Here’s quite an interesting paper by Felix von Leitner, aka Fefe, a german member of the Chaos Computer Club and political blogger.
Whereby: most of the Assembler code in it is quite Chinese to me. The interesting point he stresses is that you shouldn’t worry about overflow checks making your code slower. I don’t know how far the Xojo compiler is with this, but using LLVM for iOS will surely open the path for a general use of LLVM in the near future.
In general RAM access is still much slower than internal computations, and modern CPUs (supported by optimizing compilers) work asynchronously, meaning there’s a lot of idle time when the CPU waits for another piece of RAM to load. This is, as he has proven, more than enough to perform addition overflow checks without any delay.
For multiplication overflow checks there is still some delay but some compilers offer intrinsics like builtin_mul_overflow which can be checked without performance loss. Nice to know, I think.
The paper: http://www.fefe.de/source-code-optimization.pdf
and his blog entry (in german): http://blog.fefe.de/?ts=aa84a00b