<feed xmlns='http://www.w3.org/2005/Atom'>
<title>llvm-project.git/llvm/lib/Target/AMDGPU/AMDGPUHSAMetadataStreamer.h, branch users/nico/python-2</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>AMDGPU: Move enqueued block handling into clang (#128519)</title>
<updated>2025-03-10T12:54:04+00:00</updated>
<author>
<name>Matt Arsenault</name>
<email>Matthew.Arsenault@amd.com</email>
</author>
<published>2025-03-10T12:54:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=0d2c55cb9682dc589949fb6767e50c4efb538f2d'/>
<id>0d2c55cb9682dc589949fb6767e50c4efb538f2d</id>
<content type='text'>
The previous implementation wasn't maintaining a faithful IR
representation of how this really works. The value returned by
createEnqueuedBlockKernel wasn't actually used as a function, and
hacked up later to be a pointer to the runtime handle global
variable. In reality, the enqueued block is a struct where the first
field is a pointer to the kernel descriptor, not the kernel itself. We
were also relying on passing around a reference to a global using a
string attribute containing its name. It's better to base this on a
proper IR symbol reference during final emission.

This now avoids using a function attribute on kernels and avoids using
the additional "runtime-handle" attribute to populate the final
metadata. Instead, associate the runtime handle reference to the
kernel with the !associated global metadata. We can then get a final,
correctly mangled name at the end.

I couldn't figure out how to get rename-with-external-symbol behavior
using a combination of comdats and aliases, so leaves an IR pass to
externalize the runtime handles for codegen. If anything breaks, it's
most likely this, so leave avoiding this for a later step. Use a
special section name to enable this behavior. This also means it's
possible to declare enqueuable kernels in source without going through
the dedicated block syntax or other dedicated compiler support.

We could move towards initializing the runtime handle in the
compiler/linker. I have a working patch where the linker sets up the
first field of the handle, avoiding the need to export the block
kernel symbol for the runtime. We would need new relocations to get
the private and group sizes, but that would avoid the runtime's
special case handling that requires the device_enqueue_symbol metadata
field.

https://reviews.llvm.org/D141700</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The previous implementation wasn't maintaining a faithful IR
representation of how this really works. The value returned by
createEnqueuedBlockKernel wasn't actually used as a function, and
hacked up later to be a pointer to the runtime handle global
variable. In reality, the enqueued block is a struct where the first
field is a pointer to the kernel descriptor, not the kernel itself. We
were also relying on passing around a reference to a global using a
string attribute containing its name. It's better to base this on a
proper IR symbol reference during final emission.

This now avoids using a function attribute on kernels and avoids using
the additional "runtime-handle" attribute to populate the final
metadata. Instead, associate the runtime handle reference to the
kernel with the !associated global metadata. We can then get a final,
correctly mangled name at the end.

I couldn't figure out how to get rename-with-external-symbol behavior
using a combination of comdats and aliases, so leaves an IR pass to
externalize the runtime handles for codegen. If anything breaks, it's
most likely this, so leave avoiding this for a later step. Use a
special section name to enable this behavior. This also means it's
possible to declare enqueuable kernels in source without going through
the dedicated block syntax or other dedicated compiler support.

We could move towards initializing the runtime handle in the
compiler/linker. I have a working patch where the linker sets up the
first field of the handle, avoiding the need to export the block
kernel symbol for the runtime. We would need new relocations to get
the private and group sizes, but that would avoid the runtime's
special case handling that requires the device_enqueue_symbol metadata
field.

https://reviews.llvm.org/D141700</pre>
</div>
</content>
</entry>
<entry>
<title>[AMDGPU] MCExpr-ify AMDGPU HSAMetadata (#94788)</title>
<updated>2024-06-26T15:39:08+00:00</updated>
<author>
<name>Janek van Oirschot</name>
<email>janek.vanoirschot@amd.com</email>
</author>
<published>2024-06-26T15:39:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=17eaa23f7ecdfe79ad74552aaa260e6ce32432c2'/>
<id>17eaa23f7ecdfe79ad74552aaa260e6ce32432c2</id>
<content type='text'>
Enables MCExpr for HSAMetadata, particularly, HSAMetadata's msgpack format.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Enables MCExpr for HSAMetadata, particularly, HSAMetadata's msgpack format.</pre>
</div>
</content>
</entry>
<entry>
<title>[AMDGPU] Fix unittest linking error with `LLVM_LINK_LLVM_DYLIB` (#91727)</title>
<updated>2024-05-11T07:18:05+00:00</updated>
<author>
<name>Jonas Hahnfeld</name>
<email>jonas.hahnfeld@cern.ch</email>
</author>
<published>2024-05-11T07:18:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=52c5a81001663d4ca8fca5e7b1634a6a5b0bd021'/>
<id>52c5a81001663d4ca8fca5e7b1634a6a5b0bd021</id>
<content type='text'>
Follow-up to https://github.com/llvm/llvm-project/pull/88257</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Follow-up to https://github.com/llvm/llvm-project/pull/88257</pre>
</div>
</content>
</entry>
<entry>
<title>[AMDGPU] Introduce Code Object V6 (#76954)</title>
<updated>2024-02-05T07:19:53+00:00</updated>
<author>
<name>Pierre van Houtryve</name>
<email>pierre.vanhoutryve@amd.com</email>
</author>
<published>2024-02-05T07:19:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=500846d2f542c93e349161a39a1baae0f1f6fad0'/>
<id>500846d2f542c93e349161a39a1baae0f1f6fad0</id>
<content type='text'>
Introduce Code Object V6 in Clang, LLD, Flang and LLVM. This is the same
as V5 except a new "generic version" flag can be present in EFLAGS. This
is related to new generic targets that'll be added in a follow-up patch.
It's also likely V6 will have new changes (possibly new metadata
entries) added later.

Docs change are part of the follow-up patch #76955</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Introduce Code Object V6 in Clang, LLD, Flang and LLVM. This is the same
as V5 except a new "generic version" flag can be present in EFLAGS. This
is related to new generic targets that'll be added in a follow-up patch.
It's also likely V6 will have new changes (possibly new metadata
entries) added later.

Docs change are part of the follow-up patch #76955</pre>
</div>
</content>
</entry>
<entry>
<title>[Target] Remove unused forward declarations (NFC)</title>
<updated>2023-12-10T18:38:55+00:00</updated>
<author>
<name>Kazu Hirata</name>
<email>kazu@google.com</email>
</author>
<published>2023-12-10T18:38:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=55531e715faabc6edfcba574e4861c97f989850d'/>
<id>55531e715faabc6edfcba574e4861c97f989850d</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Reland: [AMDGPU] Remove Code Object V3 (#67118)</title>
<updated>2023-11-07T11:23:03+00:00</updated>
<author>
<name>Pierre van Houtryve</name>
<email>pierre.vanhoutryve@amd.com</email>
</author>
<published>2023-10-16T06:21:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=4428b01faa41bb9afd75ae88c3ecbdb480a83e4d'/>
<id>4428b01faa41bb9afd75ae88c3ecbdb480a83e4d</id>
<content type='text'>
V3 has been deprecated for a while as well, so it can safely be removed
like V2 was removed.

- [Clang] Set minimum code object version to 4
- [lld] Fix tests using code object v3
- Remove code object V3 from the AMDGPU backend, and delete or port v3
tests to v4.
- Update docs to make it clear V3 can no longer be emitted.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
V3 has been deprecated for a while as well, so it can safely be removed
like V2 was removed.

- [Clang] Set minimum code object version to 4
- [lld] Fix tests using code object v3
- Remove code object V3 from the AMDGPU backend, and delete or port v3
tests to v4.
- Update docs to make it clear V3 can no longer be emitted.
</pre>
</div>
</content>
</entry>
<entry>
<title>Revert "[AMDGPU] Remove Code Object V3 (#67118)"</title>
<updated>2023-10-18T10:55:36+00:00</updated>
<author>
<name>pvanhout</name>
<email>pierre.vanhoutryve@amd.com</email>
</author>
<published>2023-10-18T10:55:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=868abf09619cb10ba710162483e5a66b0c1e4446'/>
<id>868abf09619cb10ba710162483e5a66b0c1e4446</id>
<content type='text'>
This reverts commit 544d91280c26fd5f7acd70eac4d667863562f4cc.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This reverts commit 544d91280c26fd5f7acd70eac4d667863562f4cc.
</pre>
</div>
</content>
</entry>
<entry>
<title>[AMDGPU] Remove Code Object V3 (#67118)</title>
<updated>2023-10-16T06:21:48+00:00</updated>
<author>
<name>Pierre van Houtryve</name>
<email>pierre.vanhoutryve@amd.com</email>
</author>
<published>2023-10-16T06:21:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=544d91280c26fd5f7acd70eac4d667863562f4cc'/>
<id>544d91280c26fd5f7acd70eac4d667863562f4cc</id>
<content type='text'>
V3 has been deprecated for a while as well, so it can safely be removed
like V2 was removed.

- [Clang] Set minimum code object version to 4
- [lld] Fix tests using code object v3
- Remove code object V3 from the AMDGPU backend, and delete or port v3
tests to v4.
- Update docs to make it clear V3 can no longer be emitted.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
V3 has been deprecated for a while as well, so it can safely be removed
like V2 was removed.

- [Clang] Set minimum code object version to 4
- [lld] Fix tests using code object v3
- Remove code object V3 from the AMDGPU backend, and delete or port v3
tests to v4.
- Update docs to make it clear V3 can no longer be emitted.</pre>
</div>
</content>
</entry>
<entry>
<title>[AMDGPU] Remove Code Object V2 (#65715)</title>
<updated>2023-09-21T10:00:45+00:00</updated>
<author>
<name>Pierre van Houtryve</name>
<email>pierre.vanhoutryve@amd.com</email>
</author>
<published>2023-09-21T10:00:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=fe2f67e4ba62ce9f0c3a9adcff592a77606e5228'/>
<id>fe2f67e4ba62ce9f0c3a9adcff592a77606e5228</id>
<content type='text'>
Code Object V2 has been deprecated for more than a year now. We can
safely remove it from LLVM.

- [clang] Remove support for the `-mcode-object-version=2` option.
- [lld] Remove/refactor tests that were still using COV2
- [llvm] Update AMDGPUUsage.rst
- Code Object V2 docs are left for informational purposes because those
code objects may still be supported by the runtime/loaders for a while.
- [AMDGPU] Remove COV2 emission capabilities.
- [AMDGPU] Remove `MetadataStreamerYamlV2` which was only used by COV2
- [AMDGPU] Update all tests that were still using COV2 - They are either
deleted or ported directly to code object v4 (as v3 is also planned to
be removed soon).</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Code Object V2 has been deprecated for more than a year now. We can
safely remove it from LLVM.

- [clang] Remove support for the `-mcode-object-version=2` option.
- [lld] Remove/refactor tests that were still using COV2
- [llvm] Update AMDGPUUsage.rst
- Code Object V2 docs are left for informational purposes because those
code objects may still be supported by the runtime/loaders for a while.
- [AMDGPU] Remove COV2 emission capabilities.
- [AMDGPU] Remove `MetadataStreamerYamlV2` which was only used by COV2
- [AMDGPU] Update all tests that were still using COV2 - They are either
deleted or ported directly to code object v4 (as v3 is also planned to
be removed soon).</pre>
</div>
</content>
</entry>
<entry>
<title>[AMDGPU] Emit .actual_access metadata</title>
<updated>2023-08-23T19:57:29+00:00</updated>
<author>
<name>Changpeng Fang</name>
<email>changpeng.fang@amd.com</email>
</author>
<published>2023-08-23T19:57:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=ffa7c7897c14223c591249dde41f33ecb3c4c148'/>
<id>ffa7c7897c14223c591249dde41f33ecb3c4c148</id>
<content type='text'>
Summary:
  Emit .actual_access metadata for the deduced argument access qualifier,
and .access for kernel_arg_access_qual.

Reviewers:
 arsenm

Differential Revision:
  https://reviews.llvm.org/D157451
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Summary:
  Emit .actual_access metadata for the deduced argument access qualifier,
and .access for kernel_arg_access_qual.

Reviewers:
 arsenm

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