[all-commits] [llvm/llvm-project] c8b3d7: [DXIL] Remove incompatible metadata types when pre...
Joshua Batista via All-commits
all-commits at lists.llvm.org
Mon Apr 28 12:43:59 PDT 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: c8b3d79961834e62e15e8350cb35a5bd7fafae50
https://github.com/llvm/llvm-project/commit/c8b3d79961834e62e15e8350cb35a5bd7fafae50
Author: Joshua Batista <jbatista at microsoft.com>
Date: 2025-04-28 (Mon, 28 Apr 2025)
Changed paths:
M llvm/lib/Target/DirectX/DXILPrepare.cpp
A llvm/test/CodeGen/DirectX/metadata-stripping.ll
Log Message:
-----------
[DXIL] Remove incompatible metadata types when preparing DXIL. (#136386)
This PR introduces a Metadata Node Kind allowlist. The purpose is to
prevent newer Metadata Node Kinds to be used and inserted into the
outputted DXIL module. Only the metadata kinds that are accepted in the
DXIL Validator are on the allowlist. The Github DXC validator doesn't
support these newer Metadata Node Kinds, so we need to filter them out.
We introduce this restrictive allowlist into LLVM and strip all metadata
that isn't found in the list.
The accompanying test would add the `llvm.loop.mustprogress` metadata
node kind, but thanks to the allowlist, filters it out, and so the
whitelist is proven to work.
The test also has two separate metadata kinds that are on the allowlist,
and remain after the DXIL Prepare pass.
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