This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/16559] Incorrect code generated for function pointer
- From: "hjl at lucon dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 15 Jul 2004 07:18:23 -0000
- Subject: [Bug target/16559] Incorrect code generated for function pointer
- References: <20040715070433.16559.hjl@lucon.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From hjl at lucon dot org 2004-07-15 07:18 -------
This should work on ia64. Otherwise, we will be in big trouble. The issue is
we can never access a function pointer with
addl r14 = @ltoffx(os_boot_rendez#), r1
...
ld8.mov r14 = [r14], os_boot_rendez#
This sequence is for accessing data. A function pointer has to be accessed
with special relocations like
addl r14 = @ltoff(@fptr(os_boot_rendez#)), gp
BTW, gcc 3.4 is OK.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16559