Re: divmod, div, mod

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Florent DEFAY <spira.inhabitant@xxxxxxxxx> writes:

> My question is:
> should I implement umodhi3 and udivhi3 and include them in libgcc so
> __divsi3 is alright,
> or should I implement divmodsi4 to override __divsi3 and __modsi3?

It's a question of runtime efficiency.  If it is faster to compute just
the quotient or the remainder, then implement __divsi3 and __modsi3 in
libgcc.  If the processor gives you both the quotient and the remainder
at the same time, then implement the udivmodsi4 insn in the MD file
(e.g., avr.md).

Ian

[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux