Re: [Patch] Overflow-trapping integer arithmetic routines7code: bloated and slooooow

2020-10-05 Thread Jonathan Wakely via Gcc
On Mon, 5 Oct 2020 at 17:12, Stefan Kanthak wrote: > > 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 an

[Patch] Overflow-trapping integer arithmetic routines7code: bloated and slooooow

2020-10-05 Thread Stefan Kanthak
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