1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2025-02-01 05:01:59 +01:00
Eli Friedman ffa26401ac StoreInst should store Align, not MaybeAlign
This is D77454, except for stores.  All the infrastructure work was done
for loads, so the remaining changes necessary are relatively small.

Differential Revision: https://reviews.llvm.org/D79968
2020-05-15 12:26:58 -07:00

27 lines
545 B
LLVM

; RUN: opt < %s -debugify -instcombine -S | FileCheck %s
declare i32 @escape(i32)
; CHECK-LABEL: define {{.*}}@foo(
define i32 @foo() {
entry:
%baz = alloca i32
br i1 undef, label %lhs, label %rhs
lhs:
store i32 1, i32* %baz
br label %cleanup
rhs:
store i32 2, i32* %baz
br label %cleanup
cleanup:
; CHECK: %storemerge = phi i32 [ 2, %rhs ], [ 1, %lhs ], !dbg [[merge_loc:![0-9]+]]
%baz.val = load i32, i32* %baz
%ret.val = call i32 @escape(i32 %baz.val)
ret i32 %ret.val
}
; CHECK: [[merge_loc]] = !DILocation(line: 0