This is the mail archive of the gcc-help@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: Modifications to x86 __attribute__(__thiscall__) and __attribute__(cdecl) calling conventions


Robert Butler <lighth7015@gmail.com> writes:

> So far, we've only been able to deduce that functions in
> gcc/config/i386/i386.c merely check for conflicting attributes
> (e.g. fastcall AND cdecl, fastcall AND regparam, etc.) in functions
> like ix86_handle_cconv_attribute.
>
> Is there a specific suite of functions we should be looking at? (i.e.,
> ix86_xxx_foo_yyy)

ix86_function_arg and the functions that it calls.  Also
init_cumulative_args.

The effect of cdecl and stdcall is only on ix86_return_pops_args, which
I guess you don't care about.  So look for fastcall, which does change
the way that parameters are passed.

Note that this code is complicated.  What you are trying to do is not
going to be a trivial change.

Ian


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