Skip to content

Commit

Permalink
[CPU] Add conversion for unsupported BF16 ops via target-specific sta…
Browse files Browse the repository at this point in the history
…ge (#27)

* Remove unused code.

Signed-off-by: Ilya Enkovich <[email protected]>

* Fma is always allowed on CPU.

Signed-off-by: Ilya Enkovich <[email protected]>

* Add unsupported op conversions for BF16 type.

Signed-off-by: Ilya Enkovich <[email protected]>

---------

Signed-off-by: Ilya Enkovich <[email protected]>
  • Loading branch information
ienkovich authored and int3 committed Aug 28, 2024
1 parent 5ba8381 commit ddbb2c3
Show file tree
Hide file tree
Showing 35 changed files with 458 additions and 721 deletions.
2 changes: 2 additions & 0 deletions bin/RegisterTritonDialects.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
#include "triton/Dialect/TritonNvidiaGPU/Transforms/Passes.h"

#include "cpu/include/TritonCPUToLLVM/Passes.h"
#include "cpu/include/TritonCPUTransforms/Passes.h"
#include "cpu/include/TritonToTritonCPU/Passes.h"
#include "nvidia/include/NVGPUToLLVM/Passes.h"
#include "nvidia/include/TritonNVIDIAGPUToLLVM/Passes.h"
Expand Down Expand Up @@ -69,6 +70,7 @@ inline void registerTritonDialects(mlir::DialectRegistry &registry) {
// CPU passes
mlir::triton::cpu::registerTritonToTritonCPUPasses();
mlir::triton::cpu::registerTritonToTritonCPUPipeline();
mlir::triton::cpu::registerTritonCPUTransformsPasses();
mlir::triton::cpu::registerTritonCPUToLLVMPasses();
mlir::triton::cpu::registerTritonCPUToLLVMPipeline();

Expand Down
1 change: 0 additions & 1 deletion include/triton/Dialect/TritonCPU/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
add_subdirectory(IR)
add_subdirectory(Transforms)
3 changes: 0 additions & 3 deletions include/triton/Dialect/TritonCPU/Transforms/CMakeLists.txt

This file was deleted.

16 changes: 0 additions & 16 deletions include/triton/Dialect/TritonCPU/Transforms/Passes.h

This file was deleted.

6 changes: 0 additions & 6 deletions include/triton/Dialect/TritonCPU/Transforms/Passes.td

This file was deleted.

31 changes: 0 additions & 31 deletions include/triton/Dialect/TritonCPU/Transforms/TritonCPUConversion.h

This file was deleted.

3 changes: 0 additions & 3 deletions lib/Conversion/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,2 @@
# TODO(minjang): I will remove these scratches soon.
# add_subdirectory(TritonToTritonCPU)
add_subdirectory(TritonToTritonGPU)
# add_subdirectory(TritonCPUToLLVM)
add_subdirectory(TritonGPUToLLVM)
20 changes: 0 additions & 20 deletions lib/Conversion/TritonCPUToLLVM/CMakeLists.txt

This file was deleted.

49 changes: 0 additions & 49 deletions lib/Conversion/TritonCPUToLLVM/CPUTargetInfo.cpp

This file was deleted.

37 changes: 0 additions & 37 deletions lib/Conversion/TritonCPUToLLVM/ControlFlowOpToLLVM.cpp

This file was deleted.

54 changes: 0 additions & 54 deletions lib/Conversion/TritonCPUToLLVM/FuncOpToLLVM.cpp

This file was deleted.

131 changes: 0 additions & 131 deletions lib/Conversion/TritonCPUToLLVM/PrintOpToLLVM.cpp

This file was deleted.

Loading

0 comments on commit ddbb2c3

Please sign in to comment.