Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/llvm/llvm-project.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKrzysztof Parzyszek <kparzysz@quicinc.com>2022-11-13 23:33:26 +0300
committerKrzysztof Parzyszek <kparzysz@quicinc.com>2022-11-13 23:35:11 +0300
commit1a6d770447c57222470ca0f2d029f31ed7ed750e (patch)
treed91f753cc667f4fcc4006229cb63bb8fae2e4a44
parent110825b677f9c85c9e0ed94a06893d3290d58215 (diff)
[Hexagon] Pass Hexagon::PC to InitializeHexagonMCRegisterInfo
That will make MCRegisterInfo::getProgramCounter return the right thing.
-rw-r--r--llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCTargetDesc.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCTargetDesc.cpp b/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCTargetDesc.cpp
index 3fd69a1b9760..8ee53624aeba 100644
--- a/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCTargetDesc.cpp
+++ b/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCTargetDesc.cpp
@@ -297,7 +297,8 @@ llvm::MCInstrInfo *llvm::createHexagonMCInstrInfo() {
static MCRegisterInfo *createHexagonMCRegisterInfo(const Triple &TT) {
MCRegisterInfo *X = new MCRegisterInfo();
- InitHexagonMCRegisterInfo(X, Hexagon::R31);
+ InitHexagonMCRegisterInfo(X, Hexagon::R31, /*DwarfFlavour=*/0,
+ /*EHFlavour=*/0, /*PC=*/Hexagon::PC);
return X;
}