diff options
author | Davide Italiano <davide@freebsd.org> | 2017-02-07 17:56:50 +0000 |
---|---|---|
committer | Davide Italiano <davide@freebsd.org> | 2017-02-07 17:56:50 +0000 |
commit | 2133bf556250920f803fdd60fe03d39235cc37e4 (patch) | |
tree | 6b7598685677adea0c4eb3b50bb825bf1d2832df /llvm/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp | |
parent | c6cf1f1f02c58d15b8fe8ce9c27d9ac6b080500b (diff) | |
download | bcm5719-llvm-2133bf556250920f803fdd60fe03d39235cc37e4.tar.gz bcm5719-llvm-2133bf556250920f803fdd60fe03d39235cc37e4.zip |
[InstCombine] Make max size array combine a tunable.
Requested by Sanjoy/Hal a while ago, and forgotten by me
(r283612).
llvm-svn: 294323
Diffstat (limited to 'llvm/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp')
-rw-r--r-- | llvm/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp b/llvm/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp index e0d7b72e817..a9f21512e00 100644 --- a/llvm/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp +++ b/llvm/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp @@ -609,7 +609,7 @@ static Instruction *unpackLoadToAggregate(InstCombiner &IC, LoadInst &LI) { // arrays of arbitrary size but this has a terrible impact on compile time. // The threshold here is chosen arbitrarily, maybe needs a little bit of // tuning. - if (NumElements > 1024) + if (NumElements > IC.MaxArraySizeForCombine) return nullptr; const DataLayout &DL = IC.getDataLayout(); @@ -1114,7 +1114,7 @@ static bool unpackStoreToAggregate(InstCombiner &IC, StoreInst &SI) { // arrays of arbitrary size but this has a terrible impact on compile time. // The threshold here is chosen arbitrarily, maybe needs a little bit of // tuning. - if (NumElements > 1024) + if (NumElements > IC.MaxArraySizeForCombine) return false; const DataLayout &DL = IC.getDataLayout(); |