blob: d6ffffca12f11a683e55c744b272225e2df50b93 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
diff -Naurp gcc/config/avr/avr.c gcc/config/avr/avr.c
--- gcc/config/avr/avr.c 2011-02-11 14:56:08.000000000 -0600
+++ gcc/config/avr/avr.c 2011-02-11 14:54:05.000000000 -0600
@@ -211,6 +211,8 @@ static const struct attribute_spec avr_a
#undef TARGET_EXPAND_BUILTIN
#define TARGET_EXPAND_BUILTIN avr_expand_builtin
+#undef TARGET_HELP
+#define TARGET_HELP avr_target_help
/* Implement TARGET_SCALAR_MODE_SUPPORTED_P. */
static bool
@@ -232,7 +234,24 @@ static const struct attribute_spec avr_a
return default_fixed_point_supported_p ();
}
-
+/* Implement TARGET_HELP. */
+void
+avr_target_help (void)
+{
+ if (avr_list_supported_parts)
+ {
+ const struct mcu_type_s *list_part;
+ fprintf (stdout, "List of parts supported by avr-gcc:\n");
+ for (list_part = &avr_mcu_types[0]; (list_part + 1)->name; list_part++)
+ {
+ if (!list_part->macro)
+ list_part++;
+ fprintf (stdout, "%-20s%s\n", list_part->name, list_part->macro);
+ }
+ fprintf (stdout, "\n");
+ }
+}
+
struct gcc_target targetm = TARGET_INITIALIZER;
void
diff -Naurp gcc/config/avr/avr.opt gcc/config/avr/avr.opt
--- gcc/config/avr/avr.opt 2009-10-08 13:28:48.000000000 -0500
+++ gcc/config/avr/avr.opt 2011-02-11 14:53:20.000000000 -0600
@@ -58,3 +58,7 @@ Relax branches
mpmem-wrap-around
Target Report
Make the linker relaxation machine assume that a program counter wrap-around occures.
+
+mlist-devices
+Target RejectNegative Var(avr_list_supported_parts)
+Print the list of parts supported while printing --target-help
|