torch-mlir/lib/Dialect
Ashay Rane 6491c69539
torch: use ScalarType enum instead of raw constants (#1020)
This patch replaces the use of raw integers like 6, 4, etc. (that
represent PyTorch's scalar types) with named values from the ScalarType
enum (e.g. `ScalarType::Float`, `ScalarType::Long`, etc.) in code for
folding `prim.dtype` ops into numeric constants.

This patch isn't strictly a non-functional change, since its use of
`Torch::getScalarTypeForType()` implies that the input type has to be
one among the supported types, otherwise compilation will abort, whereas
previously, compilation proceeded without folding the unsupported data
type into a numeric constant.
2022-07-07 14:21:05 -07:00
..
Torch torch: use ScalarType enum instead of raw constants (#1020) 2022-07-07 14:21:05 -07:00
TorchConversion [MLIR][TORCH] Add folder for torch_c.from_i64 & torch_c.to_i64 (#933) 2022-06-24 09:34:39 +08:00
CMakeLists.txt Move external/torch-mlir to the root of the repo. 2021-09-27 17:11:08 -07:00