torch-mlir/lib/Dialect/Torch/IR
Sean Silva 3b66b4925a Make TorchOps.cpp faster to iterate on.
The ODS-generated code included via the `TorchOps.cpp.inc` file takes a
very long time to compile. This PR isolates it into its own file so that
the build system can cache it.

This PR creates a new file `TorchOpsODSGenerated.cpp` just to include
the `TorchOps.cpp.inc` file. Doing so required moving to the "new" way
to define verifiers, since the static `verify` free functions in
TorchOps.cpp weren't accessible from the .inc file after it was moved to
`TorchOpsODSGenerated.cpp`.

On my machine, this drops the build time of TorchOps.cpp (such as when
iterating on a canonicalizer) from >40 seconds to <10 seconds.
10 seconds still isn't great though, but at least it isn't "go get a
coffee" type of waiting.
2022-03-16 09:33:12 -07:00
..
CMakeLists.txt Make TorchOps.cpp faster to iterate on. 2022-03-16 09:33:12 -07:00
TorchDialect.cpp Elide `!torch.` prefix in nested dialect types. 2022-03-15 17:24:08 -07:00
TorchOps.cpp Make TorchOps.cpp faster to iterate on. 2022-03-16 09:33:12 -07:00
TorchOpsODSGenerated.cpp Make TorchOps.cpp faster to iterate on. 2022-03-16 09:33:12 -07:00
TorchTypes.cpp Make TorchOps.cpp faster to iterate on. 2022-03-16 09:33:12 -07:00