[all-commits] [llvm/llvm-project] fab4fd: [AMDGPU][Verifier] Mark calls to entry functions a...

Shilei Tian via All-commits all-commits at lists.llvm.org
Wed Apr 9 07:06:01 PDT 2025


  Branch: refs/heads/users/shiltian/dont-allow-call-to-amdgpu-kernel
  Home:   https://github.com/llvm/llvm-project
  Commit: fab4fdde2a7ec951504b60bbd9d567e77348649f
      https://github.com/llvm/llvm-project/commit/fab4fdde2a7ec951504b60bbd9d567e77348649f
  Author: Shilei Tian <i at tianshilei.me>
  Date:   2025-04-09 (Wed, 09 Apr 2025)

  Changed paths:
    M llvm/include/llvm/IR/CallingConv.h
    M llvm/lib/IR/Verifier.cpp
    M llvm/test/CodeGen/AMDGPU/attributor-flatscratchinit.ll
    R llvm/test/CodeGen/AMDGPU/call-to-kernel-undefined.ll
    R llvm/test/CodeGen/AMDGPU/call-to-kernel.ll
    M llvm/test/Verifier/amdgpu-cc.ll
    A llvm/test/Verifier/call-to-non-callable-functions.ll

  Log Message:
  -----------
  [AMDGPU][Verifier] Mark calls to entry functions as invalid in the IR verifier

For AMDGPU, calls to entry functions are invalid. Previously, due to certain
limitations, this restriction was not enforced by the IR verifier. These
limitations have now been resolved, enabling us to enforce this check.

Adding target-dependent checks directly into the IR verifier is not ideal.
However, a cleaner solution, such as a dedicated target-dependent IR verifier,
is underway (e.g., https://github.com/llvm/llvm-project/pull/123609). Once that
or similar code is merged, we can move this check accordingly.



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