Skip to content

Commit

Permalink
rebase, remove chlo and clang-format
Browse files Browse the repository at this point in the history
  • Loading branch information
Tanyo Kwok committed Jul 22, 2022
1 parent 1e3bd68 commit d294d47
Show file tree
Hide file tree
Showing 7 changed files with 561 additions and 592 deletions.
3 changes: 3 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,9 @@ endmacro()
option(TORCH_MLIR_ENABLE_MHLO "Add mhlo dialect" ON)
if(TORCH_MLIR_ENABLE_MHLO)
add_definitions(-DTORCH_MLIR_ENABLE_MHLO)
# The i64 calculation is much slower than i32 on some devices, such as Nvidia GPU.
# One can truncate from i64 to i32 since dimension sizes are unlikely to exceed
# the range of i32(4GiB)
option(TORCH_MLIR_ENABLE_MHLO_TRUNC_DIMSIZE_TO_I32
"Enable truncate dimension size from i64 to i32(unsafely)" OFF)
if(TORCH_MLIR_ENABLE_MHLO_TRUNC_DIMSIZE_TO_I32)
Expand Down
2 changes: 0 additions & 2 deletions lib/Conversion/TorchToMhlo/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ add_mlir_conversion_library(TorchMLIRTorchToMhlo

DEPENDS
MhloDialect
ChloDialect
TorchMLIRConversionPassIncGen

LINK_COMPONENTS
Expand All @@ -18,7 +17,6 @@ add_mlir_conversion_library(TorchMLIRTorchToMhlo
MLIRIR
MLIRPass
MhloDialect
ChloDialect
TorchMLIRTorchDialect
)

Expand Down
5 changes: 2 additions & 3 deletions lib/Conversion/TorchToMhlo/PopulatePatterns.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,8 @@ void populateBasicOpPatternsAndLegality(TypeConverter &typeConverter,
RewritePatternSet &patterns,
ConversionTarget &target);
void populateViewLikeOpPatternsAndLegality(TypeConverter &typeConverter,
RewritePatternSet &patterns,
ConversionTarget &target);

RewritePatternSet &patterns,
ConversionTarget &target);

} // namespace torch_to_mhlo
} // namespace torch
Expand Down
249 changes: 0 additions & 249 deletions lib/Conversion/TorchToMhlo/SliceLikeOps.cpp

This file was deleted.

Loading

0 comments on commit d294d47

Please sign in to comment.