Skip to content

Commit

Permalink
Unify pipeline for XeGPU tests
Browse files Browse the repository at this point in the history
  • Loading branch information
chencha3 committed Oct 10, 2024
1 parent 9d73c3c commit 97bd8aa
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 64 deletions.
2 changes: 1 addition & 1 deletion lib/Transforms/VnniTransformation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -386,7 +386,7 @@ static void updateDpasOp(mlir::OpBuilder &builder, mlir::xegpu::DpasOp &op,
auto rhs = op.getRhs();
// B operand of DPAS has multiple uses and
// the rest uses don't use vnni.
if (!analysis.getLayout(rhs)) {
if (!analysis.getLayout(rhs) && isVNNIApplicable(rhs.getType())) {
builder.setInsertionPoint(op);
auto cast = mlir::cast<mlir::TypedValue<mlir::VectorType>>(rhs);
auto &&[newRhs, root] = applyVnniTransform(builder, cast);
Expand Down
4 changes: 2 additions & 2 deletions test/Integration/Dialect/XeGPU/optimize_transpose.mlir
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
// RUN: %python_executable %imex_runner --requires=l0-runtime -i %s --pass-pipeline-file=%p/xegpu-to-func-vc-optimize-transpose.pp \
// RUN: %python_executable %imex_runner --requires=l0-runtime -i %s --pass-pipeline-file=%p/xegpu-to-func-vc.pp \
// RUN: --runner imex-cpu-runner -e main \
// RUN: --entry-point-result=void \
// RUN: --shared-libs=%irunner_utils,%mlir_runner_utils,%mlir_c_runner_utils,%levelzero_runtime --filecheck
// RUN: %python_executable %imex_runner --requires=sycl-runtime -i %s --pass-pipeline-file=%p/xegpu-to-func-vc-optimize-transpose.pp \
// RUN: %python_executable %imex_runner --requires=sycl-runtime -i %s --pass-pipeline-file=%p/xegpu-to-func-vc.pp \
// RUN: --runner imex-cpu-runner -e main \
// RUN: --entry-point-result=void \
// RUN: --shared-libs=%irunner_utils,%mlir_runner_utils,%mlir_c_runner_utils,%sycl_runtime --filecheck
Expand Down

This file was deleted.

3 changes: 3 additions & 0 deletions test/Integration/Dialect/XeGPU/xegpu-to-func-vc.pp
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
// spirv dialect (for device code) lowering pipeline.
// Ready for imex runner starting from GPU dialect.
builtin.module(
gpu.module(imex-xegpu-hoist-transpose,
imex-xegpu-apply-vnni-transformation,
imex-xegpu-optimize-transpose)
imex-vector-linearize
gpu.module(convert-xegpu-to-vc)
cse
Expand Down
31 changes: 0 additions & 31 deletions test/Transforms/VnniTransform/xegpu-to-func-vc.pp

This file was deleted.

0 comments on commit 97bd8aa

Please sign in to comment.