2025-01-13 10:38:46 +08:00
|
|
|
; ModuleID = 'github.com/goplus/llgo/compiler/cl/_testrt/cstr'
|
|
|
|
|
source_filename = "github.com/goplus/llgo/compiler/cl/_testrt/cstr"
|
2024-04-29 13:59:06 +08:00
|
|
|
|
2025-01-13 10:38:46 +08:00
|
|
|
@"github.com/goplus/llgo/compiler/cl/_testrt/cstr.init$guard" = global i1 false, align 1
|
2024-04-29 14:34:26 +08:00
|
|
|
@0 = private unnamed_addr constant [14 x i8] c"Hello, world\0A\00", align 1
|
2024-04-29 13:59:06 +08:00
|
|
|
|
2025-01-13 10:38:46 +08:00
|
|
|
define void @"github.com/goplus/llgo/compiler/cl/_testrt/cstr.init"() {
|
2024-04-29 13:59:06 +08:00
|
|
|
_llgo_0:
|
2025-01-13 10:38:46 +08:00
|
|
|
%0 = load i1, ptr @"github.com/goplus/llgo/compiler/cl/_testrt/cstr.init$guard", align 1
|
2024-04-29 13:59:06 +08:00
|
|
|
br i1 %0, label %_llgo_2, label %_llgo_1
|
|
|
|
|
|
|
|
|
|
_llgo_1: ; preds = %_llgo_0
|
2025-01-13 10:38:46 +08:00
|
|
|
store i1 true, ptr @"github.com/goplus/llgo/compiler/cl/_testrt/cstr.init$guard", align 1
|
2024-04-29 13:59:06 +08:00
|
|
|
br label %_llgo_2
|
|
|
|
|
|
|
|
|
|
_llgo_2: ; preds = %_llgo_1, %_llgo_0
|
|
|
|
|
ret void
|
|
|
|
|
}
|
|
|
|
|
|
2025-01-13 10:38:46 +08:00
|
|
|
define void @"github.com/goplus/llgo/compiler/cl/_testrt/cstr.main"() {
|
2024-04-29 13:59:06 +08:00
|
|
|
_llgo_0:
|
2024-04-29 14:34:26 +08:00
|
|
|
call void (ptr, ...) @printf(ptr @0)
|
2025-01-13 10:38:46 +08:00
|
|
|
ret void
|
2024-04-29 13:59:06 +08:00
|
|
|
}
|
|
|
|
|
|
2024-05-05 21:33:04 +08:00
|
|
|
declare void @printf(ptr, ...)
|