comp.lang.ada
 help / color / mirror / Atom feed
* Integer Overflow Question.
@ 2014-08-25 11:21 austin.obyrne769
  2014-08-25 11:46 ` G.B.
  2014-08-25 12:20 ` gautier_niouzes
  0 siblings, 2 replies; 16+ messages in thread
From: austin.obyrne769 @ 2014-08-25 11:21 UTC (permalink / raw)


I have written two Ada driven ciphers that are complete and have been tweaked for the last time.

I have used an early Ada compiler - a Gnat311.p - of about 1995 vintage  <= Ada-95.

In order that the ciphers can run in 32-bit computers which are still going to be around for some time despite the availability of the 64-bit operating system in Windows 8.1 which I also use, I have had to put a bound on the maximum integer size output of computations at 2^31 which of course is the maximum positive integer that 32-bit computers can handle.

Running the same software that was written for 32-bit computers in the  64-bit environment of 8.1 and raising the bar on integer size I thought I should be able to do this ok but no - the cipher will still crash if the integer size is greater than 2^31 when I thought I could go up to 2^63.

As it happens this is not a problem crypto wise because the cipher is independent of the integer size but I am intrigued that this overflow should still happen.

I am coming to the conclusion that the max integer size than can be used without integer overflow occurring in any computer is a function of the Ada compiler being used and not the computer operating system???

Could anybody throw some light on this conjecture?

Thanking you in anticipation of your usual help,

adacrypt

^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2014-08-25 19:38 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-08-25 11:21 Integer Overflow Question austin.obyrne769
2014-08-25 11:46 ` G.B.
2014-08-25 12:58   ` austin.obyrne769
2014-08-25 13:09     ` Simon Clubley
2014-08-25 13:29       ` austin.obyrne769
2014-08-25 13:44         ` Simon Clubley
2014-08-25 13:34     ` Aay Jay Chan
2014-08-25 15:09       ` austin.obyrne769
2014-08-25 17:02       ` austin.obyrne769
2014-08-25 17:21         ` Simon Wright
2014-08-25 17:56           ` austin.obyrne769
2014-08-25 19:38           ` austin.obyrne769
2014-08-25 17:40         ` Simon Clubley
2014-08-25 18:09           ` austin.obyrne769
2014-08-25 12:20 ` gautier_niouzes
2014-08-25 12:54   ` austin.obyrne769

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox