RFC: Enabling pre-commit for torch-mlir
On some other projects, we’ve been enabling pre-commit to do lint checks and make fixes. It works pretty well. torch-mlir’s existing discipline around this is… somewhat lacking. Patch: Pre commit by...
View ArticleFIRRTL specfication questions
Hello everyone! I have a couple of questions about some FIRRTL specification version 3.2.0 examples. Section 5.3: In the last two examples I got the following error:...
View ArticleRFC: Support zero-width integers in the comb dialect (CIRCT)
I would like to discuss in this RFC motivating reasons to revert the decision of banning i0 from the comb dialect, and how to implement it in practice. Motivation A zero-width integer (i0) is a...
View ArticlePIP install `torch-mlir` downloads never-ending number of variations
Reproducing: $ pip install torch-mlir Defaulting to user installation because normal site-packages is not writeable Collecting torch-mlir Downloading...
View Article[RFC] Torch-mlir lowering to named ops
Looking into torch-mlir, the lowering to linalg is as generic but convoluted as I expected. Lots of corner cases, but also lots of generic builders and code reuse. Trying to create an ingress in...
View ArticleConversion of `sv.assign` to `sv.alwayscomb`
Does CIRCT have a pass or lowering option which converts sequences of sv.assign operations into a single sv.alwayscomb containing multiple assignments? For example (in RTL): // before assign a = c;...
View ArticleCompiling CIRCT with standard LLVM and MLIR packages
Hi, I’m involved in the development of a research compiler that is based on the conventional LLVM and MLIR packages. Currently, we have a dependency on CIRCT where I have created a version that...
View ArticleTorch-mlir + torchvision with torch dependency conflicts
Trying to install pytorch using: pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cpu and torch-mlir using: pip install torch-mlir -f...
View ArticleError trying to run torchscript demo example
Trying to run the torchscript demo example from the MLIR homepage and getting some errors, what are the dependencies I’m missing here? -2024-07-12 12:09:47--...
View ArticleLowering from CHIRRTL dialect
Hello everyone! Recently I’ve tried a project called RISC-V Mini. I got the ‘.fir’ file and while lowering to LoFIRRTL from CHIRRTL dialect I got the following error: loc(".../tile.fir":892:5): error:...
View ArticleDrastically reducing documented scope of project
Hey folks, I’m going to take a pass at the torch-mlir documentation to delete obsolete content, drastically reduce the stated scope of the project, and provide better front-page notes on which parts...
View ArticleCiting CIRCT
Hello, I’m writing a paper and I’d like to cite CIRCT in it. I guess that I could cite the main webpage of CIRCT but I think it’s not really scientific. So, I wonder if there is a better citation I...
View Article[torch-mlir][onnx] how to run torch-mlir python lit unittest
When I build torch-mlir, I hope to be able to use its torch-mlir-import-onnx. How do I build it? Or how can I go through “python -m torch_mlir.tools.import_onnx xxx.onnx”, but for the latter method, I...
View ArticlePSA: pytorch native interface no longer being built
As of Disable TORCH_MLIR_ENABLE_JIT_IR_IMPORTER and TORCH_MLIR_ENABLE_PYTOR… · llvm/torch-mlir@fbb0db1 · GitHub, we are no longer building features that natively link to pytorch via c++. Concretely,...
View ArticleHow do you code a generate (parallel for loop) in FIRRTL?
I’m examining whether to use FIRRTL as an output for a codesign tool. My only concern at the moment is that there seems to be no way to express a SystemVerilog generate/for loop construction. What is...
View ArticleHow to separate the body and dialect resources from a module in torch-mlir...
Following the github example of torch-mlir, I have translated the resnet18 into mlir: resnet18 = torchvision.models.resnet18(pretrained=True) resnet18.eval() module = torchscript.compile(resnet18,...
View ArticleCustomizing Function Export with fx.export_and_import
I am trying to export the MLIR file of Llama2 using fx.export_and_import in torch_mlir. By default, it seems to export the model’s forward function. Is there a way to specify which function to export,...
View ArticleFIRRTL equivalent to Yosys's `$initstate`
I’m building a embedded HDL library in Rust that generates FIRRTL, but I’m running into a problem when I’m trying to run formal verification using SymbiYosys on the output: I can’t figure out how to...
View ArticleEvaluation mode behavior for training-specific parameters for pytorch model
Hi All, I’m not sure if this is the right forum to ask this question; if it is not, please let me know. I have the below clarification question related to pytorch module.eval(): The document below...
View ArticleJittable error of iree-turbine
I followed the iree-turbine steps to set up the environment and executed the corresponding samples in order. The first two samples, AOT MLP With Static Shapes and AOT MLP with a Dynamic Batch Size,...
View Article[Job Ad] PhD position in Munich, Germany, on CIRCT, Yosys and Verilator
Hi everyone, I have a fully funded PhD position to fill in Munich to work on interoperability of CIRCT, Yosys and Verilator, and related topics. You can find some information here: Open Source Chip...
View ArticleLLVM Dev Meeting CIRCT Meetup?
I remember there was some talk in an ODM a couple of weeks back of planning a bay area CIRCT meetup to coincide with the LLVM Dev Meeting next week. Are there any plans for this? Would be great to...
View ArticleOperation cloning in graph regions with use before def values
Hi, I’m working on building a pass to outline operations that are part of strongly connected components within an HwModuleOp into separate submodules. To achieve this, I need to clone the necessary...
View ArticleCIRCT: Lowering Upstream MLIR into Verilog
Hello, I’m a newcomer to both MLIR and CIRCT. I recently created a small dialect in MLIR and successfully lowered its operations to LLVM as a test. Now, I’m trying to lower that same dialect into...
View ArticleProper way to obtain arcilator-runtime.h for C++ integration
When using the arcilator from CIRCT its generated code requires arcilator-runtime.h for C++ compilation. However, this header is missing in the official pre-built release tarbal ( from GitHub release...
View Article