<feed xmlns='http://www.w3.org/2005/Atom'>
<title>llvm-project.git/llvm/lib/Target/WebAssembly/WebAssemblyInstrRef.td, branch main</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.
</subtitle>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/'/>
<entry>
<title>Add support for ref.func to AsmParser/MC (#163326)</title>
<updated>2025-11-06T00:39:37+00:00</updated>
<author>
<name>Demetrius Kanios</name>
<email>demetrius@kanios.net</email>
</author>
<published>2025-11-06T00:39:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=1262dce1fddf7b8e6396d1359b574d36b8992d87'/>
<id>1262dce1fddf7b8e6396d1359b574d36b8992d87</id>
<content type='text'>
This is step 1 of exposing WASM `ref.func` to LLVM.

This PR only handles creating the instruction and a test for assembling
it.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This is step 1 of exposing WASM `ref.func` to LLVM.

This PR only handles creating the instruction and a test for assembling
it.</pre>
</div>
</content>
</entry>
<entry>
<title>[WebAssembly,clang] Add __builtin_wasm_test_function_pointer_signature (#150201)</title>
<updated>2025-07-25T23:52:39+00:00</updated>
<author>
<name>Hood Chatham</name>
<email>roberthoodchatham@gmail.com</email>
</author>
<published>2025-07-25T23:52:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=15b03687ff655e2e64afb8554645457d2e4cabd7'/>
<id>15b03687ff655e2e64afb8554645457d2e4cabd7</id>
<content type='text'>
Tests if the runtime type of the function pointer matches the static
type. If this returns false, calling the function pointer will trap.
Uses `@llvm.wasm.ref.test.func` added in #147486.

Also adds a "gc" wasm feature to gate the use of the ref.test
instruction.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Tests if the runtime type of the function pointer matches the static
type. If this returns false, calling the function pointer will trap.
Uses `@llvm.wasm.ref.test.func` added in #147486.

Also adds a "gc" wasm feature to gate the use of the ref.test
instruction.
</pre>
</div>
</content>
</entry>
<entry>
<title>[WebAssembly,MC] Add ref.test_func handling to AsmParser (#139642)</title>
<updated>2025-07-07T20:31:57+00:00</updated>
<author>
<name>Hood Chatham</name>
<email>roberthoodchatham@gmail.com</email>
</author>
<published>2025-07-07T20:31:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=42d079e16ebd4da1f76488df6da2fd2750d4f898'/>
<id>42d079e16ebd4da1f76488df6da2fd2750d4f898</id>
<content type='text'>
This will allow us to eliminate the hand-coded webassembly here:

https://github.com/python/cpython/blob/main/Python/emscripten_trampoline.c#L138
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This will allow us to eliminate the hand-coded webassembly here:

https://github.com/python/cpython/blob/main/Python/emscripten_trampoline.c#L138
</pre>
</div>
</content>
</entry>
<entry>
<title>[WebAssembly] Add exnref type (#93586)</title>
<updated>2024-05-28T23:10:11+00:00</updated>
<author>
<name>Heejin Ahn</name>
<email>aheejin@gmail.com</email>
</author>
<published>2024-05-28T23:10:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=c179d50fd3d84311708701d84e3bca60570d3d7f'/>
<id>c179d50fd3d84311708701d84e3bca60570d3d7f</id>
<content type='text'>
This adds (back) the exnref type restored in the new EH proposal adopted
in Oct 2023 CG meeting:

https://github.com/WebAssembly/exception-handling/blob/main/proposals/exception-handling/Exceptions.md:x</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This adds (back) the exnref type restored in the new EH proposal adopted
in Oct 2023 CG meeting:

https://github.com/WebAssembly/exception-handling/blob/main/proposals/exception-handling/Exceptions.md:x</pre>
</div>
</content>
</entry>
<entry>
<title>[WebAssembly] Implement ref.is_null MC layer support and codegen</title>
<updated>2022-05-13T06:08:10+00:00</updated>
<author>
<name>Alex Bradbury</name>
<email>asb@igalia.com</email>
</author>
<published>2022-05-13T05:55:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=cb778e9328292b7cfa4e0b43f26e4d1091923a39'/>
<id>cb778e9328292b7cfa4e0b43f26e4d1091923a39</id>
<content type='text'>
Custom type-checking (in WebAssemblyAsmTypeCheck.cpp) is used to
workaround the fact that separate variants of the instruction are
defined for externref and funcref.

Based on an initial patch by Paulo Matos &lt;pmatos@igalia.com&gt;.

Differential Revision: https://reviews.llvm.org/D123484
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Custom type-checking (in WebAssemblyAsmTypeCheck.cpp) is used to
workaround the fact that separate variants of the instruction are
defined for externref and funcref.

Based on an initial patch by Paulo Matos &lt;pmatos@igalia.com&gt;.

Differential Revision: https://reviews.llvm.org/D123484
</pre>
</div>
</content>
</entry>
<entry>
<title>[WebAssembly] Implementation of intrinsic for ref.null and HeapType removal</title>
<updated>2021-12-06T08:46:15+00:00</updated>
<author>
<name>Paulo Matos</name>
<email>pmatos@igalia.com</email>
</author>
<published>2021-12-05T12:50:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=a96d8285101546c92116246939c2d53c57b88cf0'/>
<id>a96d8285101546c92116246939c2d53c57b88cf0</id>
<content type='text'>
This patch implements the intrinsic for ref.null.
In the process of implementing int_wasm_ref_null_func() and
int_wasm_ref_null_extern() intrinsics, it removes the redundant
HeapType.

This also causes the textual assembler syntax for ref.null to
change. Instead of receiving an argument: `func` or `extern`, the
instruction mnemonic is either ref.null_func or ref.null_extern,
without the need for a further operand.

Reviewed By: tlively

Differential Revision: https://reviews.llvm.org/D114979
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch implements the intrinsic for ref.null.
In the process of implementing int_wasm_ref_null_func() and
int_wasm_ref_null_extern() intrinsics, it removes the redundant
HeapType.

This also causes the textual assembler syntax for ref.null to
change. Instead of receiving an argument: `func` or `extern`, the
instruction mnemonic is either ref.null_func or ref.null_extern,
without the need for a further operand.

Reviewed By: tlively

Differential Revision: https://reviews.llvm.org/D114979
</pre>
</div>
</content>
</entry>
<entry>
<title>[WebAssembly] Support for WebAssembly globals in LLVM IR</title>
<updated>2021-05-11T09:19:29+00:00</updated>
<author>
<name>Paulo Matos</name>
<email>pmatos@igalia.com</email>
</author>
<published>2021-05-04T12:13:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=d7086af2143d58a6535e0837c4d8789c69c6985f'/>
<id>d7086af2143d58a6535e0837c4d8789c69c6985f</id>
<content type='text'>
This patch adds support for WebAssembly globals in LLVM IR, representing
them as pointers to global values, in a non-default, non-integral
address space.  Instruction selection legalizes loads and stores to
these pointers to new WebAssemblyISD nodes GLOBAL_GET and GLOBAL_SET.
Once the lowering creates the new nodes, tablegen pattern matches those
and converts them to Wasm global.get/set of the appropriate type.

Based on work by Paulo Matos in https://reviews.llvm.org/D95425.

Reviewed By: pmatos

Differential Revision: https://reviews.llvm.org/D101608
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch adds support for WebAssembly globals in LLVM IR, representing
them as pointers to global values, in a non-default, non-integral
address space.  Instruction selection legalizes loads and stores to
these pointers to new WebAssemblyISD nodes GLOBAL_GET and GLOBAL_SET.
Once the lowering creates the new nodes, tablegen pattern matches those
and converts them to Wasm global.get/set of the appropriate type.

Based on work by Paulo Matos in https://reviews.llvm.org/D95425.

Reviewed By: pmatos

Differential Revision: https://reviews.llvm.org/D101608
</pre>
</div>
</content>
</entry>
<entry>
<title>[WebAssembly] Remove exnref and br_on_exn</title>
<updated>2021-01-09T10:02:54+00:00</updated>
<author>
<name>Heejin Ahn</name>
<email>aheejin@gmail.com</email>
</author>
<published>2020-12-26T04:23:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=52e240a0721e4120a7143f6f5bab4760d28d48e8'/>
<id>52e240a0721e4120a7143f6f5bab4760d28d48e8</id>
<content type='text'>
This removes `exnref` type and `br_on_exn` instruction. This is
effectively NFC because most uses of these were already removed in the
previous CLs.

Reviewed By: dschuff, tlively

Differential Revision: https://reviews.llvm.org/D94041
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This removes `exnref` type and `br_on_exn` instruction. This is
effectively NFC because most uses of these were already removed in the
previous CLs.

Reviewed By: dschuff, tlively

Differential Revision: https://reviews.llvm.org/D94041
</pre>
</div>
</content>
</entry>
<entry>
<title>[WebAssembly] Support select and block for reference types</title>
<updated>2020-12-02T03:16:57+00:00</updated>
<author>
<name>Heejin Ahn</name>
<email>aheejin@gmail.com</email>
</author>
<published>2020-11-30T09:39:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=60653e24b6297f2830b9de649f575840ecb364b6'/>
<id>60653e24b6297f2830b9de649f575840ecb364b6</id>
<content type='text'>
This adds missing `select` instruction support and block return type
support for reference types. Also refactors WebAssemblyInstrRef.td and
rearranges tests in reference-types.s. Tests don't include `exnref`
types, because we currently don't support `exnref` for `ref.null` and
the type will be removed soon anyway.

Reviewed By: tlively, sbc100, wingo

Differential Revision: https://reviews.llvm.org/D92359
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This adds missing `select` instruction support and block return type
support for reference types. Also refactors WebAssemblyInstrRef.td and
rearranges tests in reference-types.s. Tests don't include `exnref`
types, because we currently don't support `exnref` for `ref.null` and
the type will be removed soon anyway.

Reviewed By: tlively, sbc100, wingo

Differential Revision: https://reviews.llvm.org/D92359
</pre>
</div>
</content>
</entry>
<entry>
<title>[WebAssembly] Implement ref.null</title>
<updated>2020-11-03T18:46:23+00:00</updated>
<author>
<name>Andy Wingo</name>
<email>wingo@igalia.com</email>
</author>
<published>2020-11-03T18:46:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=107c3a12d627f12a23f138a00d6aabe9de7402f7'/>
<id>107c3a12d627f12a23f138a00d6aabe9de7402f7</id>
<content type='text'>
This patch adds a new "heap type" operand kind to the WebAssembly MC
layer, used by ref.null. Currently the possible values are "extern" and
"func"; when typed function references come, though, this operand may be
a type index.

Note that the "heap type" production is still known as "refedtype" in
the draft proposal; changing its name in the spec is
ongoing (https://github.com/WebAssembly/reference-types/issues/123).

The register form of ref.null is still untested.

Differential Revision: https://reviews.llvm.org/D90608
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch adds a new "heap type" operand kind to the WebAssembly MC
layer, used by ref.null. Currently the possible values are "extern" and
"func"; when typed function references come, though, this operand may be
a type index.

Note that the "heap type" production is still known as "refedtype" in
the draft proposal; changing its name in the spec is
ongoing (https://github.com/WebAssembly/reference-types/issues/123).

The register form of ref.null is still untested.

Differential Revision: https://reviews.llvm.org/D90608
</pre>
</div>
</content>
</entry>
</feed>
