On Feb 16, 4:59 am, Tadashi Saito <sh... / mail2.accsnet.ne.jp> wrote: > Hello all, > > I released Decimal 0.0 somehow, an arithmetic extension library for Ruby. > > http://decimal.rubyforge.org/ > ... > > $ time ruby -rbigdecimal -e 'BigDecimal("1.1") ** (2 ** 16)' > > real 0m9.462s > user 0m9.433s > sys 0m0.008s > > $ time ruby -rdecimal -e 'Decimal("1.1") ** (2 ** 16)' > > real 0m0.338s > user 0m0.328s > sys 0m0.000s > > $ cat mem.rb > def mem > File.read("/proc/#{$$}/status").grep(/VmSize/) > end > > $ ruby -rmem -rbigdecimal -e 'GC.disable; d=BigDecimal("1"); 2_000_000.times {d+d}; puts mem' > VmSize: 129208 kB > > $ ruby -rmem -rdecimal -e 'GC.disable; d=Decimal(1); 2_000_000.times {d+d}; puts mem' > VmSize: 82340 kB > > These improved your image? > > In addition, this is my first release of software products. I'm little > unsure of myself, so I welcome any comments from the community to a novice. Very impressive! :-) IANAL, but you might want to add license notice to `decimal.c'. The copyright line alone would mean no rights for users if they copy the file out of the package (which includes the license text). Just curious what made you develop another decimal library--is BigDecimal unhackable or does your library uses totally different approach, or something else? ;-) -- Cheers, Alex