[Bug middle-end/32044] udivdi3 counterproductive, unwarranted use

pinskia at gcc dot gnu dot org gcc-bugzilla@gcc.gnu.org
Tue May 22 21:04:00 GMT 2007



------- Comment #4 from pinskia at gcc dot gnu dot org  2007-05-22 22:04 -------
> (probably the condition check is too conservative
> so this isn't fully cooked yet):

Way too conservative because even if you don't have the opcode, sometimes code
can be produced without calling the libcall.
If you change the define to:
#define NSEC_PER_SEC  0x10000000UL

You will not get an call udividi3, though there is still a divide in unsigned
long long, the division can be done exactly (via shifting).


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Severity|major                       |normal
          Component|c                           |middle-end


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=32044



More information about the Gcc-bugs mailing list