[all-commits] [llvm/llvm-project] 8198d8: [X86] Pass to transform amx intrinsics to scalar o...

Luo, Yuanke via All-commits all-commits at lists.llvm.org
Fri Mar 5 00:03:02 PST 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 8198d83965ba4b9db6922b44ef3041030b2bac39
      https://github.com/llvm/llvm-project/commit/8198d83965ba4b9db6922b44ef3041030b2bac39
  Author: Luo, Yuanke <yuanke.luo at intel.com>
  Date:   2021-03-05 (Fri, 05 Mar 2021)

  Changed paths:
    M llvm/include/llvm/CodeGen/Passes.h
    M llvm/lib/Target/X86/CMakeLists.txt
    M llvm/lib/Target/X86/X86.h
    A llvm/lib/Target/X86/X86LowerAMXIntrinsics.cpp
    M llvm/lib/Target/X86/X86LowerAMXType.cpp
    M llvm/lib/Target/X86/X86TargetMachine.cpp
    A llvm/test/CodeGen/X86/AMX/amx-low-intrinsics-no-amx-bitcast.ll
    A llvm/test/CodeGen/X86/AMX/amx-low-intrinsics.ll
    M llvm/test/CodeGen/X86/AMX/amx-type.ll
    M llvm/test/CodeGen/X86/O0-pipeline.ll
    M llvm/test/CodeGen/X86/opt-pipeline.ll
    M llvm/tools/opt/opt.cpp

  Log Message:
  -----------
  [X86] Pass to transform amx intrinsics to scalar operation.

This pass runs in any situations but we skip it when it is not O0 and the
function doesn't have optnone attribute. With -O0, the def of shape to amx
intrinsics is near the amx intrinsics code. We are not able to find a
point which post-dominate all the shape and dominate all amx intrinsics.
To decouple the dependency of the shape, we transform amx intrinsics
to scalar operation, so that compiling doesn't fail. In long term, we
 should improve fast register allocation to allocate amx register.

Reviewed By: pengfei

Differential Revision: https://reviews.llvm.org/D93594




More information about the All-commits mailing list