Re: RFC: project directions...

jgd@cix.compulink.co.uk
Sat, 19 Sep 2009 13:57:32 -0500

          From comp.compilers

Related articles
RFC: project directions... cr88192@hotmail.com (BGB / cr88192) (2009-09-14)
Re: RFC: project directions... jgd@cix.compulink.co.uk (2009-09-19)
Re: RFC: project directions... cr88192@hotmail.com (BGB / cr88192) (2009-09-21)
Re: RFC: project directions... jgd@cix.compulink.co.uk (2009-09-26)
Re: RFC: project directions... cr88192@hotmail.com (BGB / cr88192) (2009-09-26)
Re: RFC: project directions... jgd@cix.compulink.co.uk (2009-10-03)
Re: RFC: project directions... cr88192@hotmail.com (BGB / cr88192) (2009-10-03)
| List of all articles for this month |
From: jgd@cix.compulink.co.uk
Newsgroups: comp.compilers
Date: Sat, 19 Sep 2009 13:57:32 -0500
Organization: Compilers Central
References: 09-09-065
Keywords: code
Posted-Date: 21 Sep 2009 15:14:50 EDT

cr88192@hotmail.com (BGB / cr88192) wrote:


> however, as a cost:
> since it would be the non-native calling convention, there would be
> imperfect interfacing with the natively compiled code, in particular
> WRT function pointers and 'va_list' and similar. although automatic
> stub-generation is likely to glue the calling conventions together
> fairly well, the glue is likely to be imperfect in various cases.


Do you plan to provide libraries of your own for all of the APIs that
Linux on x86-64 offers? I suspect not, but without that, the usefulness
of your language will be rather limited. I think you need to provide a
real, honest, 100% compatible implementation of the standard calling
convention, both for calling external libraries, and for functions to be
passed to them as callbacks. You really should ensure that linker
symbols for your own calling convention can't be confused with ones from
the usual compilers, not even by ingenious idiots.


I'd expect that using your own calling convention, while it may offer
up-front savings in effort, will become a millstone with time. It's
probably going to be best to bite the bullet now, and save the effort of
switching at a later date.


--
John Dallman jgd@cix.co.uk
                    "C++ - the FORTRAN of the early 21st century."
[How much performance difference does a calling convention make, anyway?
I'd think that if you had a lot of tiny procedures, you'd be better off
inlining them like C++ does so they can participate in the calling
procedure's optimizations. -John]



Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.