blob: 6616640045d85841d3efd13b739b888781e6bc31 (
plain)
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
|
--- a/gcc/config/avr32/avr32.c
+++ b/gcc/config/avr32/avr32.c
@@ -6501,12 +6501,23 @@ avr32_reorg_optimization (void)
continue;
set = single_set (scan);
- if (set && rtx_equal_p (src_reg, SET_DEST (set)))
- {
- link = scan;
- break;
- }
-
+ // Fix for bug #11763 : the following if condition
+ // has been modified and else part is included to
+ // set the link to NULL_RTX.
+ // if (set && rtx_equal_p (src_reg, SET_DEST (set)))
+ if (set && (REGNO(src_reg) == REGNO(SET_DEST(set))))
+ {
+ if (rtx_equal_p (src_reg, SET_DEST (set)))
+ {
+ link = scan;
+ break;
+ }
+ else
+ {
+ link = NULL_RTX;
+ break;
+ }
+ }
}
|