File tree Expand file tree Collapse file tree 1 file changed +8
-0
lines changed Expand file tree Collapse file tree 1 file changed +8
-0
lines changed Original file line number Diff line number Diff line change 49
49
#include " llvm/IR/DebugLoc.h"
50
50
#include " llvm/InitializePasses.h"
51
51
#include " llvm/Support/Debug.h"
52
+ #include " llvm/Transforms/Yk/BasicBlockTracer.h"
52
53
53
54
#include < set>
54
55
@@ -103,6 +104,13 @@ bool FixStackmapsSpillReloads::runOnMachineFunction(MachineFunction &MF) {
103
104
// removed during lowering?
104
105
if (MI.getOpcode () != TargetOpcode::STACKMAP &&
105
106
MI.getOpcode () != TargetOpcode::PATCHPOINT) {
107
+ MachineOperand Op = MI.getOperand (0 );
108
+ if (Op.isGlobal () && Op.getGlobal ()->getGlobalIdentifier () == YK_TRACE_FUNCTION) {
109
+ // `YK_TRACE_FUNCTION` calls don't require stackmaps so we don't
110
+ // need to adjust anything here. In fact, doing so will skew any
111
+ // stackmap that follows.
112
+ continue ;
113
+ }
106
114
// If we see a normal function call we know it will be followed by a
107
115
// STACKMAP instruction. Set `Collect` to `true` to collect all spill
108
116
// reload instructions between this call and the STACKMAP instruction.
You can’t perform that action at this time.
0 commit comments