Skip to content

Commit 750c979

Browse files
author
Artem Gindinson
authored
[NFC][SYCL] Clean up FPGA archive files after test runs (#2678)
In some local configurations, re-launching fpga_aocx*.cpp tests appends new objects to the archive created during preceding test runs. Overwrite the archive files in a separate `RUN` line to avoid misleading failures in local development environments. Signed-off-by: Artem Gindinson <[email protected]>
1 parent de92415 commit 750c979

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

sycl/test/fpga_tests/fpga_aocx.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,9 @@
99
// REQUIRES: aoc, accelerator
1010

1111
/// E2E test for AOCX creation/use/run for FPGA
12-
// Produce an archive with device (AOCX) image
12+
// Produce an archive with device (AOCX) image. To avoid appending objects to
13+
// leftover archives, remove one if exists.
14+
// RUN: rm %t_image.a || true
1315
// RUN: %clangxx -fsycl -fintelfpga -fsycl-link=image %S/Inputs/fpga_device.cpp -o %t_image.a
1416
// Produce a host object
1517
// RUN: %clangxx -fsycl -fintelfpga %S/Inputs/fpga_host.cpp -c -o %t.o

sycl/test/fpga_tests/fpga_aocx_win.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,9 @@
1010
// REQUIRES: system-windows
1111

1212
/// E2E test for AOCX creation/use/run for FPGA
13-
// Produce an archive with device (AOCX) image
13+
// Produce an archive with device (AOCX) image. To avoid appending objects to
14+
// leftover archives, remove one if exists.
15+
// RUN: rm %t_image.a || true
1416
// RUN: %clang_cl -fsycl -fintelfpga -fsycl-link=image %S/Inputs/fpga_device.cpp -o %t_image.lib
1517
// Produce a host object
1618
// RUN: %clang_cl -fsycl -fintelfpga -DHOST_PART %S/Inputs/fpga_host.cpp -c -o %t.obj

0 commit comments

Comments
 (0)