[PATCH] D97665: [InstSimplify] Don't fold comparisons of non-inbounds GEPs

LemonBoy via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Mar 1 01:14:41 PST 2021


LemonBoy added inline comments.


================
Comment at: llvm/lib/IR/ConstantFold.cpp:1837
+      // The foldings below assume the GEP to be inbounds.
+      // TODO: Some of the logic can be applied for non-inbounds GEPs as well.
+      if (!CE1GEP->isInBounds())
----------------
Are non-inbounds GEP common enough to implement this?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D97665



More information about the llvm-commits mailing list