File: pr55308.ll

package info (click to toggle)
llvm-toolchain-15 1%3A15.0.6-4
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 1,554,644 kB
  • sloc: cpp: 5,922,452; ansic: 1,012,136; asm: 674,362; python: 191,568; objc: 73,855; f90: 42,327; lisp: 31,913; pascal: 11,973; javascript: 10,144; sh: 9,421; perl: 7,447; ml: 5,527; awk: 3,523; makefile: 2,520; xml: 885; cs: 573; fortran: 567
file content (25 lines) | stat: -rw-r--r-- 1,204 bytes parent folder | download
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
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt -passes=rewrite-statepoints-for-gc -S < %s | FileCheck %s

define void @test() gc "statepoint-example" personality i32* ()* @zot{
; CHECK-LABEL: @test(
; CHECK-NEXT:  bb:
; CHECK-NEXT:    [[TMP:%.*]] = freeze i8 addrspace(1)* undef
; CHECK-NEXT:    [[TMP3:%.*]] = getelementptr inbounds i8, i8 addrspace(1)* [[TMP]], i64 16
; CHECK-NEXT:    [[TMP4:%.*]] = bitcast i8 addrspace(1)* [[TMP3]] to i32 addrspace(1)*
; CHECK-NEXT:    [[STATEPOINT_TOKEN:%.*]] = call token (i64, i32, void ()*, i32, i32, ...) @llvm.experimental.gc.statepoint.p0f_isVoidf(i64 2882400000, i32 0, void ()* elementtype(void ()) @wibble, i32 0, i32 0, i32 0, i32 0) [ "deopt"() ]
; CHECK-NEXT:    [[TMP5:%.*]] = getelementptr inbounds i32, i32 addrspace(1)* [[TMP4]], i64 undef
; CHECK-NEXT:    ret void
;
bb:
  %tmp = freeze i8 addrspace(1)* undef
  %tmp3 = getelementptr inbounds i8, i8 addrspace(1)* %tmp, i64 16
  %tmp4 = bitcast i8 addrspace(1)* %tmp3 to i32 addrspace(1)*
  call void @wibble() #3 [ "deopt"() ]
  %tmp5 = getelementptr inbounds i32, i32 addrspace(1)* %tmp4, i64 undef
  ret void
}

declare i32* @zot()

declare void @wibble()