summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--test/Transforms/InstCombine/cast.ll9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/Transforms/InstCombine/cast.ll b/test/Transforms/InstCombine/cast.ll
index 899ffddd5b..b4eb69d436 100644
--- a/test/Transforms/InstCombine/cast.ll
+++ b/test/Transforms/InstCombine/cast.ll
@@ -891,3 +891,12 @@ define double @test80([100 x double]* %p, i32 %i) {
ret double %l
; CHECK-NEXT: ret double
}
+
+define double @test81(double *%p, float %f) {
+ %i = fptosi float %f to i64
+ %q = bitcast double* %p to i8*
+ %pp = getelementptr i8* %q, i64 %i
+ %r = bitcast i8* %pp to double*
+ %l = load double* %r
+ ret double %l
+}