Skip to content

Commit

Permalink
TestMakeInterface
Browse files Browse the repository at this point in the history
  • Loading branch information
xushiwei committed May 31, 2024
1 parent 76c1800 commit 6fb4802
Showing 1 changed file with 0 additions and 32 deletions.
32 changes: 0 additions & 32 deletions ssa/cl_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,38 +57,6 @@ func TestMakeInterface(t *testing.T) {
b.MakeInterface(prog.Any(), prog.IntVal(100, prog.Int64()))
b.MakeInterface(prog.Any(), prog.FloatVal(100, prog.Float64()))
b.Return()
ssatest.Assert(t, pkg, `; ModuleID = 'foo'
source_filename = "foo"
%"github.com/goplus/llgo/internal/runtime.eface" = type { ptr, ptr }
define void @main() {
_llgo_0:
%0 = call ptr @"github.com/goplus/llgo/internal/runtime.Basic"(i64 6)
%1 = call ptr @"github.com/goplus/llgo/internal/runtime.AllocU"(i64 8)
store i64 100, ptr %1, align 4
%2 = alloca %"github.com/goplus/llgo/internal/runtime.eface", align 8
%3 = getelementptr inbounds %"github.com/goplus/llgo/internal/runtime.eface", ptr %2, i32 0, i32 0
store ptr %0, ptr %3, align 8
%4 = getelementptr inbounds %"github.com/goplus/llgo/internal/runtime.eface", ptr %2, i32 0, i32 1
store ptr %1, ptr %4, align 8
%5 = load %"github.com/goplus/llgo/internal/runtime.eface", ptr %2, align 8
%6 = call ptr @"github.com/goplus/llgo/internal/runtime.Basic"(i64 14)
%7 = call ptr @"github.com/goplus/llgo/internal/runtime.AllocU"(i64 8)
store double 1.000000e+02, ptr %7, align 8
%8 = alloca %"github.com/goplus/llgo/internal/runtime.eface", align 8
%9 = getelementptr inbounds %"github.com/goplus/llgo/internal/runtime.eface", ptr %8, i32 0, i32 0
store ptr %6, ptr %9, align 8
%10 = getelementptr inbounds %"github.com/goplus/llgo/internal/runtime.eface", ptr %8, i32 0, i32 1
store ptr %7, ptr %10, align 8
%11 = load %"github.com/goplus/llgo/internal/runtime.eface", ptr %8, align 8
ret void
}
declare ptr @"github.com/goplus/llgo/internal/runtime.Basic"(i64)
declare ptr @"github.com/goplus/llgo/internal/runtime.AllocU"(i64)
`)
}

/*
Expand Down

0 comments on commit 6fb4802

Please sign in to comment.