https://github.com/skatrak approved this pull request.
LGTM, thanks! Please wait for one more approval before merging.
https://github.com/llvm/llvm-project/pull/73944
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bi
https://github.com/skatrak commented:
Thanks for this work, Dominik. It LGTM, but please wait for another review
before merging. I have a couple of suggestions for small improvements, but let
me know if they would take significant effort to address, as I'm not completely
familiar with that par
https://github.com/skatrak edited
https://github.com/llvm/llvm-project/pull/72638
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -264,6 +263,37 @@ static void addDepdendentLibs(mlir::ModuleOp &mlirModule,
}
}
+// Add to MLIR code target specific items which are dependent on target
+// configuration specified by the user
+static void addTargetSpecificMLIRItems(mlir::ModuleOp &mlirModule,
+
@@ -264,6 +263,37 @@ static void addDepdendentLibs(mlir::ModuleOp &mlirModule,
}
}
+// Add to MLIR code target specific items which are dependent on target
+// configuration specified by the user
+static void addTargetSpecificMLIRItems(mlir::ModuleOp &mlirModule,
+
@@ -1851,6 +1853,18 @@ bool ClauseProcessor::processTo(
});
}
+bool ClauseProcessor::processEnter(
+llvm::SmallVectorImpl &result) const {
+ return findRepeatableClause(
+ [&](const ClauseTy::Enter *enterClause,
+ const Fortran::parser::CharBlock &) {
https://github.com/skatrak edited
https://github.com/llvm/llvm-project/pull/72770
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -590,6 +590,8 @@ class ClauseProcessor {
bool processSectionsReduction(mlir::Location currentLocation) const;
bool processTo(llvm::SmallVectorImpl &result)
const;
bool
+ processEnter(llvm::SmallVectorImpl &result) const;
skatrak wrote:
Nit: It would
https://github.com/skatrak commented:
Thank you Shraiysh, I just have a couple of nits.
https://github.com/llvm/llvm-project/pull/72770
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/skatrak commented:
Thanks for this work. I only have very little feedback, but it LGTM.
I think the enum looks a bit out of place in a file called "TargetParser.h",
but I'm not very familiar with this part of the project, so I'll let the
experts say something if there is a m
https://github.com/skatrak edited
https://github.com/llvm/llvm-project/pull/73944
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -405,9 +398,9 @@ class LLVM_LIBRARY_VISIBILITY AMDGPUTargetInfo final :
public TargetInfo {
getDWARFAddressSpace(unsigned AddressSpace) const override {
const unsigned DWARF_Private = 1;
const unsigned DWARF_Local = 2;
-if (AddressSpace == Private) {
+if (
@@ -31,6 +31,15 @@ class Triple;
// back-end to TableGen to create these clean tables.
namespace AMDGPU {
+/// Address space values for AMD GPUs
+enum AddrSpace {
+ Generic = 0,
skatrak wrote:
I think it would be good to prefix these names with something so
@@ -665,60 +619,44 @@ bool
clang::isOpenMPTargetDataManagementDirective(OpenMPDirectiveKind DKind) {
}
bool clang::isOpenMPNestingTeamsDirective(OpenMPDirectiveKind DKind) {
- return DKind == OMPD_teams || DKind == OMPD_teams_distribute ||
- DKind == OMPD_teams_distr
https://github.com/skatrak edited
https://github.com/llvm/llvm-project/pull/80460
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/skatrak commented:
I noticed a small breakage of the OpenMP MLIR dialect from one of these
changes. It should be trivial to address.
https://github.com/llvm/llvm-project/pull/80460
___
cfe-commits mailing list
cfe-commits@lists.llvm
@@ -6872,35 +6883,6 @@ void OpenMPIRBuilder::loadOffloadInfoMetadata(StringRef
HostFilePath) {
loadOffloadInfoMetadata(*M.get());
}
-Function *OpenMPIRBuilder::createRegisterRequires(StringRef Name) {
skatrak wrote:
Removing this function breaks the compil
@@ -6872,35 +6883,6 @@ void OpenMPIRBuilder::loadOffloadInfoMetadata(StringRef
HostFilePath) {
loadOffloadInfoMetadata(*M.get());
}
-Function *OpenMPIRBuilder::createRegisterRequires(StringRef Name) {
skatrak wrote:
Flang already picks up your changes to `
@@ -6872,35 +6883,6 @@ void OpenMPIRBuilder::loadOffloadInfoMetadata(StringRef
HostFilePath) {
loadOffloadInfoMetadata(*M.get());
}
-Function *OpenMPIRBuilder::createRegisterRequires(StringRef Name) {
skatrak wrote:
The test itself has "requires unified_sh
@@ -6872,35 +6883,6 @@ void OpenMPIRBuilder::loadOffloadInfoMetadata(StringRef
HostFilePath) {
loadOffloadInfoMetadata(*M.get());
}
-Function *OpenMPIRBuilder::createRegisterRequires(StringRef Name) {
skatrak wrote:
> It was a very obvious problem. I mixed
https://github.com/skatrak edited
https://github.com/llvm/llvm-project/pull/80460
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -3358,14 +3396,17 @@ genOMP(Fortran::lower::AbstractConverter &converter,
.t);
// Currently only private/firstprivate clause is handled, and
// all privatization is done within `omp.section` operations.
+ symTable.pushScope();
skatrak wrot
https://github.com/skatrak approved this pull request.
Thanks for addressing my comments, LGTM.
https://github.com/llvm/llvm-project/pull/77758
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-
https://github.com/skatrak edited
https://github.com/llvm/llvm-project/pull/77758
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -110,6 +110,34 @@ static void gatherFuncAndVarSyms(
}
}
+static Fortran::lower::pft::Evaluation *
+getCollapsedEval(Fortran::lower::pft::Evaluation &eval, int collapseValue) {
skatrak wrote:
Nit: Maybe `getCollapsedLoopEval` would be slightly more self-e
@@ -2178,7 +2178,7 @@
createAndSetPrivatizedLoopVar(Fortran::lower::AbstractConverter &converter,
template
static void createBodyOfOp(
Op &op, Fortran::lower::AbstractConverter &converter, mlir::Location &loc,
-Fortran::lower::pft::Evaluation &eval,
+Fortran::lowe
https://github.com/skatrak approved this pull request.
LGTM, thank you!
https://github.com/llvm/llvm-project/pull/77760
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
Author: Sergio Afonso
Date: 2023-08-07T11:18:43+01:00
New Revision: ec70627dd17703a2a12ce0f28bd3794aa77d2058
URL:
https://github.com/llvm/llvm-project/commit/ec70627dd17703a2a12ce0f28bd3794aa77d2058
DIFF:
https://github.com/llvm/llvm-project/commit/ec70627dd17703a2a12ce0f28bd3794aa77d2058.diff
Author: Sergio Afonso
Date: 2023-08-10T11:54:45+01:00
New Revision: e5a524b8b5e9d11fbb12ad8ed9b2d998e05e6119
URL:
https://github.com/llvm/llvm-project/commit/e5a524b8b5e9d11fbb12ad8ed9b2d998e05e6119
DIFF:
https://github.com/llvm/llvm-project/commit/e5a524b8b5e9d11fbb12ad8ed9b2d998e05e6119.diff
Author: Sergio Afonso
Date: 2023-09-14T10:33:54+01:00
New Revision: 094a63a20bf54f18efafbb6a727466da0f22a245
URL:
https://github.com/llvm/llvm-project/commit/094a63a20bf54f18efafbb6a727466da0f22a245
DIFF:
https://github.com/llvm/llvm-project/commit/094a63a20bf54f18efafbb6a727466da0f22a245.diff
Author: Sergio Afonso
Date: 2023-09-14T10:35:44+01:00
New Revision: 9058762789c0a83560c2b567a347b993e70b05ae
URL:
https://github.com/llvm/llvm-project/commit/9058762789c0a83560c2b567a347b993e70b05ae
DIFF:
https://github.com/llvm/llvm-project/commit/9058762789c0a83560c2b567a347b993e70b05ae.diff
Author: Sergio Afonso
Date: 2023-03-24T17:13:40Z
New Revision: 33be83415c9b5e9a874fcbddee8e64ecf464c203
URL:
https://github.com/llvm/llvm-project/commit/33be83415c9b5e9a874fcbddee8e64ecf464c203
DIFF:
https://github.com/llvm/llvm-project/commit/33be83415c9b5e9a874fcbddee8e64ecf464c203.diff
LOG:
Author: Sergio Afonso
Date: 2023-04-12T14:59:37+01:00
New Revision: 2266f4a3b38f4b59d313cdd2a9209952afb29d14
URL:
https://github.com/llvm/llvm-project/commit/2266f4a3b38f4b59d313cdd2a9209952afb29d14
DIFF:
https://github.com/llvm/llvm-project/commit/2266f4a3b38f4b59d313cdd2a9209952afb29d14.diff
https://github.com/skatrak approved this pull request.
Thank you Pranav, LGTM. I have just one more comment but no need to wait for
another review by me before merging this. Just make sure @Meinersbur is happy
with it as well!
https://github.com/llvm/llvm-project/pull/93977
___
https://github.com/skatrak edited
https://github.com/llvm/llvm-project/pull/93977
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -682,6 +682,41 @@ convertOmpTeams(omp::TeamsOp op, llvm::IRBuilderBase
&builder,
return bodyGenStatus;
}
+static void
+buildDependData(Operation *op, LLVM::ModuleTranslation &moduleTranslation,
skatrak wrote:
I'd suggest taking `std::optional depends` a
@@ -705,28 +740,7 @@ convertOmpTaskOp(omp::TaskOp taskOp, llvm::IRBuilderBase
&builder,
};
SmallVector dds;
- if (!taskOp.getDependVars().empty() && taskOp.getDepends()) {
-for (auto dep :
- llvm::zip(taskOp.getDependVars(), taskOp.getDepends()->getValue()))
https://github.com/skatrak edited
https://github.com/llvm/llvm-project/pull/93977
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/skatrak commented:
Thank you Pranav, I think this looks good. I just have a few minor comments.
https://github.com/llvm/llvm-project/pull/93977
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/ma
@@ -5252,6 +5660,8 @@ static void emitTargetCall(OpenMPIRBuilder &OMPBuilder,
IRBuilderBase &Builder,
// emitKernelLaunch
auto &&EmitTargetCallFallbackCB =
[&](OpenMPIRBuilder::InsertPointTy IP) -> OpenMPIRBuilder::InsertPointTy
{
+LLVM_DEBUG(dbgs() << "EmitTar
@@ -5572,6 +5999,8 @@ void OpenMPIRBuilder::emitOffloadingArrays(
return;
Builder.restoreIP(AllocaIP);
+ LLVM_DEBUG(dbgs() << "Basicblock before emitOffloadingArrays\n"
+<< *(Builder.GetInsertBlock()) << "\n");
skatrak wrote:
Nit: I
@@ -5212,6 +5273,78 @@ static Function *createOutlinedFunction(
return Func;
}
+// Create an entry point for a target task with the following.
+// It'll have the following signature
+// void @.omp_target_task_proxy_func(i32 %thread.id, ptr %task)
+// This function is called
@@ -0,0 +1,37 @@
+! Offloading test checking the use of the depend clause on
+! the target construct
+! REQUIRES: flang, amdgcn-amd-amdhsa
+! UNSUPPORTED: nvptx64-nvidia-cuda
+! UNSUPPORTED: nvptx64-nvidia-cuda-LTO
+! UNSUPPORTED: aarch64-unknown-linux-gnu
+! UNSUPPORTED: aarch64-
@@ -5272,36 +5682,53 @@ static void emitTargetCall(OpenMPIRBuilder &OMPBuilder,
IRBuilderBase &Builder,
Value *DynCGGroupMem = Builder.getInt32(0);
bool HasNoWait = false;
+ bool HasDependencies = Dependencies.size() > 0;
+ bool RequiresOuterTargetTask = HasNoWait || Ha
@@ -792,6 +792,9 @@ void OpenMPIRBuilder::finalize(Function *Fn) {
if (!OffloadInfoManager.empty())
createOffloadEntriesAndInfoMetadata(ErrorReportFn);
+
+ LLVM_DEBUG(dbgs() << "Module after OMPIRBuilder::finalize\n");
+ LLVM_DEBUG(dbgs() << M << "\n");
---
@@ -1698,6 +1701,64 @@ void OpenMPIRBuilder::createTaskyield(const
LocationDescription &Loc) {
emitTaskyieldImpl(Loc);
}
+// Processes the dependencies in Dependencies and does the following
+// - Allocates space on the stack of an array of DependInfo objects
+// - Populate
@@ -705,28 +728,9 @@ convertOmpTaskOp(omp::TaskOp taskOp, llvm::IRBuilderBase
&builder,
};
SmallVector dds;
- if (!taskOp.getDependVars().empty() && taskOp.getDepends()) {
-for (auto dep :
- llvm::zip(taskOp.getDependVars(), taskOp.getDepends()->getValue()))
https://github.com/skatrak updated
https://github.com/llvm/llvm-project/pull/94359
>From 88a2553168b4fd3ad1b65b855c2bdf5aba09d126 Mon Sep 17 00:00:00 2001
From: Sergio Afonso
Date: Tue, 4 Jun 2024 15:26:38 +0100
Subject: [PATCH 1/2] [Flang][OpenMP] Add -fopenmp-force-usm option to flang
This p
skatrak wrote:
Thank your for the reviews. Merging now since buildbot failure is unrelated.
https://github.com/llvm/llvm-project/pull/94359
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-comm
https://github.com/skatrak closed
https://github.com/llvm/llvm-project/pull/94359
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -223,9 +223,12 @@ class CodeGenAction : public FrontendAction {
std::unique_ptr llvmCtx;
std::unique_ptr llvmModule;
- /// Embeds offload objects given with specified with -fembed-offload-object
+ /// Embeds offload objects specified with -fembed-offload-object
voi
https://github.com/skatrak created
https://github.com/llvm/llvm-project/pull/94359
This patch enables the `-fopenmp-force-usm` option to be passed to the flang
driver, which forwards it to the compiler frontend. This flag, when set,
results in the introduction of the `unified_shared_memory` bi
https://github.com/skatrak created
https://github.com/llvm/llvm-project/pull/100152
This patch modifies the flang driver to introduce the `-fopenmp-targets` option
to the frontend compiler invocations corresponding to the OpenMP host device on
offloading-enabled compilations.
This option hold
skatrak wrote:
> Code changes look good to me. I can't speak to the needs of anyone else using
> offloading.
>
> I see this is copied exactly from `Toolchains/Clang.cpp`. I think that's okay
> for such a small bit of code.
Thank you for the quick review. Yes, it's basically copied from clang,
https://github.com/skatrak updated
https://github.com/llvm/llvm-project/pull/100152
>From cf26a318d3b49eb6217f29405cee9fd2c20f8e8a Mon Sep 17 00:00:00 2001
From: Sergio Afonso
Date: Tue, 23 Jul 2024 16:19:55 +0100
Subject: [PATCH 1/2] [Flang][Driver] Introduce -fopenmp-targets offloading
optio
@@ -492,6 +493,18 @@ void Flang::addOffloadOptions(Compilation &C, const
InputInfoList &Inputs,
if (Args.hasArg(options::OPT_nogpulib))
CmdArgs.push_back("-nogpulib");
}
+
+ // For all the host OpenMP offloading compile jobs we need to pass the
targets
+ // info
@@ -227,3 +227,20 @@
! FORCE-USM-OFFLOAD-SAME: "-fopenmp" "-fopenmp-force-usm"
! FORCE-USM-OFFLOAD-NEXT: "{{[^"]*}}flang-new" "-fc1" "-triple"
"amdgcn-amd-amdhsa"
! FORCE-USM-OFFLOAD-SAME: "-fopenmp" "-fopenmp-force-usm"
+
skatrak wrote:
Done.
https://github
https://github.com/skatrak updated
https://github.com/llvm/llvm-project/pull/100152
>From cf26a318d3b49eb6217f29405cee9fd2c20f8e8a Mon Sep 17 00:00:00 2001
From: Sergio Afonso
Date: Tue, 23 Jul 2024 16:19:55 +0100
Subject: [PATCH 1/3] [Flang][Driver] Introduce -fopenmp-targets offloading
optio
https://github.com/skatrak updated
https://github.com/llvm/llvm-project/pull/100152
>From cf26a318d3b49eb6217f29405cee9fd2c20f8e8a Mon Sep 17 00:00:00 2001
From: Sergio Afonso
Date: Tue, 23 Jul 2024 16:19:55 +0100
Subject: [PATCH 1/4] [Flang][Driver] Introduce -fopenmp-targets offloading
optio
skatrak wrote:
I'm not very knowledgeable on the set of offloading-related options clang
supports, how those impact the set of invocations and options produced by the
driver, or how these options eventually impact passes and codegen. Much less
about potential shortcomings and improvements to t
@@ -492,6 +493,18 @@ void Flang::addOffloadOptions(Compilation &C, const
InputInfoList &Inputs,
if (Args.hasArg(options::OPT_nogpulib))
CmdArgs.push_back("-nogpulib");
}
+
+ // For all the host OpenMP offloading compile jobs we need to pass the
targets
+ // info
skatrak wrote:
> The only issue I see is that this PR adds a new driver flag that may be used
> to compile the applications. Renaming the user visible flags is not that
> easy. But if they get renamed before any compiler release then it should be
> fine.
Thank you for the comment. Actually, t
https://github.com/skatrak updated
https://github.com/llvm/llvm-project/pull/100152
>From cf26a318d3b49eb6217f29405cee9fd2c20f8e8a Mon Sep 17 00:00:00 2001
From: Sergio Afonso
Date: Tue, 23 Jul 2024 16:19:55 +0100
Subject: [PATCH 1/5] [Flang][Driver] Introduce -fopenmp-targets offloading
optio
@@ -492,6 +493,18 @@ void Flang::addOffloadOptions(Compilation &C, const
InputInfoList &Inputs,
if (Args.hasArg(options::OPT_nogpulib))
CmdArgs.push_back("-nogpulib");
}
+
+ // For all the host OpenMP offloading compile jobs we need to pass the
targets
+ // info
@@ -492,6 +493,18 @@ void Flang::addOffloadOptions(Compilation &C, const
InputInfoList &Inputs,
if (Args.hasArg(options::OPT_nogpulib))
CmdArgs.push_back("-nogpulib");
}
+
+ // For all the host OpenMP offloading compile jobs we need to pass the
targets
+ // info
@@ -492,6 +493,18 @@ void Flang::addOffloadOptions(Compilation &C, const
InputInfoList &Inputs,
if (Args.hasArg(options::OPT_nogpulib))
CmdArgs.push_back("-nogpulib");
}
+
+ // For all the host OpenMP offloading compile jobs we need to pass the
targets
+ // info
https://github.com/skatrak updated
https://github.com/llvm/llvm-project/pull/100152
>From 3861b28deeb1b558f182f2ab5680b123fd94c005 Mon Sep 17 00:00:00 2001
From: Sergio Afonso
Date: Tue, 23 Jul 2024 16:19:55 +0100
Subject: [PATCH] [Flang][Driver] Introduce -fopenmp-targets offloading option
Th
skatrak wrote:
Thank you all for your reviews. I think it should be ok to merge at this point,
but I'll wait until tomorrow to give some time in case there are any remaining
concerns about this change.
https://github.com/llvm/llvm-project/pull/100152
___
https://github.com/skatrak updated
https://github.com/llvm/llvm-project/pull/100152
>From e59c38db58ba5ca2eef66d3b3477d5ad81043228 Mon Sep 17 00:00:00 2001
From: Sergio Afonso
Date: Tue, 23 Jul 2024 16:19:55 +0100
Subject: [PATCH] [Flang][Driver] Introduce -fopenmp-targets offloading option
Th
https://github.com/skatrak updated
https://github.com/llvm/llvm-project/pull/100152
>From e59c38db58ba5ca2eef66d3b3477d5ad81043228 Mon Sep 17 00:00:00 2001
From: Sergio Afonso
Date: Tue, 23 Jul 2024 16:19:55 +0100
Subject: [PATCH 1/2] [Flang][Driver] Introduce -fopenmp-targets offloading
optio
https://github.com/skatrak closed
https://github.com/llvm/llvm-project/pull/100152
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/skatrak edited
https://github.com/llvm/llvm-project/pull/100154
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/skatrak commented:
Thanks for working on my previous comments. I just have a couple more minor
ones.
https://github.com/llvm/llvm-project/pull/93977
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-
@@ -5272,36 +5682,53 @@ static void emitTargetCall(OpenMPIRBuilder &OMPBuilder,
IRBuilderBase &Builder,
Value *DynCGGroupMem = Builder.getInt32(0);
bool HasNoWait = false;
+ bool HasDependencies = Dependencies.size() > 0;
+ bool RequiresOuterTargetTask = HasNoWait || Ha
@@ -5229,13 +5382,284 @@ static void emitTargetOutlinedFunction(
OMPBuilder.emitTargetRegionFunction(EntryInfo, GenerateOutlinedFunction,
true,
OutlinedFn, OutlinedFnID);
}
+OpenMPIRBuilder::InsertPointTy OpenMPIRBuilder::emitTargetTask(
https://github.com/skatrak edited
https://github.com/llvm/llvm-project/pull/93977
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,83 @@
+! Offloading test checking the use of the depend clause on
+! the target construct
+! REQUIRES: flang, amdgcn-amd-amdhsa
+! UNSUPPORTED: nvptx64-nvidia-cuda
+! UNSUPPORTED: nvptx64-nvidia-cuda-LTO
+! UNSUPPORTED: aarch64-unknown-linux-gnu
+! UNSUPPORTED: aarch64-
@@ -0,0 +1,83 @@
+! Offloading test checking the use of the depend clause on
+! the target construct
+! REQUIRES: flang, amdgcn-amd-amdhsa
+! UNSUPPORTED: nvptx64-nvidia-cuda
+! UNSUPPORTED: nvptx64-nvidia-cuda-LTO
+! UNSUPPORTED: aarch64-unknown-linux-gnu
+! UNSUPPORTED: aarch64-
@@ -705,28 +728,9 @@ convertOmpTaskOp(omp::TaskOp taskOp, llvm::IRBuilderBase
&builder,
};
SmallVector dds;
- if (!taskOp.getDependVars().empty() && taskOp.getDepends()) {
-for (auto dep :
- llvm::zip(taskOp.getDependVars(), taskOp.getDepends()->getValue()))
@@ -0,0 +1,83 @@
+! Offloading test checking the use of the depend clause on
+! the target construct
+! REQUIRES: flang, amdgcn-amd-amdhsa
+! UNSUPPORTED: nvptx64-nvidia-cuda
+! UNSUPPORTED: nvptx64-nvidia-cuda-LTO
+! UNSUPPORTED: aarch64-unknown-linux-gnu
+! UNSUPPORTED: aarch64-
https://github.com/skatrak ready_for_review
https://github.com/llvm/llvm-project/pull/112533
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/skatrak edited
https://github.com/llvm/llvm-project/pull/112533
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/skatrak edited
https://github.com/llvm/llvm-project/pull/112533
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1103,6 +1105,13 @@ bool ConstructDecompositionT::applyClause(
return applyToOutermost(node);
}
+template
+bool ConstructDecompositionT::applyClause(
+const tomp::clause::OmpxBareT &clause,
+const ClauseTy *node) {
+ return applyToAll(node);
ska
@@ -2331,8 +2332,10 @@ void CGOpenMPRuntime::emitBarrierCall(CodeGenFunction
&CGF, SourceLocation Loc,
auto *OMPRegionInfo =
dyn_cast_or_null(CGF.CapturedStmtInfo);
if (CGF.CGM.getLangOpts().OpenMPIRBuilder) {
-CGF.Builder.restoreIP(OMPBuilder.createBarrier(
-
@@ -1171,12 +1179,15 @@ void OpenMPIRBuilder::emitCancelationCheckImpl(Value
*CancelFlag,
// post finalization block that is known to the FiniCB callback.
Builder.SetInsertPoint(CancellationBlock);
if (ExitCB)
-ExitCB(Builder.saveIP());
+if (Error Err = ExitCB(Bu
@@ -2331,8 +2332,10 @@ void CGOpenMPRuntime::emitBarrierCall(CodeGenFunction
&CGF, SourceLocation Loc,
auto *OMPRegionInfo =
dyn_cast_or_null(CGF.CapturedStmtInfo);
if (CGF.CGM.getLangOpts().OpenMPIRBuilder) {
-CGF.Builder.restoreIP(OMPBuilder.createBarrier(
-
@@ -1496,7 +1507,8 @@ IRBuilder<>::InsertPoint OpenMPIRBuilder::createParallel(
// Let the caller create the body.
assert(BodyGenCB && "Expected body generation callback!");
InsertPointTy CodeGenIP(PRegBodyBB, PRegBodyBB->begin());
- BodyGenCB(InnerAllocaIP, CodeGenIP);
@@ -1103,6 +1105,13 @@ bool ConstructDecompositionT::applyClause(
return applyToOutermost(node);
}
+template
+bool ConstructDecompositionT::applyClause(
+const tomp::clause::OmpxBareT &clause,
+const ClauseTy *node) {
+ return applyToAll(node);
ska
https://github.com/skatrak closed
https://github.com/llvm/llvm-project/pull/112533
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1103,6 +1105,13 @@ bool ConstructDecompositionT::applyClause(
return applyToOutermost(node);
}
+template
+bool ConstructDecompositionT::applyClause(
+const tomp::clause::OmpxBareT &clause,
+const ClauseTy *node) {
+ return applyToAll(node);
ska
https://github.com/skatrak edited
https://github.com/llvm/llvm-project/pull/06
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -350,6 +350,10 @@ bool
ClauseProcessor::processNowait(mlir::omp::NowaitClauseOps &result) const {
return markClauseOccurrence(result.nowait);
}
+bool ClauseProcessor::processBare(mlir::omp::BareClauseOps &result) const {
skatrak wrote:
Nit: Move above `
https://github.com/skatrak approved this pull request.
Thank you Ivan, Flang and MLIR changes look good to me. Sorry for the delay
getting back to this!
https://github.com/llvm/llvm-project/pull/06
___
cfe-commits mailing list
cfe-commits@lists.ll
@@ -1672,8 +1672,9 @@ void TargetOp::build(OpBuilder &builder, OperationState
&state,
// TODO Store clauses in op: allocateVars, allocatorVars, inReductionVars,
// inReductionByref, inReductionSyms.
TargetOp::build(builder, state, /*allocate_vars=*/{}, /*allocator_vars=*
https://github.com/skatrak edited
https://github.com/llvm/llvm-project/pull/112533
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -2331,8 +2332,11 @@ void CGOpenMPRuntime::emitBarrierCall(CodeGenFunction
&CGF, SourceLocation Loc,
auto *OMPRegionInfo =
dyn_cast_or_null(CGF.CapturedStmtInfo);
if (CGF.CGM.getLangOpts().OpenMPIRBuilder) {
-CGF.Builder.restoreIP(OMPBuilder.createBarrier(
-
skatrak wrote:
Thank you @Meinersbur for your comments. I just updated the PR description and
replaced `cantFail()` calls in unit tests as you suggested, let me know if that
addresses your concerns.
https://github.com/llvm/llvm-project/pull/115863
__
https://github.com/skatrak edited
https://github.com/llvm/llvm-project/pull/115863
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -2331,8 +2332,11 @@ void CGOpenMPRuntime::emitBarrierCall(CodeGenFunction
&CGF, SourceLocation Loc,
auto *OMPRegionInfo =
dyn_cast_or_null(CGF.CapturedStmtInfo);
if (CGF.CGM.getLangOpts().OpenMPIRBuilder) {
-CGF.Builder.restoreIP(OMPBuilder.createBarrier(
-
1 - 100 of 149 matches
Mail list logo