| | |
Summary: Strength Reduction of Integer Division and Modulo Operations
Jeffrey Sheldon, Walter Lee, Ben Greenwald, Saman Amarasinghe
M.I.T. Laboratory for Computer Science
Cambridge, MA 02139, U.S.A.
fjeffshel,walt,beng,samang@lcs.mit.edu
ABSTRACT
Integer division, modulo, and remainder operations are ex-
pressive and useful operations. They are logical candidates
to express complex data accesses such as the wrap-around be-
havior in queues using ring buers. In addition, they appear
frequently in address computations as a result of compiler
optimizations that improve data locality, perform data dis-
tribution, or enable parallelization. Experienced application
programmers, however, avoid them because they are slow.
Furthermore, while advances in both hardware and software
have improved the performance of many parts of a program,
few are applicable to division and modulo operations. This
trend makes these operations increasingly detrimental to pro-
gram performance.
This paper describes a suite of optimizations for eliminat-
|