[PATCH] D142168: [mlgo] Stream the training data

Mircea Trofin via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Feb 3 18:02:10 PST 2023


mtrofin added inline comments.


================
Comment at: llvm/lib/CodeGen/MLRegallocEvictAdvisor.cpp:468-469
+    if (Log->currentContext() != MF.getName()) {
+      MF.getFunction().getContext().emitError(
+          "The training log context shouldn't have had changed.");
+    }
----------------
MatzeB wrote:
> I think I am hitting this for cases where `RegAllocGreedy` bails out early in the `if (!hasVirtRegAlloc()) return false;` check and never initializes the advisor.
> 
> Replacing with `Log->switchCurrentContext()` for my experiments...
ack. I'll take a look. Probably in that case `(!hasVirtRegAlloc())` there's also no output to log, right?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D142168



More information about the llvm-commits mailing list