7 Commits

Author SHA1 Message Date
Michael Liao
0d08282310 [MLIR][XeGPU] Fix shared build. NFC 2024-03-20 22:40:44 -04:00
Jie Fu
258091e76d [mlir] Fix -Wunused-variable in XeGPUOps.cpp (NFC)
llvm-project/mlir/lib/Dialect/XeGPU/IR/XeGPUOps.cpp:47:8:
error: unused variable 'ty' [-Werror,-Wunused-variable]
  auto ty = source.getType();
       ^
1 error generated.
2024-03-21 07:51:56 +08:00
Chao Chen
61b24c61a9
[MLIR][XeGPU] Adding XeGPU 2d block operators (#85804)
This PR adds XeGPU 2D block operators. It contains:
1. TensorDescType and TensorDescAttr definitions
2. MemoryScopeAttr and CacheHintAttr definitions which are used by
TensorDescAttr.
3. CreateNdDescOp, PrefetchNdOp, LoadNdOp, and StoreNdOp definitions,
and their corresponding testcases for illustration.

It cherry-picks daebe5c4f27ba140ac8d13abf41e3fe4db72b91a with asan fix.

---------

Co-authored-by: Mehdi Amini <joker.eph@gmail.com>
2024-03-20 17:32:30 -05:00
Balaji V. Iyer
8d142043e8
Revert "[MLIR][XeGPU] Adding XeGPU 2d block operators (#84692)" (#85653)
This reverts commit daebe5c4f27ba140ac8d13abf41e3fe4db72b91a.

This commit causes the following asan issue:

```
<snip>/llvm-project/build/bin/mlir-opt <snip>/llvm-project/mlir/test/Dialect/XeGPU/XeGPUOps.mlir | <snip>/llvm-project/build/bin/FileCheck <snip>/llvm-project/mlir/test/Dialect/XeGPU/XeGPUOps.mlir
# executed command: <snip>/llvm-project/build/bin/mlir-opt <snip>/llvm-project/mlir/test/Dialect/XeGPU/XeGPUOps.mlir
# .---command stderr------------
# | =================================================================
# | ==2772558==ERROR: AddressSanitizer: stack-use-after-return on address 0x7fd2c2c42b90 at pc 0x55e406d54614 bp 0x7ffc810e4070 sp 0x7ffc810e4068
# | READ of size 8 at 0x7fd2c2c42b90 thread T0
# |     #0 0x55e406d54613 in operator()<long int const*> /usr/include/c++/13/bits/predefined_ops.h:318
# |     #1 0x55e406d54613 in __count_if<long int const*, __gnu_cxx::__ops::_Iter_pred<mlir::verifyListOfOperandsOrIntegers(Operation*, llvm::StringRef, unsigned int, llvm::ArrayRef<long int>, ValueRange)::<lambda(int64_t)> > > /usr/include/c++/13/bits/stl_algobase.h:2125
# |     #2 0x55e406d54613 in count_if<long int const*, mlir::verifyListOfOperandsOrIntegers(Operation*, 
...
```
2024-03-18 11:27:58 -05:00
Adrian Kuegel
bfd1d95de2 [mlir] Fix unused variable error in builds with asserts enabled. 2024-03-18 14:13:47 +00:00
Chao Chen
daebe5c4f2
[MLIR][XeGPU] Adding XeGPU 2d block operators (#84692)
Hi @joker-eph, This PR adds XeGPU 2D block operators. It contains:
1. `TensorDescType` and `TensorDescAttr` definitions
2. `MemoryScopeAttr` and `CacheHintAttr` definitions which are used by
`TensorDescAttr`.
3. `CreateNdDescOp`, `PrefetchNdOp`, `LoadNdOp`, and `StoreNdOp`
definitions, and their corresponding testcases for illustration.

---------

Co-authored-by: Mehdi Amini <joker.eph@gmail.com>
2024-03-18 07:09:47 -05:00
Chao Chen
5669660f37
[MLIR] XeGPU dialect for Intel GPU - core definitions and base classes (#78483)
This PR follows our previous [RFC
](https://discourse.llvm.org/t/rfc-add-xegpu-dialect-for-intel-gpus/75723)
to add XeGPU dialect definition for Intel GPUs. It contains dialect,
type, attributes and operators definitions, as well as testcases for
semantic checks. The lowering and optimization passes will be issued
with separated passes.

---------

Co-authored-by: Mehdi Amini <joker.eph@gmail.com>
2024-03-07 17:25:59 -06:00