[PATCH] D135376: [Transforms/ObjCARC] Fix non-deterministic output of `ObjCARCOptPass`

Argyrios Kyrtzidis via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Oct 14 10:41:55 PDT 2022


akyrtzi added inline comments.


================
Comment at: llvm/test/Transforms/ObjCARC/related-check.ll:110
+if.end18:                                         ; preds = %if.else, %if.then13
+  %.pre-phi = phi i8* [ null, %if.else ], [ %7, %if.then13 ]
+  %9 = bitcast %0* %name.0 to i8*
----------------
ahatanak wrote:
> Instead of running opt twice and comparing the output using diff, you can just check (using FileCheck) that the phi in this block is eliminated and the release below (the second one) is moved.
This test is less about the specific effects of the transformation and more about checking that the behavior of the transformation is deterministic.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D135376



More information about the llvm-commits mailing list