Merge "Let hipcc not pass -mllvm option to HIP-Clang on Windows" into amd-master-next

[ROCm/hip commit: 027d6fb928]
This commit is contained in:
Yaxun Liu
2020-03-10 14:12:06 -04:00
committed by Gerrit Code Review
commit 87054b217a
+6 -4
Näytä tiedosto
@@ -726,10 +726,12 @@ if ($HIP_PLATFORM eq "clang") {
$HIPCXXFLAGS .= " -O3";
$HIPLDFLAGS .= " -O3";
}
if ($optArg ne "-O0") {
$HIPCXXFLAGS .= " -mllvm -amdgpu-early-inline-all=true -mllvm -amdgpu-function-calls=false";
if ($needLDFLAGS and not $needCXXFLAGS) {
$HIPLDFLAGS .= " -mllvm -amdgpu-early-inline-all=true -mllvm -amdgpu-function-calls=false";
# Do not pass -mllvm on Windows since there is a clang bug causing duplicate -mllvm options in clang -cc1 on Windows.
# ToDo : remove restriction for Windows after clang bug is fixed.
if ($optArg ne "-O0" and not $isWindows) {
$HIPCXXFLAGS .= " -mllvm -amdgpu-early-inline-all=true -mllvm -amdgpu-function-calls=false";
if ($needLDFLAGS and not $needCXXFLAGS) {
$HIPLDFLAGS .= " -mllvm -amdgpu-early-inline-all=true -mllvm -amdgpu-function-calls=false";
}
}
$HIP_DEVLIB_FLAGS = " --hip-device-lib-path=$DEVICE_LIB_PATH";