https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115019
--- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> --- (In reply to Andrew Pinski from comment #2) > /app/example.cpp:36:24: runtime error: negation of > 0x80000000000000000000000000000000 cannot be represented in type '__int128'; > cast to an unsigned type to negate this value to itself Once I fix that with: ``` static char *itoa128(char *buf, __int128_t v) { if (v < 0) { buf = utoa128(buf, -(__uint128_t)v); ``` GCC behavior is what you expect.