You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We've 2 ops:
1. nvvm.griddepcontrol.wait
2. nvvm.griddepcontrol.launch_dependents
They are related to Grid Dependent Launch (or programmatic dependent
launch in CUDA) and same concept. This PR unifies both ops into a single
one.
Causes the executing thread to wait until all prerequisite grids in flight
3051
+
If the $kind attribute is set to `wait`, it causes the
3052
+
executing thread to wait until all prerequisite grids in flight
3044
3053
have completed and all the memory operations from the prerequisite grids
3045
3054
are performed and made visible to the current grid.
3046
3055
3056
+
When the $kind is launch_dependents, it signals that specific dependents
3057
+
the runtime system designated to react to this instruction can be scheduled
3058
+
as soon as all other CTAs in the grid issue the same instruction or have
3059
+
completed.
3047
3060
3048
3061
[For more information, see PTX ISA](https://docs.nvidia.com/cuda/parallel-thread-execution/#parallel-synchronization-and-communication-instructions-griddepcontrol)
Signals that specific dependents the runtime system designated to react to
3058
-
this instruction can be scheduled as soon as all other CTAs in the grid
3059
-
issue the same instruction or have completed.
3064
+
let arguments = (ins GridDepActionAttr:$kind);
3060
3065
3066
+
let assemblyFormat = "$kind attr-dict";
3061
3067
3062
-
[For more information, see PTX ISA](https://docs.nvidia.com/cuda/parallel-thread-execution/#parallel-synchronization-and-communication-instructions-griddepcontrol)
3068
+
string llvmBuilder = [{
3069
+
llvm::Intrinsic::ID id;
3070
+
switch ($kind) {
3071
+
case NVVM::GridDepActionKind::wait:
3072
+
id = llvm::Intrinsic::nvvm_griddepcontrol_wait;
3073
+
break;
3074
+
case NVVM::GridDepActionKind::launch_dependents:
3075
+
id = llvm::Intrinsic::nvvm_griddepcontrol_launch_dependents;
0 commit comments