Let hipcc handle clang-offload-bundler file in obj format for hip-clang

Esse commit está contido em:
Yaxun Sam Liu
2018-11-08 11:28:47 -05:00
commit 8fef5618ed
+4
Ver Arquivo
@@ -498,6 +498,10 @@ foreach $arg (@ARGV)
$obj = "$tmpdir/$obj";
my $fileType = `file $obj`;
my $isObj = ($fileType =~ m/ELF/ or $fileType =~ m/COFF/);
if ($fileType =~ m/ELF/) {
my $sections = `readelf -e -W $obj`;
$isObj = !($sections =~ m/__CLANG_OFFLOAD_BUNDLE__/);
}
$allIsObj = ($allIsObj and $isObj);
if ($isObj) {
$realObjs = ($realObjs . " " . $obj);