[hipcc] A workaround for [SWDEV-105366] HCC's omitting of system includes while compiling kernel code leads to 'file not found' error.
Missing includes are set explicitly.
Workaround is switched on by default, to disable it set HCC_SYS_INCLUDES_WA=0.
WA will be removed after fixing [SWDEV-105366].
[ROCm/hip commit: 2027fcd0a2]
Этот коммит содержится в:
@@ -91,6 +91,18 @@ if ($HIP_PLATFORM eq "hcc") {
|
||||
$HIPCC=$HCC;
|
||||
$HIPCXXFLAGS = $HCCFLAGS;
|
||||
|
||||
#### GCC system includes workaround ####
|
||||
$WA = $ENV{'HCC_SYS_INCLUDES_WA'};
|
||||
if (!defined($WA) || ${WA} ne "0") {
|
||||
my $GCC_CUR_VER = `gcc -dumpversion`;
|
||||
my $GPP_CUR_VER = `g++ -dumpversion`;
|
||||
$GCC_CUR_VER =~ s/\R//g;
|
||||
$GPP_CUR_VER =~ s/\R//g;
|
||||
if (${GCC_CUR_VER} eq ${GPP_CUR_VER}) {
|
||||
$HIPCXXFLAGS .= "-I/usr/include/x86_64-linux-gnu -I/usr/include/x86_64-linux-gnu/c++/${GCC_CUR_VER} -I/usr/include/c++/${GCC_CUR_VER}";
|
||||
}
|
||||
}
|
||||
|
||||
$HIPCXXFLAGS .= " -I$HIP_PATH/include/hip/hcc_detail/cuda";
|
||||
$HIPCXXFLAGS .= " -I$HSA_PATH/include";
|
||||
$HIPCXXFLAGS .= " -Wno-deprecated-register";
|
||||
|
||||
Ссылка в новой задаче
Block a user