[PATCH] D147020: [AA] Add a tbaa-fence intrinsic.

Jeroen Dobbelaere via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Mar 30 03:38:03 PDT 2023


jeroen.dobbelaere added a comment.

What exactly are the wanted semantics for such a fence ? And how would it be used ?
Once a pointer is stored into memory, you loose the fence dependency and tbaa does not look into that.

Assume following code:

  int bar (int *p, short *q) {
    *p =42;
    *q =99;
    return *p;
  }
  int foo(int * p) {
     short * q = (short *)tbaa_fence(p);
     return bar(p, q);
  }

This will still return 42


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D147020



More information about the llvm-commits mailing list