[Bug c/70742] Support div as a builtin
glisse at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Wed Apr 20 22:18:00 GMT 2016
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70742
--- Comment #5 from Marc Glisse <glisse at gcc dot gnu.org> ---
It seems to me that the reason we don't already have div as a builtin is that
we need to know the layout of div_t.
In a header, you don't really need inline asm:
inline div_t div(int a, int b){ div_t q; q.quot=a/b; q.rem=a%b; return q; }
More information about the Gcc-bugs
mailing list