File tree Expand file tree Collapse file tree 2 files changed +5
-7
lines changed
lib/Target/AVR/MCTargetDesc Expand file tree Collapse file tree 2 files changed +5
-7
lines changed Original file line number Diff line number Diff line change @@ -495,19 +495,17 @@ class LLVM_ABI MCTargetExpr : public MCExpr {
495
495
class LLVM_ABI MCSpecifierExpr : public MCExpr {
496
496
protected:
497
497
const MCExpr *Expr;
498
- // Target-specific relocation specifier code
499
- const Spec specifier;
500
498
501
499
explicit MCSpecifierExpr (const MCExpr *Expr, Spec S, SMLoc Loc = SMLoc())
502
- : MCExpr(Specifier, Loc), Expr(Expr ), specifier(S ) {}
500
+ : MCExpr(Specifier, Loc, S ), Expr(Expr ) {}
503
501
504
502
public:
505
503
static const MCSpecifierExpr *create (const MCExpr *Expr, Spec S,
506
504
MCContext &Ctx, SMLoc Loc = SMLoc());
507
505
static const MCSpecifierExpr *create (const MCSymbol *Sym, Spec S,
508
506
MCContext &Ctx, SMLoc Loc = SMLoc());
509
507
510
- Spec getSpecifier () const { return specifier ; }
508
+ Spec getSpecifier () const { return getSubclassData () ; }
511
509
const MCExpr *getSubExpr () const { return Expr; }
512
510
513
511
static bool classof (const MCExpr *E) {
Original file line number Diff line number Diff line change @@ -63,7 +63,7 @@ AVRMCExpr::Specifier AVRMCExpr::parseSpecifier(StringRef Name) {
63
63
const char *AVRMCExpr::getName () const {
64
64
const auto &Modifier =
65
65
llvm::find_if (ModifierNames, [this ](ModifierEntry const &Mod) {
66
- return Mod.specifier == specifier ;
66
+ return Mod.specifier == getSpecifier () ;
67
67
});
68
68
69
69
if (Modifier != std::end (ModifierNames)) {
@@ -75,7 +75,7 @@ const char *AVRMCExpr::getName() const {
75
75
AVR::Fixups AVRMCExpr::getFixupKind () const {
76
76
AVR::Fixups Kind = AVR::Fixups::LastTargetFixupKind;
77
77
78
- switch (specifier ) {
78
+ switch (getSpecifier () ) {
79
79
case AVR::S_LO8:
80
80
Kind = isNegated () ? AVR::fixup_lo8_ldi_neg : AVR::fixup_lo8_ldi;
81
81
break ;
@@ -133,7 +133,7 @@ int64_t AVRMCExpr::evaluateAsInt64(int64_t Value) const {
133
133
if (Negated)
134
134
Value *= -1 ;
135
135
136
- switch (specifier ) {
136
+ switch (getSpecifier () ) {
137
137
case AVR::S_LO8:
138
138
Value &= 0xff ;
139
139
break ;
You can’t perform that action at this time.
0 commit comments