On Thu, Aug 18, 2011 at 4:16 AM, Richard Earnshaw Richard.Earnshaw@arm.com wrote:
I was just browsing libgmp this afternoon and noticed that it really could do with an overhaul to support recent ARM chips.
The ARM code seems to have been written for StrongARM; which is now almost obsolete (for example, it loads from a cache line it is about to write to in order to pre-allocate the line in the cache).
It doesn't support v4T interworking.
It doesn't make any use of v5 or later instructions.
There is some Thumb(1) code, but again it has no support for interworking, is pretty poor and limited in scope.
I'm not sure overall how useful this is to gcc performance; the library is needed to build GCC, but I think it's mostly there to support libmpfr.
Nevertheless, there are other apps out there that make use of this stuff, including some crypto code, IIRC.
I looked at using gmp as a benchmark some time ago. The assembly version is twice as fast as the C version already, which is nice. I assume NEON would be a big improvement as well.
I had a quick poke through the dependencies in Ubuntu and came up with the following popular packages that use libgmp or libmpfr: * guile * python-crypto * gch (Haskel) * maxima * darcs
Nothing earth shattering but probably worthwhile. I've registered: https://blueprints.launchpad.net/linaro-toolchain-misc/+spec/improve-libgmp
so that we don't lose it.
-- Michael
linaro-toolchain@lists.linaro.org