diff options
author | Nia Waldvogel <[email protected]> | 2021-12-31 14:53:19 -0500 |
---|---|---|
committer | Nia <[email protected]> | 2022-01-19 14:42:02 -0500 |
commit | c6ae1c58fcb2f2a70a6d31e7319a1e9dadfe715f (patch) | |
tree | 73f1e52e0cff4a784a1fad830d335d82bba026c9 /interp/testdata | |
parent | 0c2fefa09b4b7751d9b325e2418c8813b5929537 (diff) | |
download | tinygo-c6ae1c58fcb2f2a70a6d31e7319a1e9dadfe715f.tar.gz tinygo-c6ae1c58fcb2f2a70a6d31e7319a1e9dadfe715f.zip |
compiler: remove parentHandle from calling convention
This removes the parentHandle argument from the internal calling convention.
It was formerly used to implment coroutines.
Now that coroutines have been removed, it is no longer necessary.
Diffstat (limited to 'interp/testdata')
-rw-r--r-- | interp/testdata/revert.ll | 24 | ||||
-rw-r--r-- | interp/testdata/revert.out.ll | 12 |
2 files changed, 18 insertions, 18 deletions
diff --git a/interp/testdata/revert.ll b/interp/testdata/revert.ll index c8929719b..dc6ee5c2a 100644 --- a/interp/testdata/revert.ll +++ b/interp/testdata/revert.ll @@ -13,27 +13,27 @@ declare void @externalCall(i64) define void @runtime.initAll() unnamed_addr { entry: - call void @baz.init(i8* undef, i8* undef) - call void @foo.init(i8* undef, i8* undef) - call void @bar.init(i8* undef, i8* undef) - call void @main.init(i8* undef, i8* undef) - call void @x.init(i8* undef, i8* undef) - call void @y.init(i8* undef, i8* undef) + call void @baz.init(i8* undef) + call void @foo.init(i8* undef) + call void @bar.init(i8* undef) + call void @main.init(i8* undef) + call void @x.init(i8* undef) + call void @y.init(i8* undef) ret void } -define internal void @foo.init(i8* %context, i8* %parentHandle) unnamed_addr { +define internal void @foo.init(i8* %context) unnamed_addr { store i64 5, i64* @foo.knownAtRuntime unreachable ; this triggers a revert of @foo.init. } -define internal void @bar.init(i8* %context, i8* %parentHandle) unnamed_addr { +define internal void @bar.init(i8* %context) unnamed_addr { %val = load i64, i64* @foo.knownAtRuntime store i64 %val, i64* @bar.knownAtRuntime ret void } -define internal void @baz.init(i8* %context, i8* %parentHandle) unnamed_addr { +define internal void @baz.init(i8* %context) unnamed_addr { ; Test extractvalue/insertvalue with more than one index. %val = load [3 x {i64, i32}], [3 x {i64, i32}]* @baz.someGlobal %part = extractvalue [3 x {i64, i32}] %val, 0, 1 @@ -41,14 +41,14 @@ define internal void @baz.init(i8* %context, i8* %parentHandle) unnamed_addr { unreachable ; trigger revert } -define internal void @main.init(i8* %context, i8* %parentHandle) unnamed_addr { +define internal void @main.init(i8* %context) unnamed_addr { entry: call void @externalCall(i64 3) ret void } -define internal void @x.init(i8* %context, i8* %parentHandle) unnamed_addr { +define internal void @x.init(i8* %context) unnamed_addr { ; Test atomic and volatile memory accesses. store atomic i32 1, i32* @x.atomicNum seq_cst, align 4 %x = load atomic i32, i32* @x.atomicNum seq_cst, align 4 @@ -58,7 +58,7 @@ define internal void @x.init(i8* %context, i8* %parentHandle) unnamed_addr { ret void } -define internal void @y.init(i8* %context, i8* %parentHandle) unnamed_addr { +define internal void @y.init(i8* %context) unnamed_addr { entry: br label %loop diff --git a/interp/testdata/revert.out.ll b/interp/testdata/revert.out.ll index e8fc94858..030734d8e 100644 --- a/interp/testdata/revert.out.ll +++ b/interp/testdata/revert.out.ll @@ -13,8 +13,8 @@ declare void @externalCall(i64) local_unnamed_addr define void @runtime.initAll() unnamed_addr { entry: - call fastcc void @baz.init(i8* undef, i8* undef) - call fastcc void @foo.init(i8* undef, i8* undef) + call fastcc void @baz.init(i8* undef) + call fastcc void @foo.init(i8* undef) %val = load i64, i64* @foo.knownAtRuntime, align 8 store i64 %val, i64* @bar.knownAtRuntime, align 8 call void @externalCall(i64 3) @@ -23,20 +23,20 @@ entry: store i32 %x, i32* @x.atomicNum, align 4 %y = load volatile i32, i32* @x.volatileNum, align 4 store volatile i32 %y, i32* @x.volatileNum, align 4 - call fastcc void @y.init(i8* undef, i8* undef) + call fastcc void @y.init(i8* undef) ret void } -define internal fastcc void @foo.init(i8* %context, i8* %parentHandle) unnamed_addr { +define internal fastcc void @foo.init(i8* %context) unnamed_addr { store i64 5, i64* @foo.knownAtRuntime, align 8 unreachable } -define internal fastcc void @baz.init(i8* %context, i8* %parentHandle) unnamed_addr { +define internal fastcc void @baz.init(i8* %context) unnamed_addr { unreachable } -define internal fastcc void @y.init(i8* %context, i8* %parentHandle) unnamed_addr { +define internal fastcc void @y.init(i8* %context) unnamed_addr { entry: br label %loop |