Skip to content

Commit 1a6d770

Browse files
author
Krzysztof Parzyszek
committed
[Hexagon] Pass Hexagon::PC to InitializeHexagonMCRegisterInfo
That will make MCRegisterInfo::getProgramCounter return the right thing.
1 parent 110825b commit 1a6d770

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCTargetDesc.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,8 @@ llvm::MCInstrInfo *llvm::createHexagonMCInstrInfo() {
297297

298298
static MCRegisterInfo *createHexagonMCRegisterInfo(const Triple &TT) {
299299
MCRegisterInfo *X = new MCRegisterInfo();
300-
InitHexagonMCRegisterInfo(X, Hexagon::R31);
300+
InitHexagonMCRegisterInfo(X, Hexagon::R31, /*DwarfFlavour=*/0,
301+
/*EHFlavour=*/0, /*PC=*/Hexagon::PC);
301302
return X;
302303
}
303304

0 commit comments

Comments
 (0)