Update copyright year
[openadk.git] / toolchain / gcc / patches / 4.4.7 / 933-avr32_bug_7435.patch
blob78106619c5e37834e3fc8be360edc09b16ed3acf
1 --- a/gcc/config/avr32/avr32.c
2 +++ b/gcc/config/avr32/avr32.c
3 @@ -243,14 +243,14 @@ void
4 avr32_override_options (void)
6 const struct part_type_s *part;
7 - const struct arch_type_s *arch;
8 + const struct arch_type_s *arch, *part_arch;
10 /*Add backward compability*/
11 if (strcmp ("uc", avr32_arch_name)== 0)
13 fprintf (stderr, "Warning: Deprecated arch `%s' specified. "
14 "Please use '-march=ucr1' instead. "
15 - "Converting to arch 'ucr1'\n",
16 + "Using arch 'ucr1'\n",
17 avr32_arch_name);
18 avr32_arch_name="ucr1";
20 @@ -298,6 +298,12 @@ avr32_override_options (void)
21 if (!arch->name)
22 avr32_arch = &avr32_arch_types[avr32_part->arch_type];
24 + /* When architecture implied by -mpart and one passed in -march are
25 + * conflicting, issue an error message */
26 + part_arch = &avr32_arch_types[avr32_part->arch_type];
27 + if (strcmp("none",avr32_part_name) && strcmp("none", avr32_arch_name) && strcmp(avr32_arch_name,part_arch->name))
28 + error ("Conflicting architectures implied by -mpart and -march\n");
30 /* If optimization level is two or greater, then align start of loops to a
31 word boundary since this will allow folding the first insn of the loop.
32 Do this only for targets supporting branch prediction. */