The implementation of the functions __absv?i2(), __addv?i3() etc. for
trapping integer overflow provided in libgcc2.c is rather bad.
Same for __cmp?i2() and __ucmp?i2()

GCC creates awful to horrible code for them (at least for AMD64 and
i386 processors): see <https://skanthak.homepage.t-online.de/gcc.html>
for some examples.

The attached diff/patch provides better implementations.

Stefan

Attachment: libgcc2.diff
Description: Binary data

Reply via email to