[PATCH] [AArch64] Enable partial unrolling and runtime unrolling for AArch64 target

hfinkel at anl.gov hfinkel at anl.gov
Tue Sep 9 14:51:34 PDT 2014


================
Comment at: lib/Target/AArch64/AArch64TargetTransformInfo.cpp:530
@@ +529,3 @@
+                                         UnrollingPreferences &UP) const {
+    UP.Partial = UP.Runtime = true;
+}
----------------
I recommend not enabling it this way. Instead, you should set LoopMicroOpBufferSize in the relevant scheduling model. You'll see this is done in lib/Target/X86/X86SchedHaswell.td, for example. This was you can take advantage of the default logic in BasicTargetTransformInfo.cpp (which does things like exclude loops with function calls).

Also, it will force you to pick a threshold, which is really a core-specific property (generally speaking). In my experience, this helps on OOO cores only for small loops. For in-order cores, especially if you use AA during instruction scheduling, it can help for larger loops too (but obviously not *too* large).

http://reviews.llvm.org/D5148






More information about the llvm-commits mailing list