Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(546)

Unified Diff: lib/Transforms/NaCl/PNaClABISimplify.cpp

Issue 135953002: PNaCl: Fix handling of va_arg on structs in simplification passes (Closed) Base URL: http://git.chromium.org/native_client/pnacl-llvm.git@master
Patch Set: Update comment Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « lib/Transforms/NaCl/ExpandVarArgs.cpp ('k') | test/Transforms/NaCl/pnacl-abi-simplify-preopt.ll » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/Transforms/NaCl/PNaClABISimplify.cpp
diff --git a/lib/Transforms/NaCl/PNaClABISimplify.cpp b/lib/Transforms/NaCl/PNaClABISimplify.cpp
index 91729c253ba731eddff2e49cedc63e7598182a83..6355d1e2aa29acc4146b6c10a233e110bd43002f 100644
--- a/lib/Transforms/NaCl/PNaClABISimplify.cpp
+++ b/lib/Transforms/NaCl/PNaClABISimplify.cpp
@@ -57,13 +57,15 @@ void llvm::PNaClABISimplifyAddPreOptPasses(PassManager &PM) {
PM.add(createRewriteLLVMIntrinsicsPass());
// Expand out some uses of struct types.
+ PM.add(createExpandVarArgsPass());
PM.add(createExpandArithWithOverflowPass());
// ExpandStructRegs must be run after ExpandArithWithOverflow to
// expand out the insertvalue instructions that
- // ExpandArithWithOverflow introduces.
+ // ExpandArithWithOverflow introduces. ExpandStructRegs must be run
+ // after ExpandVarArgs so that struct-typed "va_arg" instructions
+ // have been removed.
PM.add(createExpandStructRegsPass());
- PM.add(createExpandVarArgsPass());
PM.add(createExpandCtorsPass());
PM.add(createResolveAliasesPass());
PM.add(createExpandTlsPass());
« no previous file with comments | « lib/Transforms/NaCl/ExpandVarArgs.cpp ('k') | test/Transforms/NaCl/pnacl-abi-simplify-preopt.ll » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698