[PATCH] D115283: [AMDGPU] Set "amdgpu_hostcall" module flag if an AMDGPU function has calls to device lib functions that use hostcalls.

Daniil Fukalov via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Dec 8 01:37:10 PST 2021


dfukalov added inline comments.


================
Comment at: clang/test/CodeGenHIP/amdgpu_hostcall.cpp:2-6
+// RUN: %clang_cc1 -triple amdgcn-amd-amdhsa -x hip -emit-llvm -fcuda-is-device -DFN_HOSTCALL \
+// RUN:   -o - %s | FileCheck --enable-var-scope %s
+
+// RUN: %clang_cc1 -triple amdgcn-amd-amdhsa -x hip -emit-llvm -fcuda-is-device -DFN_PRINTF \
+// RUN:   -o - %s | FileCheck --enable-var-scope %s
----------------
Am I right we don't actually need two runs here, the test may be executed with one run, removed `#ifdefs` and, possible, multiplied `CHECK:` lines?
I would suggest to use the llvm/utils/update_cc_test_checks.py script in such tests.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D115283/new/

https://reviews.llvm.org/D115283



More information about the cfe-commits mailing list