[PATCH] D51048: cmake: Specify reference outputs in llvm_test_data()

Artem Belevich via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Aug 31 17:34:00 PDT 2018


tra added a comment.

I've ran into an unexpected problem after this patches have landed.

CUDA test suite generates multiple tests that use the same reference output.
I can't just use llvm_test_data(test_XYZ, "test.reference_output"), because there can only be one test.reference_output in the build directory.
I also can't manually create a symlink $SRC/test.reference_output -> $BUILD_DIR/test-XYZ.reference_output and then use llvm_test_data(SOURCE_DIR=$BUILD_DIR test-XYZ.reference_output) because it can't link to itself.
The only way around is to create a new directory, symlink original file there as test_XYZ and then use the temp dir as SOURCE_DIR to create test_XYZ.reference_output in the build dir. This is rather convoluted.

We probably need llvm_test_data with an optional argument that would allow providing a different name for the file name in the build dir, or make it unique automatically.


Repository:
  rT test-suite

https://reviews.llvm.org/D51048





More information about the llvm-commits mailing list