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

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

Issue 992493002: Lower signatures exposing struct registers to byval struct pointers (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-llvm.git@master
Patch Set: Using IRBuilder Created 5 years, 9 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
Index: lib/Transforms/NaCl/PNaClABISimplify.cpp
diff --git a/lib/Transforms/NaCl/PNaClABISimplify.cpp b/lib/Transforms/NaCl/PNaClABISimplify.cpp
index e5d2fbd4b38da27062c5e82a5b8bc2590ac2d001..c8dcae1d19d4fedcc8dd63913e3ae720819c134e 100644
--- a/lib/Transforms/NaCl/PNaClABISimplify.cpp
+++ b/lib/Transforms/NaCl/PNaClABISimplify.cpp
@@ -154,6 +154,9 @@ void llvm::PNaClABISimplifyAddPostOptPasses(PassManagerBase &PM) {
// ConstantExprs have already been expanded out.
PM.add(createReplacePtrsWithIntsPass());
+ // Convert struct reg function params to struct* byval
+ PM.add(createSimplifyStructRegSignaturesPass());
+
// The atomic cmpxchg instruction returns a struct, and is rewritten to an
// intrinsic as a post-opt pass, we therefore need to expand struct regs.
PM.add(createExpandStructRegsPass());

Powered by Google App Engine
This is Rietveld 408576698