summaryrefslogtreecommitdiffstats
path: root/llvm/test/Transforms/InstCombine/saturating-add-sub.ll
diff options
context:
space:
mode:
authorFangrui Song <maskray@google.com>2019-02-28 05:16:01 +0000
committerFangrui Song <maskray@google.com>2019-02-28 05:16:01 +0000
commite931931b34cebf132b601374399f021105434c32 (patch)
tree22feb1c365c3165270b0732eb2b3d8057e9374b3 /llvm/test/Transforms/InstCombine/saturating-add-sub.ll
parent21020bf015aa15af503e9ae8a56314b15ee93e07 (diff)
downloadbcm5719-llvm-e931931b34cebf132b601374399f021105434c32.tar.gz
bcm5719-llvm-e931931b34cebf132b601374399f021105434c32.zip
[Dominators] Avoid potentially quadratic std::is_permutation
Summary: If the two sequences are not equal, std::is_permutation may be O(N^2) and indeed the case in libstdc++ and libc++. Use SmallPtrSet to prevent pessimizing cases. On my machine, SmallPtrSet starts to outperform std::is_permutation when there are 16 elements. Reviewers: kuhar Reviewed By: kuhar Subscribers: kristina, jdoerfert, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D58373 llvm-svn: 355070
Diffstat (limited to 'llvm/test/Transforms/InstCombine/saturating-add-sub.ll')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud