[HIP] Ignore host linker flags for device-only
authorSiu Chi Chan <siuchi.chan@amd.com>
Mon, 10 Jul 2023 17:30:23 +0000 (13:30 -0400)
committerSiu Chi Chan <siuchi.chan@amd.com>
Mon, 17 Jul 2023 20:29:15 +0000 (16:29 -0400)
commitcbc4bbb85c729f34bf0cba84ccd2e116af1454f5
tree6eba641047ecdc726a7e73914b5a3469980bd29c
parent7f08f449621da737d3fa8e89b0e3022c0178f216
[HIP] Ignore host linker flags for device-only

When compiling in device only mode (e.g. --offload-device-only), the
host linker phase would not happen and therefore, the driver should
ignore all the host linker flags.

Differential Revision: https://reviews.llvm.org/D154881

Change-Id: I8244acef5c33108cf15b1dbb188f974f30099718
clang/lib/Driver/Driver.cpp
clang/test/Driver/hip-phases.hip