File: int-uadd-12.ll

package info (click to toggle)
llvm-toolchain-16 1%3A16.0.6-15~deb12u1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 1,634,792 kB
  • sloc: cpp: 6,179,261; ansic: 1,216,205; asm: 741,319; python: 196,614; objc: 75,325; f90: 49,640; lisp: 32,396; pascal: 12,286; sh: 9,394; perl: 7,442; ml: 5,494; awk: 3,523; makefile: 2,723; javascript: 1,206; xml: 886; fortran: 581; cs: 573
file content (34 lines) | stat: -rw-r--r-- 1,620 bytes parent folder | download | duplicates (12)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
; Test that this test case does not abort after the folding of load -> add ->
; store into an alsi. This folding is suppose to not happen as it would
; introduce a loop in the DAG.
;
; RUN: llc < %s -mtriple=s390x-linux-gnu -mcpu=z13 -disable-basic-aa -consthoist-gep | FileCheck %s

@g_295 = external dso_local unnamed_addr global i32, align 4
@g_672 = external dso_local unnamed_addr global i64, align 8
@g_1484 = external dso_local global <{ i8, i64, { i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i32, i8, i8, [2 x i8], i8, i8, i8, i8, i8, i8, i8, i8, i32, i8, i8, i8 }, i32 }>, align 2

define void @fun() {
; CHECK-LABEL: fun:

bb:
  br label %bb1

bb1:                                              ; preds = %bb1, %bb
  store i32 2, ptr getelementptr inbounds (<{ i8, i64, { i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i32, i8, i8, [2 x i8], i8, i8, i8, i8, i8, i8, i8, i8, i32, i8, i8, i8 }, i32 }>, ptr @g_1484, i64 0, i32 2, i32 16)
  %tmp = icmp slt i32 undef, 3
  br i1 %tmp, label %bb1, label %bb2

bb2:                                              ; preds = %bb1
  %tmp3 = load i32, ptr getelementptr inbounds (<{ i8, i64, { i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i32, i8, i8, [2 x i8], i8, i8, i8, i8, i8, i8, i8, i8, i32, i8, i8, i8 }, i32 }>, ptr @g_1484, i64 0, i32 2, i32 28)
  %tmp4 = load i64, ptr @g_672
  %tmp5 = add i64 %tmp4, 1
  store i64 %tmp5, ptr @g_672
  %tmp6 = icmp eq i64 %tmp5, 0
  %tmp7 = zext i1 %tmp6 to i32
  %tmp8 = icmp ult i32 %tmp3, %tmp7
  %tmp9 = zext i1 %tmp8 to i32
  store i32 %tmp9, ptr @g_295
  ret void
}