[Zlib-devel] Re: AMD64 and inffas86.c

Greg Roelofs newt at pobox.com
Mon Nov 1 10:24:44 EST 2004


>> But reading inffas86.c, it seem that AMD64 is only for GNUC.
>> I've an AMD64 running Windows XP64 bits and a beta of Visual studio 2005, so
>> I can help testing assembly version for AMD64 for Microsoft compiler.

> I used this script to convert from gcc to msvc in inffas86.c.  First I
> clipped out the lines in __asm__ __volatile__ (lines 463 to 783), then
> ran gcc2masm.pl < lines463-783.txt > masm.out.  I believe that converts
> most or all of the 32 bit instructions but doesn't do the 64 bit ones. 
> I'll look at that tomorrow morning...

Folks might also give intel2gas a whirl; it goes both directions and
handles inline code as well as gas/MSVC/NASM syntaxes.  It's not perfect,
but it was very helpful with the last of the big pnggccrd.c functions
(opposite direction from what you want, though).

It used to be here but seems to have moved on:

	http://hermes.terminal.at/intel2gas/

According to freshmeat, this is the current home page:

	http://www.niksula.cs.hut.fi/~mtiihone/intel2gas/

However, it hasn't been updated in four years, and I'd bet there's a
newer version out there somewhere.  (Either way, it's simple enough to
add the 64-bit instructions to the existing lists of opcodes.)

Greg




More information about the Zlib-devel mailing list