This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug middle-end/47602] Permit inline asm to clobber PIC register


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47602

--- Comment #12 from H.J. Lu <hjl.tools at gmail dot com> 2011-02-04 15:01:56 UTC ---
(In reply to comment #10)
>
> what way are we helping them by forcing them to know about it?  How does that
> help them write inline assembler which, e.g., uses the cpuid instruction, or

Use <cpuid.h> provided by gcc.

> makes a kernel system call which passes a parameter in %ebx?

You can use syscall () or take a look at the C library source
to see how system call is inlined.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]