[PATCH] D139213: [llvm][CUDA] Make NVVM Reflect pass look inside ptr casting

Hugh Delaney via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Dec 2 11:02:30 PST 2022


hdelan added inline comments.


================
Comment at: llvm/include/llvm/IR/InstrTypes.h:1407
+    if (auto *Operand = getCalledOperand())
+      return dyn_cast_or_null<Function>(Operand->stripPointerCasts());
+    return nullptr;
----------------
tra wrote:
> Does it need a type check as it's done in `getCalledFunction()` above after a similar cast?
The type checking above is checking that the operands match for the function and the call. However because we are removing ptr casts the operands will be different for the call and the func with removed ptr casts


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D139213



More information about the llvm-commits mailing list