File tree Expand file tree Collapse file tree 1 file changed +11
-11
lines changed Expand file tree Collapse file tree 1 file changed +11
-11
lines changed Original file line number Diff line number Diff line change @@ -3859,20 +3859,20 @@ SDValue SITargetLowering::LowerCall(CallLoweringInfo &CLI,
3859
3859
assert(Mask && "Missing call preserved mask for calling convention");
3860
3860
Ops.push_back(DAG.getRegisterMask(Mask));
3861
3861
3862
- if (InGlue.getNode())
3863
- Ops.push_back(InGlue);
3864
-
3865
- // NOTE: This potentially results in *two* glue operands, and the wrong one
3866
- // might possibly show up where the other was intended. In particular,
3867
- // Emitter::EmitMachineNode() expects only the glued convergence token if it
3868
- // exists. Similarly, the selection of the call expects to match only the
3869
- // InGlue operand if it exists.
3870
3862
if (SDValue Token = CLI.ConvergenceControlToken) {
3871
- Ops.push_back(SDValue(DAG.getMachineNode(TargetOpcode::CONVERGENCECTRL_GLUE,
3872
- DL, MVT::Glue, Token),
3873
- 0));
3863
+ SmallVector<SDValue, 2> GlueOps;
3864
+ GlueOps.push_back(Token);
3865
+ if (InGlue)
3866
+ GlueOps.push_back(InGlue);
3867
+
3868
+ InGlue = SDValue(DAG.getMachineNode(TargetOpcode::CONVERGENCECTRL_GLUE, DL,
3869
+ MVT::Glue, GlueOps),
3870
+ 0);
3874
3871
}
3875
3872
3873
+ if (InGlue)
3874
+ Ops.push_back(InGlue);
3875
+
3876
3876
SDVTList NodeTys = DAG.getVTList(MVT::Other, MVT::Glue);
3877
3877
3878
3878
// If we're doing a tall call, use a TC_RETURN here rather than an
You can’t perform that action at this time.
0 commit comments