Mail Archives: djgpp/1996/05/03/04:49:18
frank denis (Frank DOT Denis AT epita DOT fr) wrote:
: Hello ! In a previous mail, our friend Eli Zaretskii said :
: -=)> Use the -mregparm=n (where n is a number [1..3]). Look it up in the GCC
: -=)> docs. Note that you will have to rebuild the libraries you use (including
: -=)> the libraries which come with DJGPP) with that same switch to be
: -=)> consistent with that parameter-passing mechanism.
: May someone recompile these libraries and make them available for everyone
: on a ftp ? I tried but all the programs crashed with the new libc when I
: added -mrtd and -mregparm=3. Using __attribute__ ((__stdcall__)) for my own
: functions also cause an exception, although __regparm__ works fine. May
: someone help me produce the fastest possible code with DJGPP ?
Well, just recompiling the library souce code may not be sufficient to make
register calling available. Most of the assember parts would have to be fixed,
(though I'm not sure how much that actually is).
If you are not using any functions that call your own functions back from lib
functions (e.g. qsort or signal), it may also be possible to just fix up the
include headers to call all lib functions with __stdcall__.
At any rate, fixing the library for different calling conventions is a highly
non-trivial task that probably should be coordinated with the djgpp
developers, so that you don't have to redo it everytime a new version of the
lib gets released.
bye, Alexander
--
Alexander Lehmann, | "On the Internet,
alex AT hal DOT rhein-main DOT de (plain, MIME, NeXT) | nobody knows
alexlehm AT rbg DOT informatik DOT th-darmstadt DOT de (plain) | you're a dog."
<URL:http://www.student.informatik.th-darmstadt.de/~alexlehm/>
- Raw text -