projects
/
oota-llvm.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Disable most IR-level transform passes on functions marked 'optnone'.
[oota-llvm.git]
/
lib
/
Transforms
/
Scalar
/
ADCE.cpp
diff --git
a/lib/Transforms/Scalar/ADCE.cpp
b/lib/Transforms/Scalar/ADCE.cpp
index a3eb07a9f6d66507a76fb5b23f07c597482b9011..a53b23ec446c0d221947b45d424344a9fe03b0d8 100644
(file)
--- a/
lib/Transforms/Scalar/ADCE.cpp
+++ b/
lib/Transforms/Scalar/ADCE.cpp
@@
-50,6
+50,9
@@
char ADCE::ID = 0;
INITIALIZE_PASS(ADCE, "adce", "Aggressive Dead Code Elimination", false, false)
bool ADCE::runOnFunction(Function& F) {
+ if (skipOptnoneFunction(F))
+ return false;
+
SmallPtrSet<Instruction*, 128> alive;
SmallVector<Instruction*, 128> worklist;