This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/14084] New: Reg allocator changes REG_EXPR
- From: "zlomek at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 9 Feb 2004 14:10:52 -0000
- Subject: [Bug middle-end/14084] New: Reg allocator changes REG_EXPR
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
On ppc64 and probably all 64-bit big endian machines
global register allocator IMHO wrongly changes REG_EXPR of an "int" variable
stored in 64-bit when compiling attached testcase (even at -O0).
In the following example, repcount is a 32-bit "int" variable,
subreg:SI (reg:DI 118 [ repcount ]) 4)) is changed into
(reg:SI 0 0 [orig:118 repcount+4 ] [118]))
Note that repcount is only 4 bytes wide so offset 4 makes no sense.
lreg:
(insn 4 3 5 0 (set (reg:SI 119 [ repcount ])
(subreg:SI (reg:DI 118 [ repcount ]) 4)) 303 {*movsi_internal1} (nil)
(expr_list:REG_DEAD (reg:DI 118 [ repcount ])
(nil)))
greg:
(insn 4 3 5 0 (set (reg:SI 0 0 [orig:119 repcount ] [119])
(reg:SI 0 0 [orig:118 repcount+4 ] [118])) 303 {*movsi_internal1} (nil)
(nil))
This makes variable tracking think that there are two parts of that variable.
--
Summary: Reg allocator changes REG_EXPR
Product: gcc
Version: 3.5.0
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: middle-end
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: zlomek at gcc dot gnu dot org
CC: gcc-bugs at gcc dot gnu dot org
GCC build triplet: powerpc64-unknown-linux
GCC host triplet: powerpc64-unknown-linux
GCC target triplet: powerpc64-unknown-linux
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14084