[all-commits] [llvm/llvm-project] a8ef75: [DirectX] Strip `dx.rootsignatures` metadata durin...

Finn Plummer via All-commits all-commits at lists.llvm.org
Wed Jun 25 14:07:08 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: a8ef75e758982d8e66790ffe26fcc6f1d9648e88
      https://github.com/llvm/llvm-project/commit/a8ef75e758982d8e66790ffe26fcc6f1d9648e88
  Author: Finn Plummer <finn.c.plum at gmail.com>
  Date:   2025-06-25 (Wed, 25 Jun 2025)

  Changed paths:
    M llvm/lib/Target/DirectX/DXILPrepare.cpp
    M llvm/test/CodeGen/DirectX/llc-pipeline.ll
    A llvm/test/CodeGen/DirectX/strip-rootsignatures.ll

  Log Message:
  -----------
  [DirectX] Strip `dx.rootsignatures` metadata during `dxil-prepare` (#145746)

The `dx.rootsignatures` metadata is not recognized in DXIL, so failure
to remove this will cause validation errors.

This metadata is parsed (within `RootSignatureAnalysisWrapper`) into its
binary format. As such, once it has been used to construct the binary
form, it can be safely discarded without loss of information.

This pr ensures that the dxil prepare pass will depend and preserve on
the root signature analysis so that it runs before the metadata is
removed.

- Update `DXILPrepare.cpp` to preserve and depend on
`RootSignatureAnalysisWrapper`
- Update test to demonstrate order is correct
- Provide test-case to demonstrate the metadata is removed

Resolves https://github.com/llvm/llvm-project/issues/145437.

----------

Co-authored-by: Justin Bogner <mail at justinbogner.com>



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list