[Bug lto/64795] New: [5.0 regression x86_64] too many memory references for `lea'
dimhen at gmail dot com
gcc-bugzilla@gcc.gnu.org
Mon Jan 26 12:10:00 GMT 2015
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64795
Bug ID: 64795
Summary: [5.0 regression x86_64] too many memory references for
`lea'
Product: gcc
Version: 5.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: lto
Assignee: unassigned at gcc dot gnu.org
Reporter: dimhen at gmail dot com
r218766 PASS
r218767 FAIL
r220090 FAIL
Fedora 21 / x86_64
$ cat t.ii
typedef void tf(struct s);
struct s {
tf *pf;
};
void fn1(void *);
static void fn2(s);
main() {
static s a;
fn1(&a);
a.pf = fn2;
}
$ touch r.ii
$ /home/dimhen/bin/gcc_218767_yes/bin/g++ -fpreprocessed -O -flto -fPIC -DPIC
-c -o r.o r.ii
$ /home/dimhen/bin/gcc_218767_yes/bin/g++ -fpreprocessed -O -flto -c -o t.o
t.ii
$ $ /home/dimhen/bin/gcc_218767_yes/bin/g++ -flto -o x t.o r.o -save-temps
x.ltrans0.s: Assembler messages:
x.ltrans0.s:12: Error: too many memory references for `lea'
lto-wrapper: fatal error: /home/dimhen/bin/gcc_218767_yes/bin/g++ returned 1
exit status
compilation terminated.
/usr/bin/ld: fatal error: lto-wrapper failed
collect2: error: ld returned 1 exit status
$ cat x.ltrans0.s
.file "x.ltrans0.o"
.text
.globl main
.type main, @function
main:
.LFB0:
.cfi_startproc
subq $8, %rsp
.cfi_def_cfa_offset 16
leaq _ZZ4mainE1a(%rip), %rdi
call _Z3fn1Pv@PLT
leaq _ZL3fn21s(%rip), _ZZ4mainE1a(%rip)
movl $0, %eax
addq $8, %rsp
.cfi_def_cfa_offset 8
ret
.cfi_endproc
.LFE0:
.size main, .-main
.local _ZZ4mainE1a
.comm _ZZ4mainE1a,8,8
.ident "GCC: (GNU) 5.0.0 20141215 (experimental) [trunk revision
218767]"
.section .note.GNU-stack,"",@progbits
$ /home/dimhen/bin/gcc_218767_yes/bin/g++ -v
Using built-in specs.
COLLECT_GCC=/home/dimhen/bin/gcc_218767_yes/bin/g++
COLLECT_LTO_WRAPPER=/home/dimhen/bin/gcc_218767_yes/bin/../libexec/gcc/x86_64-unknown-linux-gnu/5.0.0/lto-wrapper
Target: x86_64-unknown-linux-gnu
Configured with: /home/dimhen/src/gcc_r218767/configure
--prefix=/usr/local/gcc_current --enable-static --enable-checking=yes
--enable-languages=c,c++,lto --enable-plugin --disable-libstdcxx-dual-abi
Thread model: posix
gcc version 5.0.0 20141215 (experimental) [trunk revision 218767] (GCC)
More information about the Gcc-bugs
mailing list