<p dir="ltr">LGTM as well. </p>
<br><div class="gmail_quote">On Thu, Mar 26, 2015, 6:15 AM Ranjeet Singh <<a href="mailto:ranjeet.singh@arm.com">ranjeet.singh@arm.com</a>> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Renato,<br>
<br>
Thanks for the code review.<br>
<br>
I've attached another patch with your suggested changes. I don't have commit access yet, so could you commit this one?<br>
I'll go through the process today to get commit rights.<br>
<br>
Thanks,<br>
Ranjeet<br>
<br>
<br>
<a href="http://reviews.llvm.org/D8630" target="_blank">http://reviews.llvm.org/D8630</a><br>
<br>
Files:<br>
lib/Target/ARM/<u></u>ARMTargetMachine.cpp<br>
<br>
Index: lib/Target/ARM/<u></u>ARMTargetMachine.cpp<br>
==============================<u></u>==============================<u></u>=======<br>
--- lib/Target/ARM/<u></u>ARMTargetMachine.cpp<br>
+++ lib/Target/ARM/<u></u>ARMTargetMachine.cpp<br>
@@ -37,6 +37,11 @@<br>
" to make use of cmpxchg flow-based information"),<br>
cl::init(true));<br>
<br>
+static cl::opt<bool><br>
+EnableARMLoadStoreOpt("arm-<u></u>load-store-opt", cl::Hidden,<br>
+ cl::desc("Enable ARM load/store optimization pass"),<br>
+ cl::init(true));<br>
+<br>
extern "C" void LLVMInitializeARMTarget() {<br>
// Register the target.<br>
RegisterTargetMachine<<u></u>ARMLETargetMachine> X(TheARMLETarget);<br>
@@ -348,18 +353,22 @@<br>
}<br>
<br>
void ARMPassConfig::addPreRegAlloc(<u></u>) {<br>
- if (getOptLevel() != CodeGenOpt::None)<br>
- addPass(<u></u>createARMLoadStoreOptimization<u></u>Pass(true));<br>
- if (getOptLevel() != CodeGenOpt::None)<br>
+ if (getOptLevel() != CodeGenOpt::None) {<br>
addPass(<u></u>createMLxExpansionPass());<br>
- if (getOptLevel() != CodeGenOpt::None && !DisableA15SDOptimization) {<br>
- addPass(<u></u>createA15SDOptimizerPass());<br>
+<br>
+ if (EnableARMLoadStoreOpt)<br>
+ addPass(<u></u>createARMLoadStoreOptimization<u></u>Pass(/* pre-register alloc */ true));<br>
+<br>
+ if (!DisableA15SDOptimization)<br>
+ addPass(<u></u>createA15SDOptimizerPass());<br>
}<br>
}<br>
<br>
void ARMPassConfig::addPreSched2() {<br>
if (getOptLevel() != CodeGenOpt::None) {<br>
- addPass(<u></u>createARMLoadStoreOptimization<u></u>Pass());<br>
+ if (EnableARMLoadStoreOpt)<br>
+ addPass(<u></u>createARMLoadStoreOptimization<u></u>Pass());<br>
+<br>
addPass(<u></u>createExecutionDependencyFixPa<u></u>ss(&ARM::DPRRegClass));<br>
}<br>
<br>
@@ -373,7 +382,7 @@<br>
addPass(<u></u>createThumb2SizeReductionPass(<u></u>));<br>
if (!getARMSubtarget().<u></u>isThumb1Only())<br>
addPass(&IfConverterID);<br>
- }<br>
+ }<br>
addPass(<u></u>createThumb2ITBlockPass());<br>
}<br>
<br>
EMAIL PREFERENCES<br>
<a href="http://reviews.llvm.org/settings/panel/emailpreferences/" target="_blank">http://reviews.llvm.org/<u></u>settings/panel/<u></u>emailpreferences/</a><br>
______________________________<u></u>_________________<br>
llvm-commits mailing list<br>
<a href="mailto:llvm-commits@cs.uiuc.edu" target="_blank">llvm-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits" target="_blank">http://lists.cs.uiuc.edu/<u></u>mailman/listinfo/llvm-commits</a><br>
</blockquote></div>