Skip to content

Commit

Permalink
Add test REQUIRESments
Browse files Browse the repository at this point in the history
  • Loading branch information
fifield committed Oct 14, 2024
1 parent 22f5044 commit 874368a
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 2 deletions.
1 change: 1 addition & 0 deletions python/compiler/aiecc/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -1210,6 +1210,7 @@ def run(mlir_module, args=None):

if opts.aietools_path is None:
print("Could not find aietools from Vitis or Ryzen AI Software.")
opts.aietools_path("<aietools not found>")

os.environ["AIETOOLS"] = opts.aietools_path

Expand Down
3 changes: 1 addition & 2 deletions test/aiecc/buffers_xclbin.mlir
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@
//
//===----------------------------------------------------------------------===//

// REQUIRES: chess
// RUN: %PYTHON aiecc.py --xchesscc --no-link -nv --aie-generate-cdo --aie-generate-npu --no-compile-host --xclbin-name=aie.xclbin --npu-insts-name=insts.txt %s
// RUN: %PYTHON aiecc.py --no-compile --no-link -nv --aie-generate-cdo --aie-generate-npu --no-compile-host --xclbin-name=aie.xclbin --npu-insts-name=insts.txt %s
// RUN: FileCheck %s --input-file=buffers_xclbin.mlir.prj/kernels.json

// CHECK: {
Expand Down
3 changes: 3 additions & 0 deletions test/aiecc/simple.mlir
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@
//
//===----------------------------------------------------------------------===//

// REQUIRES: chess
// REQUIRES: peano

// RUN: %PYTHON aiecc.py --compile --xchesscc --no-link -nv %VitisSysrootFlag% --host-target=%aieHostTargetTriplet% %s -I%aie_runtime_lib%/test_lib/include %extraAieCcFlags% -L%aie_runtime_lib%/test_lib/lib -ltest_lib %S/test.cpp -o test.elf | FileCheck %s --check-prefix=XCHESSCC
// RUN: %PYTHON aiecc.py --compile --no-xchesscc --no-link -nv %VitisSysrootFlag% --host-target=%aieHostTargetTriplet% %s -I%aie_runtime_lib%/test_lib/include %extraAieCcFlags% -L%aie_runtime_lib%/test_lib/lib -ltest_lib %S/test.cpp -o test.elf | FileCheck %s --check-prefix=PEANO
// RUN: %PYTHON aiecc.py --no-compile --no-link -nv %VitisSysrootFlag% --host-target=%aieHostTargetTriplet% %s -I%aie_runtime_lib%/test_lib/include %extraAieCcFlags% -L%aie_runtime_lib%/test_lib/lib -ltest_lib %S/test.cpp -o test.elf | FileCheck %s --check-prefix=NOCOMPILE
Expand Down
3 changes: 3 additions & 0 deletions test/aiecc/simple_aie2.mlir
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@
//
//===----------------------------------------------------------------------===//

// REQUIRES: chess
// REQUIRES: peano

// RUN: %PYTHON aiecc.py --compile --xchesscc --no-link -nv %VitisSysrootFlag% --host-target=%aieHostTargetTriplet% %s -I%aie_runtime_lib%/test_lib/include %extraAieCcFlags% -L%aie_runtime_lib%/test_lib/lib -ltest_lib %S/test.cpp -o test.elf | FileCheck %s --check-prefix=XCHESSCC
// RUN: %PYTHON aiecc.py --compile --no-xchesscc --no-link -nv %VitisSysrootFlag% --host-target=%aieHostTargetTriplet% %s -I%aie_runtime_lib%/test_lib/include %extraAieCcFlags% -L%aie_runtime_lib%/test_lib/lib -ltest_lib %S/test.cpp -o test.elf | FileCheck %s --check-prefix=PEANO
// RUN: %PYTHON aiecc.py --no-compile --no-link -nv %VitisSysrootFlag% --host-target=%aieHostTargetTriplet% %s -I%aie_runtime_lib%/test_lib/include %extraAieCcFlags% -L%aie_runtime_lib%/test_lib/lib -ltest_lib %S/test.cpp -o test.elf | FileCheck %s --check-prefix=NOCOMPILE
Expand Down
2 changes: 2 additions & 0 deletions test/python/aiecc_simple.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# Copyright (C) 2023, Advanced Micro Devices, Inc.
# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception

# REQUIRES: chess

# RUN: %PYTHON %s --compile --xchesscc --no-link -nv | FileCheck %s

# CHECK: xchesscc_wrapper aie
Expand Down

0 comments on commit 874368a

Please sign in to comment.