Skip to content

Commit 0779b88

Browse files
committed
fixup! use different way to get module flag
1 parent e3088d7 commit 0779b88

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

llvm/lib/Target/RISCV/RISCVISelLowering.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929
#include "llvm/CodeGen/MachineFunction.h"
3030
#include "llvm/CodeGen/MachineInstrBuilder.h"
3131
#include "llvm/CodeGen/MachineJumpTableInfo.h"
32-
#include "llvm/CodeGen/MachineModuleInfo.h"
3332
#include "llvm/CodeGen/MachineRegisterInfo.h"
3433
#include "llvm/CodeGen/SDPatternMatch.h"
3534
#include "llvm/CodeGen/SelectionDAGAddressAnalysis.h"
@@ -8375,7 +8374,8 @@ SDValue RISCVTargetLowering::lowerINIT_TRAMPOLINE(SDValue Op,
83758374

83768375
const bool HasCFBranch =
83778376
Subtarget.hasStdExtZicfilp() &&
8378-
DAG.getMMI()->getModule()->getModuleFlag("cf-protection-branch");
8377+
DAG.getMachineFunction().getFunction().getParent()->getModuleFlag(
8378+
"cf-protection-branch");
83798379
const unsigned StaticChainIdx = HasCFBranch ? 5 : 4;
83808380
const unsigned StaticChainOffset = StaticChainIdx * 4;
83818381
const unsigned FunctionAddressOffset = StaticChainOffset + 8;

0 commit comments

Comments
 (0)