Skip to content
This repository was archived by the owner on Jan 26, 2026. It is now read-only.

Commit 6900bf9

Browse files
committed
adjusting to latest imex
1 parent 172c55d commit 6900bf9

File tree

2 files changed

+13
-17
lines changed

2 files changed

+13
-17
lines changed

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,14 @@ A tensor implementation following the [array API as defined by the data-API cons
44
It supports a controller-worker execution model as well as a CSP-like execution.
55

66
## Setting up build environment
7-
Install MLIR/LLVM and IMEX from branch refactor (see https://github.com/intel/mlir-extensions/tree/refactor).
7+
Install MLIR/LLVM and IMEX from branch dist-ndarray (see https://github.com/intel-innersource/frameworks.ai.mlir.mlir-extensions/tree/dist-ndarray).
88
```bash
99
git --recurse-submodules clone https://github.com/intel-sandbox/personal.fschlimb.ddptensor
1010
cd personal.fschlimb.ddptensor
11+
git checkout jit
1112
conda env create -f conda-env.yml -n ddpt
1213
conda activate ddpt
1314
export MPIROOT=$CONDA_PREFIX
14-
export MKLROOT=$CONDA_PREFIX
1515
export MLIRROOT=<your-MLIR-install-dir>
1616
export IMEXROOT=<your-IMEX-install-dir>
1717
```
@@ -21,7 +21,7 @@ python setup.py develop
2121
```
2222
If your compiler does not default to a recent version, try something like `CC=gcc-9 CXX=g++-9 python setup.py develop`
2323

24-
## Running Tests
24+
## Running Tests [non functional]
2525
__Test are currently not operational on this branch.__
2626

2727
```bash
@@ -58,11 +58,11 @@ dt.fini()
5858
```
5959
Assuming the above is in file `simple.py` a single-process run is executed like
6060
```bash
61-
python DDPT_IDTR_SO=`pwd`/ddptensor/libidtr.so python simple.py
61+
DDPT_IDTR_SO=`pwd`/ddptensor/libidtr.so python simple.py
6262
```
6363
and multi-process run is executed like
6464
```bash
65-
python DDPT_IDTR_SO=`pwd`/ddptensor/libidtr.so mpirun -n 5 python simple.py
65+
DDPT_IDTR_SO=`pwd`/ddptensor/libidtr.so mpirun -n 5 python simple.py
6666
```
6767

6868
## Contributing

src/jit/mlir.cpp

Lines changed: 8 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -396,21 +396,17 @@ std::vector<intptr_t> JIT::run(::mlir::ModuleOp &module,
396396
static const char *pass_pipeline =
397397
getenv("DDPT_PASSES")
398398
? getenv("DDPT_PASSES")
399-
// :
400-
// "func.func(ptensor-dist),convert-dist-to-standard,convert-ptensor-to-linalg,arith-expand,canonicalize,arith-bufferize,func.func(empty-tensor-to-alloc-tensor,scf-bufferize,linalg-bufferize,tensor-bufferize),func-bufferize,canonicalize,func.func(finalizing-bufferize,convert-linalg-to-parallel-loops),canonicalize,fold-memref-alias-ops,lower-affine,convert-scf-to-cf,convert-memref-to-llvm,convert-func-to-llvm,reconcile-unrealized-casts";
401-
// :
402-
// "builtin.module(func.func(ptensor-dist),convert-dist-to-standard,convert-ptensor-to-linalg,arith-bufferize,func.func(empty-tensor-to-alloc-tensor,scf-bufferize,linalg-bufferize,tensor-bufferize,bufferization-bufferize),func-bufferize,func.func(finalizing-bufferize,convert-linalg-to-parallel-loops),canonicalize,fold-memref-alias-ops,expand-strided-metadata,lower-affine,convert-scf-to-cf,convert-memref-to-llvm,convert-func-to-llvm,reconcile-unrealized-casts)";
403399
: "func.func(ptensor-dist,dist-coalesce),convert-dist-to-standard,"
404400
"convert-ptensor-to-linalg,canonicalize,convert-shape-to-std,arith-"
405-
"expand,canonicalize,arith-bufferize,func-bufferize,func.func(tosa-"
406-
"to-linalg,"
407-
"empty-tensor-to-alloc-tensor,scf-bufferize,tensor-bufferize,linalg-"
408-
"bufferize,bufferization-bufferize,linalg-detensorize,tensor-"
401+
"expand,func.func(tosa-to-linalg,canonicalize,linalg-fuse-"
402+
"elementwise-ops,empty-tensor-to-alloc-tensor),memref-expand,arith-"
403+
"bufferize,func-bufferize,func.func(scf-bufferize,tensor-bufferize,"
404+
"linalg-bufferize,bufferization-bufferize,linalg-detensorize,tensor-"
409405
"bufferize,finalizing-bufferize,convert-linalg-to-parallel-loops),"
410406
"canonicalize,fold-memref-alias-ops,expand-strided-metadata,convert-"
411-
"math-to-funcs,convert-math-to-libm,lower-"
412-
"affine,convert-scf-to-cf,convert-memref-to-llvm,convert-func-to-"
413-
"llvm,reconcile-unrealized-casts";
407+
"math-to-funcs,convert-math-to-libm,lower-affine,convert-scf-to-cf,"
408+
"finalize-memref-to-llvm,convert-func-to-llvm,reconcile-unrealized-"
409+
"casts";
414410
JIT::JIT()
415411
: _context(::mlir::MLIRContext::Threading::DISABLED), _pm(&_context),
416412
_verbose(false) {
@@ -477,9 +473,9 @@ void init() {
477473
::mlir::bufferization::registerBufferizationPasses();
478474
::mlir::arith::registerArithPasses();
479475
::mlir::registerAffinePasses();
480-
::mlir::registerMemRefToLLVMConversionPass();
481476
::mlir::registerCanonicalizerPass();
482477
::mlir::registerConvertAffineToStandardPass();
478+
::mlir::registerFinalizeMemRefToLLVMConversionPass();
483479
::mlir::memref::registerMemRefPasses();
484480
::mlir::registerReconcileUnrealizedCastsPass();
485481

0 commit comments

Comments
 (0)