This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: How to define TARGET_LEGITIMATE_ADDRESS_P?
- From: Ian Lance Taylor <iant at google dot com>
- To: "Kim\, Eunchan" <helpbygrace at gmail dot com>
- Cc: gcc-help at gcc dot gnu dot org
- Date: Thu, 29 Oct 2009 22:00:13 -0700
- Subject: Re: How to define TARGET_LEGITIMATE_ADDRESS_P?
- References: <507f7d510910291912r272ee3fbv4a4ec37871465a93@mail.gmail.com>
"Kim, Eunchan" <helpbygrace@gmail.com> writes:
> With your helps, I could port first draft version of GCC. Thank you all.
>
> Now, I port 2nd version. At first, I ported with mips descriptions.
> But now i port from scratch while reading chapter 17 in GCC Internals.
>
> Now, I'm at TARGET_LEGITIMATE_ADDRESS_P. But i cannot how to define
> this Hook because i can not find any examples that define
> 'TARGET_LEGITIMATE_ADDRESS_P'. every port defines
> GO_IF_LEGITIMATE_ADDRESS which is deprecated instead
> TARGET_LEGITIMATE_ADDRESS_P.
As you've seen, in the current development sources,
GO_IF_LEGITIMATE_ADDRESS has been replaced by
TARGET_LEGITIMATE_ADDRESS_P. I assume you are doing your port using
some older version of gcc. If you run "make pdf" in the gcc
subdirectory of a configured build directory, you will get a copy of
the internals manual for the version of gcc that you are using. It
will be called gccint.pdf. Or you can just read the texinfo source
files for the manual, they are fairly readable.
GO_IF_LEGITIMATE_ADDRESS jumps to a label if the address is
legitimate.
Ian