|
1 | 1 | ; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 5 |
2 | | -; RUN: opt <%s -mtriple=arm-none-eabi -passes=globalopt -S | FileCheck %s |
| 2 | +; RUN: opt < %s -mtriple=arm-none-eabi -passes=globalopt -S | FileCheck %s |
3 | 3 |
|
4 | | -@.i8 = private unnamed_addr constant [3 x i8] [i8 1, i8 2, i8 3] , align 1 |
| 4 | +; CHECK: [3 x i8] |
5 | 5 | @other = private unnamed_addr global [3 x i8] [i8 1, i8 2, i8 3] , align 1 |
| 6 | +; CHECK: [4 x i8] |
| 7 | +@.i8 = private unnamed_addr constant [3 x i8] [i8 1, i8 2, i8 3] , align 1 |
6 | 8 |
|
7 | 9 | define void @memcpy_multiple() { |
8 | 10 | ; CHECK-LABEL: define void @memcpy_multiple() local_unnamed_addr { |
9 | 11 | ; CHECK-NEXT: [[ENTRY:.*:]] |
10 | 12 | ; CHECK-NEXT: [[SOMETHING:%.*]] = alloca [4 x i8], align 1 |
11 | | -; CHECK-NEXT: call void @llvm.memcpy.p0.p0.i32(ptr noundef nonnull align 1 dereferenceable(3) [[SOMETHING]], ptr noundef nonnull align 1 dereferenceable(3) @.i8, i32 4, i1 false) |
12 | | -; CHECK-NEXT: call void @llvm.memcpy.p0.p0.i32(ptr noundef nonnull align 1 dereferenceable(3) @other, ptr noundef nonnull align 1 dereferenceable(3) @.i8, i32 4, i1 false) |
13 | 13 | ; CHECK-NEXT: [[CALL2:%.*]] = call i32 @bar(ptr nonnull [[SOMETHING]]) |
| 14 | +; CHECK-NEXT: [[CALL3:%.*]] = call i32 @bar(ptr nonnull @other) |
| 15 | +; CHECK-NEXT: call void @llvm.memcpy.p0.p0.i32(ptr noundef nonnull align 1 dereferenceable(3) @other, ptr noundef nonnull align 1 dereferenceable(3) @.i8, i32 3, i1 false) |
| 16 | +; CHECK-NEXT: call void @llvm.memcpy.p0.p0.i32(ptr noundef nonnull align 1 dereferenceable(3) [[SOMETHING]], ptr noundef nonnull align 1 dereferenceable(3) @.i8, i32 4, i1 false) |
14 | 17 | ; CHECK-NEXT: ret void |
15 | 18 | ; |
16 | 19 | entry: |
17 | 20 | %something = alloca [3 x i8], align 1 |
18 | | - call void @llvm.memcpy.p0.p0.i32(ptr noundef nonnull align 1 dereferenceable(3) %something, ptr noundef nonnull align 1 dereferenceable(3) @.i8, i32 3, i1 false) |
| 21 | + %call1 = call i32 @bar(ptr nonnull %something) |
| 22 | + %call2 = call i32 @bar(ptr nonnull @other) |
19 | 23 | call void @llvm.memcpy.p0.p0.i32(ptr noundef nonnull align 1 dereferenceable(3) @other, ptr noundef nonnull align 1 dereferenceable(3) @.i8, i32 3, i1 false) |
20 | | - %call2 = call i32 @bar(ptr nonnull %something) |
| 24 | + call void @llvm.memcpy.p0.p0.i32(ptr noundef nonnull align 1 dereferenceable(3) %something, ptr noundef nonnull align 1 dereferenceable(3) @.i8, i32 3, i1 false) |
21 | 25 | ret void |
22 | 26 | } |
23 | 27 |
|
|
0 commit comments