[PATCH] D32208: [GVN] Don't coerce non-integral pointers to integers or vice versa

Sanjoy Das via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Apr 18 22:47:39 PDT 2017


sanjoy added inline comments.


================
Comment at: test/Transforms/NewGVN/non-integral-pointers.ll:25-28
+; CHECK-LABEL: @f1(
+; CHECK-NOT: inttoptr
+; CHECK-NOT: ptrtoint
+ entry:
----------------
davide wrote:
> I think a test made only of `CHECK-NOT` is a little brittle. Can you expand it a bit?
I could expand it to CHECK for what GVN generates here (IIRC it does not do anything), but that would mislead the reader about the purpose of this test.  This test is really intended to check that GVN did //not// generate `inttoptr` or `ptrtoint`, so I think a `CHECK-NOT` based test is appropriate here.


https://reviews.llvm.org/D32208





More information about the llvm-commits mailing list