[llvm] [ExtendLifetimes] Implement llvm.fake.use to extend variable lifetimes (PR #86149)
Felipe de Azevedo Piovezan via llvm-commits
llvm-commits at lists.llvm.org
Thu Mar 21 10:18:49 PDT 2024
felipepiovezan wrote:
> > I only skimmed the diff, but noticed there is no global isel lowering here. Were there any challenges in doing that or was it not considered?
>
> I wasn't the original patch writer, but I think it would be the latter. I'm not familiar with the internals of GlobalISel, so I'm not sure how confident I'd be implementing support for fake use there myself - though FWIW, since it's a no-op it's mostly just filling in the boilerplate, with a few more complex cases (such as moving fake uses before tail calls).
The reason I asked is -- and I could be wrong -- that GlobalISel will give up and fall back to SelectionDAG when it seems something it doesn't know how to lower. That usually happens in IRTranslator.cpp:
```
if (translate(Inst))
continue;
...
reportTranslationError(*MF, *TPC, *ORE, R);
return false;
}
```
So, depending on how/when these intrinsics are generated, this patch could affect a few different targets.
https://github.com/llvm/llvm-project/pull/86149
More information about the llvm-commits
mailing list