[PATCH] D82249: [HWASan] Disable GlobalISel/FastISel for HWASan Globals.

Evgenii Stepanov via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Jun 23 15:05:10 PDT 2020


eugenis added a comment.

In D82249#2110054 <https://reviews.llvm.org/D82249#2110054>, @hctim wrote:

> In D82249#2109920 <https://reviews.llvm.org/D82249#2109920>, @eugenis wrote:
>
> > I'm OK with this as a workaround, but it would be more natural to detect the unsupported IR pattern in globalisel and fall back instead of disabling it entirely. Is it difficult to do for some reason?
>
>
> Eh, it's not an unsupported IR pattern that's the problem, it's that the IR is lowered into `adrp + add` so that the `add` can be folded into a `ldr/str` as an offset. IMO on the scale of "painting over the problem vs. fixing it", this patch is 100% paint, forced fallback with `MO_TAGGED` is 80% paint for maybe 60% of the work of just fixing it.
>
> I'm working on fixing this properly now that we know we don't need to make a less-risky, fast-to-deploy patch. If that all falls into place this patchset will just become obsolete anyway.


Right, well, there is an IR pattern that is not handled correctly in globalisel. Let's call it "unsupported". A better way to work around that is to detect this pattern in globalisel and fall back.

If you can fix the underlying problem, that's even better, of course.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D82249





More information about the cfe-commits mailing list