Skip to content
Permalink
Browse files

Merge pull request #1136 from yxsamliu/fix-rdc

Fix device lib path for hip-clang.
  • Loading branch information...
mangupta committed May 24, 2019
2 parents 184eb79 + bba85f0 commit 43e2c9d3619d4c4fbf1245061e117144c7e5ab9e
Showing with 1 addition and 14 deletions.
  1. +1 −14 bin/hipcc
@@ -370,7 +370,6 @@ if($HIP_PLATFORM eq "nvcc"){

my $toolArgs = ""; # arguments to pass to the hcc or nvcc tool
my $optArg = ""; # -O args
my $rdc = 0;

foreach $arg (@ARGV)
{
@@ -466,14 +465,6 @@ foreach $arg (@ARGV)
{
$optArg = $arg;
}
if($arg =~ /-fgpu-rdc/)
{
$rdc = 1;
}
if($arg =~ /-fno-gpu-rdc/)
{
$rdc = 0;
}

## process linker response file for hip-clang
## extract object files from static library and pass them directly to
@@ -804,11 +795,7 @@ if ($HIP_PLATFORM eq "clang") {
$HIPLDFLAGS .= " -O3";
}
$HIP_DEVLIB_FLAGS = " --hip-device-lib-path=$DEVICE_LIB_PATH";
if ($rdc eq 0) {
$HIPCXXFLAGS .= " $HIP_DEVLIB_FLAGS";
} else {
$HIPLDFLAGS .= " $HIP_DEVLIB_FLAGS";
}
$HIPCXXFLAGS .= " $HIP_DEVLIB_FLAGS";
if ($isWindows) {
$HIPCXXFLAGS .= " -std=c++14 -fms-extensions -fms-compatibility";
} else {

0 comments on commit 43e2c9d

Please sign in to comment.
You can’t perform that action at this time.