This is the mail archive of the
mailing list for the GCC project.
Re: How to take the address of a label_ref?
- From: Philip Blundell <philb at gnu dot org>
- To: Richard Henderson <rth at redhat dot com>, Adrian von Bidder <avbidder at acter dot ch>, gcc <gcc at gcc dot gnu dot org>
- Date: Wed, 21 Nov 2001 21:13:02 +0000
- Subject: Re: How to take the address of a label_ref?
- References: <3BFB59CE.E3770960@acter.ch> <20011121105431.A17291@redhat.com>
In message <20011121105431.A17291@redhat.com>, Richard Henderson writes:
>On Wed, Nov 21, 2001 at 08:37:50AM +0100, Adrian von Bidder wrote:
>> How do I, in the machine description, get the address of a label_ref
>> near the pc into a register?
>Just label_ref. For arm, or maybe just thumb, this isn't a valid
>constant, and it gets spilled to the constant pool.
>I have no idea what you're trying to do, though.
I think what he's actually trying to do is generate "add rN, pc, #(.Lb - . -
Kind of like the code in arm_finalize_pic() does to address the GOT.