This is the mail archive of the gcc@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]

Re: Add support for the Win32 hook prologue (try 3)


2009/9/11 Ross Ridge <rridge@csclub.uwaterloo.ca>:
> Stefan Dösinger writes:
>>On a partly related topic, I think the Win64 ABI requires that the first
>>function is two bytes long, and there at least 6 bytes of slack before
>>the function. Does gcc implement that?
>
> As far as I can tell the Win64 ABI doesn't have either of these
> requirements. ?Microsoft's compiler certainly doesn't guarantee that
> functions begin with two byte instructions, and the "x64 Software
> Conventions" document gives examples of prologues with larger initial
> instructions:
>
> ? ? ? ?http://msdn.microsoft.com/en-us/library/tawsa7cb(VS.80).aspx
>
> Mind you, last I checked, GCC didn't actually follow the ABI requirements
> for prologues and epilogues given in the link above, but that only breaks
> ABI unwinding.

Right, but even unwinding is still possible on x64 (so we don't break
the SEH2 unwinding support actually), as everything gcc does here in
prologue, can be expressed by chaininfo (if prologue size is bigger
then 255 bytes).



-- 
|  (\_/) This is Bunny. Copy and paste
| (='.'=) Bunny into your signature to help
| (")_(") him gain world domination


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