[PATCH] D51698: Prevent Constant Folding From Optimizing inrange GEP
Peter Collingbourne via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Sep 5 14:02:54 PDT 2018
pcc added a comment.
Please update the commit message to reflect what this patch is now doing.
================
Comment at: llvm/test/Analysis/ConstantFolding/gep.ll:14
; CHECK-NEXT: load i32 (...)*, i32 (...)** bitcast (i8** getelementptr inbounds ([3 x i8*], [3 x i8*]* @vt, inrange i64 0, i64 2) to i32 (...)**)
%load = load i32 (...)*, i32 (...)** getelementptr (i32 (...)*, i32 (...)** bitcast (i8** getelementptr inbounds ([3 x i8*], [3 x i8*]* @vt, inrange i64 0, i64 1) to i32 (...)**), i64 1)
ret i32 (...)* %load
----------------
Can you update the other tests to return the pointer instead of loading?
https://reviews.llvm.org/D51698
More information about the llvm-commits
mailing list