[PATCH] D118858: [OpenMP] Don't use bound architecture when checking cache on the host
Joseph Huber via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Feb 3 14:57:41 PST 2022
jhuber6 added a comment.
In D118858#3295210 <https://reviews.llvm.org/D118858#3295210>, @thakis wrote:
> Looks like this breaks tests on Mac: http://45.33.8.238/macm1/27158/step_7.txt
>
> Please take a look and revert for now if it takes a while to fix.
Can you do me a favor and run the command `clang -### -fopenmp=libomp -fopenmp-targets=nvptx64-nvidia-cuda -fopenmp-new-driver -no-canonical-prefixes -ccc-print-bindings $HOME/Documents/code/llvm-project/clang/test/Driver/openmp-offload-gpu.c -o openmp-offload-gpu -fopenmp -fopenmp-targets=nvptx64 -fopenmp-new-driver -ccc-print-bindings`
diff --git a/clang/lib/Driver/Driver.cpp b/clang/lib/Driver/Driver.cpp
index 3bfddeefc7b2..cba9cecd7d5e 100644
--- a/clang/lib/Driver/Driver.cpp
+++ b/clang/lib/Driver/Driver.cpp
@@ -4745,6 +4745,7 @@ InputInfoList Driver::BuildJobsForAction(
Action::OffloadKind TargetDeviceOffloadKind) const {
std::pair<const Action *, std::string> ActionTC = {
A, GetTriplePlusArchString(TC, BoundArch, TargetDeviceOffloadKind)};
+ llvm::errs() << "Insert: " << A << " " << TC->getTriple().getTriple() << " " << BoundArch << " " << TargetDeviceOffloadKind << "\n";
auto CachedResult = CachedResults.find(ActionTC);
if (CachedResult != CachedResults.end()) {
return CachedResult->second;
@@ -4831,6 +4832,7 @@ InputInfoList Driver::BuildJobsForActionNoCache(
std::pair<const Action *, std::string> ActionTC = {
OA->getHostDependence(),
GetTriplePlusArchString(TC, BoundArch, TargetDeviceOffloadKind)};
+ llvm::errs() << "Check: " << A << " " << TC->getTriple().getTriple() << " " << BoundArch << " " << TargetDeviceOffloadKind << "\n";
if (CachedResults.find(ActionTC) != CachedResults.end()) {
InputInfoList Inputs = CachedResults[ActionTC];
Inputs.append(OffloadDependencesInputInfo);
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D118858/new/
https://reviews.llvm.org/D118858
More information about the cfe-commits
mailing list