[PATCH] D98773: [X86] Fix compile time regression of D93594.

Nikita Popov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 17 04:40:04 PDT 2021


nikic added inline comments.


================
Comment at: llvm/lib/Target/X86/X86LowerAMXIntrinsics.cpp:520
-    AU.addRequired<LoopInfoWrapperPass>();
-    AU.addPreserved<LoopInfoWrapperPass>();
     AU.addRequired<TargetPassConfig>();
----------------
I believe you should still keep the addPreserved here. You do preserve it if it already exists.


================
Comment at: llvm/lib/Target/X86/X86LowerAMXIntrinsics.cpp:525
+    auto *DTWP = getAnalysisIfAvailable<DominatorTreeWrapperPass>();
+    auto *DT = DTWP ? &DTWP->getDomTree() : nullptr;
+    auto *LIWP = getAnalysisIfAvailable<LoopInfoWrapperPass>();
----------------
I would create a DTU already here and pass it in (it's okay to create a DTU of nullptr). Otherwise the "lazy" strategy will actually be eager, as your DTU object is immediately destroyed.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D98773



More information about the llvm-commits mailing list