2016-07-12 22:24 GMT+02:00 Luciano Notarfrancesco luchiano@gmail.com:
On Sat, Apr 23, 2016 at 7:48 PM, Eliot Miranda eliot.miranda@gmail.com wrote:
Plugins: Upgrade LargeIntegersPlugin to v2.0 LargeInteger primitives now deal with 32-bits digits. No change to image code.
Memory is 8 bytes aligned on Spur. When storing 32/64 bits large integers values, allways fill the eight bytes whatever the effectivily used size, rather than bother with dissertion of size.
Generate integer type checking as C macros rather than direct/indirect interpreterProxy function call in plugins. This, and 32-bit accessing mean singificantly faster large integer arithmetic.
Awesome! The legs are in the architecture endianness? What are the reasons to not use GMP? Could we use it if was already installed in the host platform? It seems to me that it would be quite straight forward to call to the GMP low-level API from the LargeIntegersPlugin, without making any changes in the image. https://gmplib.org/manual/Low_002dlevel-Functions.html
Yes, it would be a nice projet to write a GMPLargeIntegersPlugin.
GNU smalltalk is using gmp already, so it might be quite easy, no need to re-invent, just to rewrite. GMP is LGPL, I don't know the impact on our VM, but it in no way a show stopper for experimentation.