[PATCH] D149191: [CodeGen][MachineLastInstrsCleanup] fix INLINEASM_BR hazard

Nick Desaulniers via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Apr 26 15:12:38 PDT 2023


nickdesaulniers added a comment.

In D149191#4300468 <https://reviews.llvm.org/D149191#4300468>, @efriedma wrote:

> If I'm following correctly, the issue is specifically with definitions after the INLINEASM_BR (which only execute in the fallthrough case)? In that case, you could theoretically still do some sort of analysis... but it gets a lot more complicated, so this fix seems sufficient.  LGTM

Yeah, this should be something quick that is low risk for a backport.  I started hacking up the more precise fix, but it turns out you need to find the corresponding INLINEASM_BR in the pred MBB (could be multiple) and check which dominates. That doesn't seem as low risk as this for backporting.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D149191



More information about the llvm-commits mailing list