forked from OSchip/llvm-project
Use modulo operator instead of multiplying result of a divide and subtracting from the original dividend. NFC.
llvm-svn: 253792
This commit is contained in:
parent
4ca21fc1aa
commit
a5ea5289ff
|
@ -190,7 +190,7 @@ bool MemsetRange::isProfitableToUseMemset(const DataLayout &DL) const {
|
|||
unsigned NumPointerStores = Bytes / MaxIntSize;
|
||||
|
||||
// Assume the remaining bytes if any are done a byte at a time.
|
||||
unsigned NumByteStores = Bytes - NumPointerStores * MaxIntSize;
|
||||
unsigned NumByteStores = Bytes % MaxIntSize;
|
||||
|
||||
// If we will reduce the # stores (according to this heuristic), do the
|
||||
// transformation. This encourages merging 4 x i8 -> i32 and 2 x i16 -> i32
|
||||
|
|
Loading…
Reference in New Issue