arm "neon"

Torbjorn Granlund tg at
Thu Feb 21 15:28:18 CET 2013

nisse at (Niels Möller) writes:

  One could hope so. I'm still a bit skeptic to mul and accumulate, at
  least for addmul_2, since it's seems like a good idea to schedule the
  multiplications far in advance.
Multiply-accumulate can have the drawback to put multiplication in the
critical path.

IIRC, some ARM processors actually read the accumulation registers later
than the multiplicands.

  > How do you test your loops?
  I just used tests/mpn/t-mul.
I'd advice strongly against that.  Creating hard-to-trigger carry
propagation bugs is not unlikely when playing with these primitives, and
addmul_N.c will be much better at finding these, and will also shorten
your development cycle (fast results, no need for make && make check).
It will also print a diff table which makes debugging easier.

Typical command:

gcc -O1 -I. -I$gmpsrc $gmpsrc/tests/devel/addmul_N.c -DN=2 -DTIMES \
-DCLOCK=3200000000 .libs/libgmp.a tests/.libs/libtests.a && ./a.out


More information about the gmp-devel mailing list