This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/28581] Illegal loading the address of a label with -O2
- From: "inaoka dot kazuhiro at renesas dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 3 Aug 2006 06:07:10 -0000
- Subject: [Bug c/28581] Illegal loading the address of a label with -O2
- References: <bug-28581-5993@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #1 from inaoka dot kazuhiro at renesas dot com 2006-08-03 06:07 -------
Created an attachment (id=12001)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=12001&action=view)
testcase
gcc -S -O2 label_address.c
label_address.s
.file "label_address.c"
.text
.p2align 4,,15
.globl test_func
.type test_func, @function
test_func:
.L2: <====== NG
pushl %ebp
movl %esp, %ebp
subl $8, %esp
movl $.L2, (%esp)
call func
call func1
call func2
leave
.p2align 4,,4
ret
.size test_func, .-test_func
.ident "GCC: (GNU) 4.1.2 20060708 (prerelease) (Debian 4.1.1-8)"
.section .note.GNU-stack,"",@progbits
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28581