Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions clang/lib/Driver/ToolChains/Gnu.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -595,10 +595,8 @@ void tools::gnutools::Linker::ConstructJob(Compilation &C, const JobAction &JA,

// Performing link for dependency file information, undefined symbols are OK.
// True link time errors for symbols will be captured at host link.
if (JA.getType() == types::TY_Host_Dependencies_Image) {
CmdArgs.push_back("-z");
CmdArgs.push_back("undefs");
}
if (JA.getType() == types::TY_Host_Dependencies_Image)
CmdArgs.push_back("--unresolved-symbols=ignore-all");

Args.AddAllArgs(CmdArgs, options::OPT_L);
Args.AddAllArgs(CmdArgs, options::OPT_u);
Expand Down
2 changes: 1 addition & 1 deletion clang/test/Driver/sycl-offload-intelfpga-link.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@
// RUN: -target x86_64-unknown-linux-gnu %S/Inputs/SYCL/liblin64.a \
// RUN: %s -### 2>&1 \
// RUN: | FileCheck %s --check-prefix=CHK-FPGA-LINK-UNDEFS
// CHK-FPGA-LINK-UNDEFS: ld{{.*}} "-z" "undefs"
// CHK-FPGA-LINK-UNDEFS: ld{{.*}} "--unresolved-symbols=ignore-all"
// CHK-FPGA-LINK-UNDEFS: clang-offload-deps{{.*}}

/// -fintelfpga -fsycl-link from source
Expand Down
2 changes: 1 addition & 1 deletion clang/test/Driver/sycl-offload-static-lib-2.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@
// RUN: %clangxx -target x86_64-unknown-linux-gnu -fsycl -fsycl-targets=nvptx64-nvidia-cuda %t_lib.a -o output_name -lOpenCL -### %s 2>&1 \
// RUN: | FileCheck %s -check-prefix=STATIC_LIB_SRC2 -DBUNDLE_TRIPLE=sycl-nvptx64-nvidia-cuda-sm_50 -DDEPS_TRIPLE=sycl-nvptx64-nvidia-cuda-sm_50
// STATIC_LIB_SRC2: clang{{.*}} "-emit-obj" {{.*}} "-o" "[[HOSTOBJ:.+\.o]]"
// STATIC_LIB_SRC2: ld{{(.exe)?}}" {{.*}} "-o" "[[HOSTEXE:.+\.out]]" {{.*}}"-z" "undefs"
// STATIC_LIB_SRC2: ld{{(.exe)?}}" {{.*}} "-o" "[[HOSTEXE:.+\.out]]" {{.*}}"--unresolved-symbols=ignore-all"
// STATIC_LIB_SRC2: clang-offload-deps{{.*}} "-targets=[[DEPS_TRIPLE]]" "-outputs=[[OUTDEPS:.+\.bc]]" "[[HOSTEXE]]"
// STATIC_LIB_SRC2_DEF: clang-offload-bundler{{.*}} "-type=aoo" "-targets=[[BUNDLE_TRIPLE]]" {{.*}} "-output=[[OUTLIB:.+\.txt]]"
// STATIC_LIB_SRC2_NVPTX: clang-offload-bundler{{.*}} "-type=a" "-targets=[[BUNDLE_TRIPLE]]" {{.*}} "-output=[[OUTLIB:.+\.a]]"
Expand Down