This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: C++: Letting compiler know asm block can call function that can throw?
On 03/29/2012 01:16 PM, Jan Hubicka wrote:
>> Of course, there's still the problem of getting the unwind data correct at
>> the point of the asm. I commented about that in the PR you filed.
>
> I think i386 still has the problem that it is small register class target and if you
> set rdi/rax and friends as hard registers, you risk reload failures.
True, and if this were i386 code I would certainly recommend using the [acd]
constraints instead (for suitible regparm signature). But this is explicitly
x86_64 code and the compiler has 8 registers otherwise available.
> Do we prevent code motion of hard registers sets i.e. at GIMPLE level?
I don't know for positive, but I'd certainly consider it a bug if we don't.
There are plenty of targets which have no alternative but to use this style
of programming for inline syscalls.
r~