This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/47602] Permit inline asm to clobber PIC register
- From: "hjl.tools at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 4 Feb 2011 15:02:00 +0000
- Subject: [Bug middle-end/47602] Permit inline asm to clobber PIC register
- Auto-submitted: auto-generated
- References: <bug-47602-4@http.gcc.gnu.org/bugzilla/>
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.