[PATCH] D158529: [InferAlignment] Implement InferAlignmentPass

Nikita Popov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 29 06:47:16 PDT 2023


nikic added inline comments.


================
Comment at: llvm/lib/Passes/PassBuilderPipelines.cpp:1150
+  if (EnableInferAlignmentPass)
+    FPM.addPass(InferAlignmentPass());
   if (IsFullLTO) {
----------------
danilaml wrote:
> I was wondering why the pass was added after LoopeVectorize pass and not before? Wouldn't LV benefit from knowing that some pointers are better aligned? Or it doesn't care about this at the moment?
LV uses getOrEnforceKnownAlignment(), so it shouldn't matter. Did you see any issues relating to this?

(This is true pretty generally -- the passes that care about alignment will do their own inference.)


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D158529/new/

https://reviews.llvm.org/D158529



More information about the llvm-commits mailing list