|modulus and remainder email@example.com (Matthew J. Lockner) (2001-06-28)|
|Re: modulus and remainder Peter-Lawrence.Montgomery@cwi.nl (2001-07-01)|
|Re: modulus and remainder firstname.lastname@example.org (Joachim Durchholz) (2001-07-01)|
|From:||"Matthew J. Lockner" <email@example.com>|
|Date:||28 Jun 2001 23:51:56 -0400|
|Organization:||University of Northern Iowa|
|Posted-Date:||28 Jun 2001 23:51:56 EDT|
Does anyone know of a thorough reference on compiling modulus and remainder
operators in expressions? I was looking at the output of gcc on some small
test C functions to get some insights. Sometimes it uses a divide
instruction, and uses the remainder left in a register by the instruction.
That seems like an obvious approach, but it doesn't always use that
technique. I would like to see some of the theory behind this and other
approaches. Ideally I would also like to see how translating modulus
operations differs from translating remainder operations, where each
operator is defined as it would be in Ada, for example (i.e., where the two
operations might yield different results).
Return to the
Search the comp.compilers archives again.