LINUX.IE, website of the Irish Linux Users' Group
Tux rules!

   
Home
New Users
Articles
Download
Projects
Community
Vendors

  Print Version
Email to...
 
Archives:


planetILUG

Recent News

News Archive


Join the
ILUG
on FaceBook


Join the
ILUG
on LinkedIn


Join the
ILUG SETI
Group



















 
 :: Mailing Lists

[ILUG] 64-int int math library for 32-bit int machines?

[ILUG] 64-int int math library for 32-bit int machines?

Brian Foster blf at blf.utvinternet.co.uk
Tue Aug 24 19:01:13 IST 2004


 what I am looking for is a set of routines (e.g., a library),
 written in portable pre-1999 C, whose source is available,
 that, using 32-bit maths, implements at least the five basic
 integer operations (+ - * / %) for 64-bit integers, and which
 ideally has both a "signed" and "unsigned" version.

 please note I said using 32-bit maths.  so NO <long long>,
 NO <__int64>, NO <i64>, none of that stuff!  the compilers
 (plural) in question do not have 64-bit integers.

 ideally C, albeit C++ could be Ok, but NO assembly.
 implementations in other languages (e.g., Java) which could
 be used as a model and reference for a C version would be Ok.

 ideally a BSD-ish license, albeit (L)GPL, CPL, or so on
 should be Ok.

 ideally, the "64-bit integers" would be stored as something
 like an array[] or <struct> of two 32-bit integers.  storing
 as ASCII string, or BCD, or so on would be problematical.

 I do not need an arbitrary precision package (such as GNUs
 BigNum), nor rationals, nor fixed point, etc., just signed
 and unsigned 64-bit integers.  and please note I have _not_
 mentioned (time) efficiency, albeit space (size) could be
 a concern.  but must be mathematically sound, and ideally
 also has a comprehensive Test Suite.

 Google™ has not (yet) been of much help here.  (I suppose
 the GCC support library might have something like this?)

 any ideas?  pointers?

cheers!
	-blf-
-- 
«How many surrealists does it take to    |  Brian Foster      Montpellier,
 change a lightbulb?  Three.  One calms  |  blf at utvinternet.ie      FRANCE
 the warthog, and two fill the bathtub   |    Stop E$$o (ExxonMobile)!
 with brightly-colored machine tools.»   |        http://www.stopesso.com



More information about the ILUG mailing list
Read this without the formatting.
                                                                                                    

 

Hosted by HEAnet


Maintained by the ILUG website team. The aim of Linux.ie is to support and help commercial and private users of Linux in Ireland. You can display ILUG news in your own webpages, read backend information to find out how. Networking services kindly provided by HEAnet, server kindly donated by Dell. Linux is a trademark of Linus Torvalds, used with permission. No penguins were harmed in the production or maintenance of this highly praised website. Looking for the Indian Linux Users' Group? Try here. If you've read all this and aren't a lawyer: you should be!
RSS Version
Powered by Dell