summaryrefslogtreecommitdiff
path: root/backend
diff options
context:
space:
mode:
authorYang Rong <rong.r.yang@intel.com>2015-09-16 16:49:37 +0800
committerYang Rong <rong.r.yang@intel.com>2015-10-13 15:11:39 +0800
commitb961ea7295d9709e6c997dab61411e2f18323bf1 (patch)
tree7022dcc821773a3e2a5e4f7e6b91289237bd7589 /backend
parent68b51807e909032be914520d68a7d1b60af3e6ee (diff)
GBE: Move createStripAttributesPass before createInstructionCombiningPass.
Otherwise, createInstructionCombiningPass will convert some call to illegal instruction in llvm3.7, for example utest compiler_time_stamp and test_load_program_from_spir. Signed-off-by: Yang Rong <rong.r.yang@intel.com> Reviewed-by: Ruiling Song <ruiling.song@intel.com> Reviewed-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
Diffstat (limited to 'backend')
-rw-r--r--backend/src/llvm/llvm_to_gen.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/backend/src/llvm/llvm_to_gen.cpp b/backend/src/llvm/llvm_to_gen.cpp
index 538d1c5a..24d4be79 100644
--- a/backend/src/llvm/llvm_to_gen.cpp
+++ b/backend/src/llvm/llvm_to_gen.cpp
@@ -110,6 +110,7 @@ namespace gbe
MPM.add(createTypeBasedAliasAnalysisPass());
MPM.add(createBasicAliasAnalysisPass());
MPM.add(createIntrinsicLoweringPass());
+ MPM.add(createStripAttributesPass()); // Strip unsupported attributes and calling conventions.
MPM.add(createSamplerFixPass());
MPM.add(createGlobalOptimizerPass()); // Optimize out global vars
@@ -119,7 +120,6 @@ namespace gbe
MPM.add(createInstructionCombiningPass());// Clean up after IPCP & DAE
MPM.add(createCFGSimplificationPass()); // Clean up after IPCP & DAE
MPM.add(createPruneEHPass()); // Remove dead EH info
- MPM.add(createStripAttributesPass()); // Strip unsupported attributes and calling conventions.
MPM.add(createBarrierNodupPass(false)); // remove noduplicate fnAttr before inlining.
MPM.add(createFunctionInliningPass(20000));
MPM.add(createBarrierNodupPass(true)); // restore noduplicate fnAttr after inlining.