gmp 4.3.0 asm errors on ppc64

Jørn Amundsen Jorn.Amundsen at ntnu.no
Sun Apr 19 23:30:00 CEST 2009


On Sun, 19 Apr 2009, Torbjorn Granlund wrote:
>
> I don't understand why you introduce EXTERN_TEXT.  If .globl is the
> right declaration for any externally defined symbol, why not use the
> existing mechanism EXTERN?  Am I missing something?
>
> --
> Torbjörn
>

This was the very first thing I tried. In divrem_1.asm, the EXTERN
macro expands into

         .globl  __gmpn_invert_limb

, while the CALL macro expands to

        bl      .__gmpn_invert_limb

Notice the missing initial dot. The next I tried was to try modify EXTERN()
to prefix external names with dot. However, this breaks .asm files using
LEA(), since now (dive_1.asm, mode1o.asm)

         LEA(    r7, binvert_limb_table)

expands into

         ld      7, ..__gmp_binvert_limb_table(2)

With *two* initial dot's in the external name. Hence the workaround by
introducing EXTERN_TEXT as an attempt make EXTERN+CALL
(e.g. EXTERN_TEXT) work without investigating all way down the road
how to make EXTERN+CALL *and* EXTERN+LEA both work.

It is ugly, and I understand it is not very useful to you unless it
works across all ppc64 platforms.

I have built almost all of the previous gmp 4.x releases with xlc, and
it has always worked flawlessly. This is the first time I experience
problems. We also have the latest gcc 4.3.3 compiler
installed. However, my experience is xlc is performing better.

Best Regards --Jørn Amundsen

-------------- next part --------------
A non-text attachment was scrubbed...
Name: gmp-xlc.tgz
Type: application/x-gtar
Size: 6360 bytes
Desc: 
URL: <http://gmplib.org/list-archives/gmp-bugs/attachments/20090419/d822195f/attachment-0001.gtar>


More information about the gmp-bugs mailing list