Skip to content

Commit 3c206ac

Browse files
MaskRayJaddyen
authored andcommitted
[RISCV] Remove fixup_riscv_pcrel_hi20 from evaluateTargetFixup. NFC
It can be handled by the target-neutral code path in MCAssembler::evaluateFixup.
1 parent 87abe4f commit 3c206ac

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

llvm/lib/Target/RISCV/MCTargetDesc/RISCVAsmBackend.cpp

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -71,8 +71,7 @@ MCFixupKindInfo RISCVAsmBackend::getFixupKindInfo(MCFixupKind Kind) const {
7171
{"fixup_riscv_lo12_i", 20, 12, 0},
7272
{"fixup_riscv_12_i", 20, 12, 0},
7373
{"fixup_riscv_lo12_s", 0, 32, 0},
74-
{"fixup_riscv_pcrel_hi20", 12, 20,
75-
MCFixupKindInfo::FKF_IsPCRel | MCFixupKindInfo::FKF_IsTarget},
74+
{"fixup_riscv_pcrel_hi20", 12, 20, MCFixupKindInfo::FKF_IsPCRel},
7675
{"fixup_riscv_pcrel_lo12_i", 20, 12,
7776
MCFixupKindInfo::FKF_IsPCRel | MCFixupKindInfo::FKF_IsTarget},
7877
{"fixup_riscv_pcrel_lo12_s", 0, 32,
@@ -580,11 +579,6 @@ bool RISCVAsmBackend::evaluateTargetFixup(
580579
switch (Fixup.getTargetKind()) {
581580
default:
582581
llvm_unreachable("Unexpected fixup kind!");
583-
case RISCV::fixup_riscv_pcrel_hi20:
584-
AUIPCFixup = &Fixup;
585-
AUIPCDF = DF;
586-
AUIPCTarget = Target;
587-
break;
588582
case RISCV::fixup_riscv_pcrel_lo12_i:
589583
case RISCV::fixup_riscv_pcrel_lo12_s: {
590584
AUIPCFixup = cast<RISCVMCExpr>(Fixup.getValue())->getPCRelHiFixup(&AUIPCDF);

0 commit comments

Comments
 (0)