This is the mail archive of the
mailing list for the GCC project.
Re: i686 pic & DCmode
- From: Ian Lance Taylor <iant at google dot com>
- To: Nathan Sidwell <nathan at acm dot org>
- Cc: GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Wed, 7 Aug 2013 11:36:39 -0700
- Subject: Re: i686 pic & DCmode
- References: <52026D4D dot 8020604 at acm dot org> <52028539 dot 8030609 at acm dot org>
On Wed, Aug 7, 2013 at 10:34 AM, Nathan Sidwell <email@example.com> wrote:
> Having poked further, I find this in the testsuite:
> register int regvar asm("%eax");
> char *
> do_copy (char *str)
> return malloc (strlen (str) + 1);
> Is that even meaningful? The doc's for a global reg var say:
> 'Choose a register that is normally saved and restored by function calls on
> machine, so that library routines will not clobber it.'
This is risky but meaningful, and potentially useful with asm
> If one never made calls to a library unaware of the reg's global use, things
> would be ok. Except if one chose a register that is used by the ABI to
> return things, or by the pro/epilogue code as a scratch register.
> Should attempts to use a call_used reg as a global reg var generate an
No. Perhaps a warning.
> Should it stop it being marked as a fixed_reg?