public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
* Can gcc generate an x86 "far return"?
@ 2009-02-08  0:39 John Z. Bohach
  2009-02-09 19:40 ` Michael Meissner
  0 siblings, 1 reply; 2+ messages in thread
From: John Z. Bohach @ 2009-02-08  0:39 UTC (permalink / raw)
  To: gcc-help

Is there an __attribute__ or #pragma or some other facility to get gcc 
to generate an "lret" (opcode  0xcb as opposed to opcode 0xc3) at the 
end of a void function?

I am able to generate my own "lret" via inline assembly, but I was 
wondering if the compiler offered any other options?

Thanks,
John

(I'm talking i386 and newer...).

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Can gcc generate an x86 "far return"?
  2009-02-08  0:39 Can gcc generate an x86 "far return"? John Z. Bohach
@ 2009-02-09 19:40 ` Michael Meissner
  0 siblings, 0 replies; 2+ messages in thread
From: Michael Meissner @ 2009-02-09 19:40 UTC (permalink / raw)
  To: John Z. Bohach; +Cc: gcc-help

On Sat, Feb 07, 2009 at 04:36:04PM -0800, John Z. Bohach wrote:
> Is there an __attribute__ or #pragma or some other facility to get gcc 
> to generate an "lret" (opcode  0xcb as opposed to opcode 0xc3) at the 
> end of a void function?
> 
> I am able to generate my own "lret" via inline assembly, but I was 
> wondering if the compiler offered any other options?

There is no current support in the compiler for generating an LRET instruction
directly.

-- 
Michael Meissner, IBM
4 Technology Place Drive, MS 2203A, Westford, MA, 01886, USA
meissner@linux.vnet.ibm.com

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-02-09 19:40 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-02-08  0:39 Can gcc generate an x86 "far return"? John Z. Bohach
2009-02-09 19:40 ` Michael Meissner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).