[all-commits] [llvm/llvm-project] a6b718: [HLSL] Move length support out of the DirectX Back...

Farzon Lotfi via All-commits all-commits at lists.llvm.org
Thu Jan 9 10:12:15 PST 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: a6b7181733c83523a39d4f4e788c6b7a227d477d
      https://github.com/llvm/llvm-project/commit/a6b7181733c83523a39d4f4e788c6b7a227d477d
  Author: Farzon Lotfi <farzonlotfi at microsoft.com>
  Date:   2025-01-09 (Thu, 09 Jan 2025)

  Changed paths:
    M clang/include/clang/Basic/Builtins.td
    M clang/lib/CodeGen/CGBuiltin.cpp
    M clang/lib/CodeGen/CGHLSLRuntime.h
    M clang/lib/Headers/hlsl/hlsl_detail.h
    M clang/lib/Headers/hlsl/hlsl_intrinsics.h
    M clang/lib/Sema/SemaHLSL.cpp
    M clang/test/CodeGenHLSL/builtins/length.hlsl
    M clang/test/SemaHLSL/BuiltIns/length-errors.hlsl
    M llvm/include/llvm/IR/IntrinsicsDirectX.td
    M llvm/lib/Target/DirectX/DXILIntrinsicExpansion.cpp
    R llvm/test/CodeGen/DirectX/length.ll
    R llvm/test/CodeGen/DirectX/length_error.ll
    R llvm/test/CodeGen/DirectX/length_invalid_intrinsic_error.ll
    R llvm/test/CodeGen/DirectX/length_invalid_intrinsic_error_scalar.ll

  Log Message:
  -----------
  [HLSL] Move length support out of the DirectX Backend  (#121611)

## Changes
- Delete DirectX length intrinsic
- Delete HLSL length lang builtin
- Implement length algorithm entirely in the header.

## History
- In the past if an HLSL intrinsic lowered to either a spirv op code or
a DXIL opcode we represented it with intrinsics

## Why we are moving away?
- To make HLSL apis more portable the team decided that it makes sense
for some intrinsics to be defined only in the header.
- Since there tends to be more SPIRV opcodes than DXIL opcodes the plan
is to support SPIRV opcodes either with target specific builtins or via
pattern matching.



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