Sorry, this slipped through the net a little...  Given how much is hardcoded 
with rtasm, I'd prefer to use a single calling convention everywhere, whether 
that's STDCALL or CDECL or something else I don't mind.  Probably STDCALL 
because some compilers are too dumb to use anything else??  

In which case, a little comment documentating what stdcall really means would 
help a lot - I've hit similar issues with the differences between calling 
conventions and it basically boiled down to disassembling gcc's output to 
figure out what we're supposed to be doing...  

If we switch to stdcall, there are a couple of other platform-specific varients 
in the generated code that can be removed.  It's probably going to be the 
cleanest solution from the point of view of actually working on this code.

Keith

----- Original Message ----
> From: Stephane Marchesin <[EMAIL PROTECTED]>
> To: Victor Stinner <[EMAIL PROTECTED]>
> Cc: dri-devel@lists.sourceforge.net
> Sent: Wednesday, April 2, 2008 12:18:33 PM
> Subject: Re: Gallium: Fix for tgsi_emit_sse2()
> 
> So, we should really fix this. The two options are :
> - Keep a different calling convention under linux (cdecl by default,
> which requires saving esi by hand in the shader) and apply Victor's
> patch which saves & restores this register
> - Use the same calling convention on all platforms, that is change
> include/pipe/p_compiler.h to define XSTDCALL to stdcall on linux,
> because for now it's empty, which is _not_ stdcall but cdecl.
> 
> In any case, this is a serious issue as under linux esi gets corrupted
> on return from the SSE call. Which, of course, causes crashes.
> 
> Stephane
> 
> -------------------------------------------------------------------------
> Check out the new SourceForge.net Marketplace.
> It's the best place to buy or sell services for
> just about anything Open Source.
> http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace
> --
> _______________________________________________
> Dri-devel mailing list
> Dri-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/dri-devel
> 



-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace
--
_______________________________________________
Dri-devel mailing list
Dri-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dri-devel

Reply via email to