reference, declarationdefinition
definition → references, declarations, derived classes, virtual overrides
reference to multiple definitions → definitions
unreferenced

References

include/llvm/Support/Casting.h
   58     return To::classof(&Val);
  106     return isa_impl<To, From>::doit(*Val);
  122     return isa_impl_wrap<To, SimpleFrom,
  132     return isa_impl_cl<To,FromTy>::doit(Val);
  142   return isa_impl_wrap<X, const Y,
  176   using ret_type = const To *; // Constant pointer arg case, return const Ty*
  198   using ret_type = typename cast_retty<To, SimpleFrom>::ret_type;
  204   using ret_type = typename cast_retty_impl<To,FromTy>::ret_type;
  210       To, From, typename simplify_type<From>::SimpleType>::ret_type;
  227   static typename cast_retty<To, FromTy>::ret_type doit(const FromTy &Val) {
  228     typename cast_retty<To, FromTy>::ret_type Res2
  256 inline typename cast_retty<X, Y>::ret_type cast(Y &Val) {
  263 inline typename cast_retty<X, Y *>::ret_type cast(Y *Val) {
  265   return cast_convert_val<X, Y*,
  337 LLVM_NODISCARD inline typename cast_retty<X, Y>::ret_type dyn_cast(Y &Val) {
  342 LLVM_NODISCARD inline typename cast_retty<X, Y *>::ret_type dyn_cast(Y *Val) {
  343   return isa<X>(Val) ? cast<X>(Val) : nullptr;
  343   return isa<X>(Val) ? cast<X>(Val) : nullptr;
lib/Target/Mips/AsmParser/MipsAsmParser.cpp
  703       return MipsMCExpr::create(MipsMCExpr::MEK_GOT_CALL, E, Ctx);
  703       return MipsMCExpr::create(MipsMCExpr::MEK_GOT_CALL, E, Ctx);
  705       return MipsMCExpr::create(MipsMCExpr::MEK_CALL_HI16, E, Ctx);
  705       return MipsMCExpr::create(MipsMCExpr::MEK_CALL_HI16, E, Ctx);
  707       return MipsMCExpr::create(MipsMCExpr::MEK_CALL_LO16, E, Ctx);
  707       return MipsMCExpr::create(MipsMCExpr::MEK_CALL_LO16, E, Ctx);
  709       return MipsMCExpr::create(MipsMCExpr::MEK_DTPREL_HI, E, Ctx);
  709       return MipsMCExpr::create(MipsMCExpr::MEK_DTPREL_HI, E, Ctx);
  711       return MipsMCExpr::create(MipsMCExpr::MEK_DTPREL_LO, E, Ctx);
  711       return MipsMCExpr::create(MipsMCExpr::MEK_DTPREL_LO, E, Ctx);
  713       return MipsMCExpr::create(MipsMCExpr::MEK_GOT, E, Ctx);
  713       return MipsMCExpr::create(MipsMCExpr::MEK_GOT, E, Ctx);
  715       return MipsMCExpr::create(MipsMCExpr::MEK_GOT_DISP, E, Ctx);
  715       return MipsMCExpr::create(MipsMCExpr::MEK_GOT_DISP, E, Ctx);
  717       return MipsMCExpr::create(MipsMCExpr::MEK_GOT_HI16, E, Ctx);
  717       return MipsMCExpr::create(MipsMCExpr::MEK_GOT_HI16, E, Ctx);
  719       return MipsMCExpr::create(MipsMCExpr::MEK_GOT_LO16, E, Ctx);
  719       return MipsMCExpr::create(MipsMCExpr::MEK_GOT_LO16, E, Ctx);
  721       return MipsMCExpr::create(MipsMCExpr::MEK_GOT_OFST, E, Ctx);
  721       return MipsMCExpr::create(MipsMCExpr::MEK_GOT_OFST, E, Ctx);
  723       return MipsMCExpr::create(MipsMCExpr::MEK_GOT_PAGE, E, Ctx);
  723       return MipsMCExpr::create(MipsMCExpr::MEK_GOT_PAGE, E, Ctx);
  725       return MipsMCExpr::create(MipsMCExpr::MEK_GOTTPREL, E, Ctx);
  725       return MipsMCExpr::create(MipsMCExpr::MEK_GOTTPREL, E, Ctx);
  727       return MipsMCExpr::create(MipsMCExpr::MEK_GPREL, E, Ctx);
  727       return MipsMCExpr::create(MipsMCExpr::MEK_GPREL, E, Ctx);
  729       return MipsMCExpr::create(MipsMCExpr::MEK_HI, E, Ctx);
  729       return MipsMCExpr::create(MipsMCExpr::MEK_HI, E, Ctx);
  731       return MipsMCExpr::create(MipsMCExpr::MEK_HIGHER, E, Ctx);
  731       return MipsMCExpr::create(MipsMCExpr::MEK_HIGHER, E, Ctx);
  733       return MipsMCExpr::create(MipsMCExpr::MEK_HIGHEST, E, Ctx);
  733       return MipsMCExpr::create(MipsMCExpr::MEK_HIGHEST, E, Ctx);
  735       return MipsMCExpr::create(MipsMCExpr::MEK_LO, E, Ctx);
  735       return MipsMCExpr::create(MipsMCExpr::MEK_LO, E, Ctx);
  737       return MipsMCExpr::create(MipsMCExpr::MEK_NEG, E, Ctx);
  737       return MipsMCExpr::create(MipsMCExpr::MEK_NEG, E, Ctx);
  739       return MipsMCExpr::create(MipsMCExpr::MEK_PCREL_HI16, E, Ctx);
  739       return MipsMCExpr::create(MipsMCExpr::MEK_PCREL_HI16, E, Ctx);
  741       return MipsMCExpr::create(MipsMCExpr::MEK_PCREL_LO16, E, Ctx);
  741       return MipsMCExpr::create(MipsMCExpr::MEK_PCREL_LO16, E, Ctx);
  743       return MipsMCExpr::create(MipsMCExpr::MEK_TLSGD, E, Ctx);
  743       return MipsMCExpr::create(MipsMCExpr::MEK_TLSGD, E, Ctx);
  745       return MipsMCExpr::create(MipsMCExpr::MEK_TLSLDM, E, Ctx);
  745       return MipsMCExpr::create(MipsMCExpr::MEK_TLSLDM, E, Ctx);
  747       return MipsMCExpr::create(MipsMCExpr::MEK_TPREL_HI, E, Ctx);
  747       return MipsMCExpr::create(MipsMCExpr::MEK_TPREL_HI, E, Ctx);
  749       return MipsMCExpr::create(MipsMCExpr::MEK_TPREL_LO, E, Ctx);
  749       return MipsMCExpr::create(MipsMCExpr::MEK_TPREL_LO, E, Ctx);
 2864         const MCExpr *CallHiExpr = MipsMCExpr::create(MipsMCExpr::MEK_CALL_HI16,
 2864         const MCExpr *CallHiExpr = MipsMCExpr::create(MipsMCExpr::MEK_CALL_HI16,
 2866         const MCExpr *CallLoExpr = MipsMCExpr::create(MipsMCExpr::MEK_CALL_LO16,
 2866         const MCExpr *CallLoExpr = MipsMCExpr::create(MipsMCExpr::MEK_CALL_LO16,
 2876             MipsMCExpr::create(MipsMCExpr::MEK_GOT_CALL, SymExpr, getContext());
 2876             MipsMCExpr::create(MipsMCExpr::MEK_GOT_CALL, SymExpr, getContext());
 2909           MipsMCExpr::create(MipsMCExpr::MEK_GOT_HI16, SymExpr, getContext());
 2909           MipsMCExpr::create(MipsMCExpr::MEK_GOT_HI16, SymExpr, getContext());
 2910       const MCExpr *CallLoExpr = MipsMCExpr::create(
 2911           MipsMCExpr::MEK_GOT_LO16, Res.getSymA(), getContext());
 2932     const MipsMCExpr *GotExpr = nullptr;
 2942       GotExpr = MipsMCExpr::create(MipsMCExpr::MEK_GOT_DISP, Res.getSymA(),
 2942       GotExpr = MipsMCExpr::create(MipsMCExpr::MEK_GOT_DISP, Res.getSymA(),
 2971             MipsMCExpr::create(MipsMCExpr::MEK_GOT, SymExpr, getContext());
 2971             MipsMCExpr::create(MipsMCExpr::MEK_GOT, SymExpr, getContext());
 2972         LoExpr = MipsMCExpr::create(MipsMCExpr::MEK_LO, SymExpr, getContext());
 2972         LoExpr = MipsMCExpr::create(MipsMCExpr::MEK_LO, SymExpr, getContext());
 2977         GotExpr = MipsMCExpr::create(MipsMCExpr::MEK_GOT, Res.getSymA(),
 2977         GotExpr = MipsMCExpr::create(MipsMCExpr::MEK_GOT, Res.getSymA(),
 2998   const MipsMCExpr *HiExpr =
 2999       MipsMCExpr::create(MipsMCExpr::MEK_HI, SymExpr, getContext());
 2999       MipsMCExpr::create(MipsMCExpr::MEK_HI, SymExpr, getContext());
 3000   const MipsMCExpr *LoExpr =
 3001       MipsMCExpr::create(MipsMCExpr::MEK_LO, SymExpr, getContext());
 3001       MipsMCExpr::create(MipsMCExpr::MEK_LO, SymExpr, getContext());
 3012     const MipsMCExpr *HighestExpr =
 3013         MipsMCExpr::create(MipsMCExpr::MEK_HIGHEST, SymExpr, getContext());
 3013         MipsMCExpr::create(MipsMCExpr::MEK_HIGHEST, SymExpr, getContext());
 3014     const MipsMCExpr *HigherExpr =
 3015         MipsMCExpr::create(MipsMCExpr::MEK_HIGHER, SymExpr, getContext());
 3015         MipsMCExpr::create(MipsMCExpr::MEK_HIGHER, SymExpr, getContext());
 3212     const MipsMCExpr *GotExpr =
 3213         MipsMCExpr::create(MipsMCExpr::MEK_GOT, GotSym, getContext());
 3213         MipsMCExpr::create(MipsMCExpr::MEK_GOT, GotSym, getContext());
 3225     const MipsMCExpr *HiExpr =
 3226         MipsMCExpr::create(MipsMCExpr::MEK_HI, HiSym, getContext());
 3226         MipsMCExpr::create(MipsMCExpr::MEK_HI, HiSym, getContext());
 3239       const MipsMCExpr *HighestExpr =
 3240           MipsMCExpr::create(MipsMCExpr::MEK_HIGHEST, HighestSym, getContext());
 3240           MipsMCExpr::create(MipsMCExpr::MEK_HIGHEST, HighestSym, getContext());
 3243       const MipsMCExpr *HigherExpr =
 3244           MipsMCExpr::create(MipsMCExpr::MEK_HIGHER, HigherSym, getContext());
 3244           MipsMCExpr::create(MipsMCExpr::MEK_HIGHER, HigherSym, getContext());
 3332   const MipsMCExpr *LoExpr =
 3333       MipsMCExpr::create(MipsMCExpr::MEK_LO, LoSym, getContext());
 3333       MipsMCExpr::create(MipsMCExpr::MEK_LO, LoSym, getContext());
 3384   const MipsMCExpr *LoExpr =
 3385       MipsMCExpr::create(MipsMCExpr::MEK_LO, LoSym, getContext());
 3385       MipsMCExpr::create(MipsMCExpr::MEK_LO, LoSym, getContext());
 3467   const MipsMCExpr *LoExpr =
 3468       MipsMCExpr::create(MipsMCExpr::MEK_LO, LoSym, getContext());
 3468       MipsMCExpr::create(MipsMCExpr::MEK_LO, LoSym, getContext());
 3633         MipsMCExpr::create(MipsMCExpr::MEK_LO, ExprOffset, getContext()));
 3633         MipsMCExpr::create(MipsMCExpr::MEK_LO, ExprOffset, getContext()));
 3635         MipsMCExpr::create(MipsMCExpr::MEK_HI, ExprOffset, getContext()));
 3635         MipsMCExpr::create(MipsMCExpr::MEK_HI, ExprOffset, getContext()));
 3698           MipsMCExpr::create(MipsMCExpr::MEK_LO, ExprOffset, getContext()));
 3698           MipsMCExpr::create(MipsMCExpr::MEK_LO, ExprOffset, getContext()));
 3700           MipsMCExpr::create(MipsMCExpr::MEK_HI, ExprOffset, getContext()));
 3700           MipsMCExpr::create(MipsMCExpr::MEK_HI, ExprOffset, getContext()));
lib/Target/Mips/MCTargetDesc/MipsMCCodeEmitter.cpp
  609     const MipsMCExpr *MipsExpr = cast<MipsMCExpr>(Expr);
  609     const MipsMCExpr *MipsExpr = cast<MipsMCExpr>(Expr);
  613     case MipsMCExpr::MEK_None:
  614     case MipsMCExpr::MEK_Special:
  617     case MipsMCExpr::MEK_DTPREL:
  621     case MipsMCExpr::MEK_CALL_HI16:
  624     case MipsMCExpr::MEK_CALL_LO16:
  627     case MipsMCExpr::MEK_DTPREL_HI:
  631     case MipsMCExpr::MEK_DTPREL_LO:
  635     case MipsMCExpr::MEK_GOTTPREL:
  639     case MipsMCExpr::MEK_GOT:
  643     case MipsMCExpr::MEK_GOT_CALL:
  647     case MipsMCExpr::MEK_GOT_DISP:
  651     case MipsMCExpr::MEK_GOT_HI16:
  654     case MipsMCExpr::MEK_GOT_LO16:
  657     case MipsMCExpr::MEK_GOT_PAGE:
  661     case MipsMCExpr::MEK_GOT_OFST:
  665     case MipsMCExpr::MEK_GPREL:
  668     case MipsMCExpr::MEK_LO:
  677     case MipsMCExpr::MEK_HIGHEST:
  681     case MipsMCExpr::MEK_HIGHER:
  685     case MipsMCExpr::MEK_HI:
  694     case MipsMCExpr::MEK_PCREL_HI16:
  697     case MipsMCExpr::MEK_PCREL_LO16:
  700     case MipsMCExpr::MEK_TLSGD:
  704     case MipsMCExpr::MEK_TLSLDM:
  708     case MipsMCExpr::MEK_TPREL_HI:
  712     case MipsMCExpr::MEK_TPREL_LO:
  716     case MipsMCExpr::MEK_NEG:
lib/Target/Mips/MCTargetDesc/MipsMCExpr.cpp
   27 const MipsMCExpr *MipsMCExpr::create(MipsMCExpr::MipsExprKind Kind,
   27 const MipsMCExpr *MipsMCExpr::create(MipsMCExpr::MipsExprKind Kind,
   29   return new (Ctx) MipsMCExpr(Kind, Expr);
   32 const MipsMCExpr *MipsMCExpr::createGpOff(MipsMCExpr::MipsExprKind Kind,
   32 const MipsMCExpr *MipsMCExpr::createGpOff(MipsMCExpr::MipsExprKind Kind,
  139         cast<MipsMCExpr>(cast<MipsMCExpr>(getSubExpr())->getSubExpr())
  139         cast<MipsMCExpr>(cast<MipsMCExpr>(getSubExpr())->getSubExpr())
  226     fixELFSymbolsInTLSFixupsImpl(cast<MipsMCExpr>(Expr)->getSubExpr(), Asm);
  274     if (const MipsMCExpr *E = dyn_cast<const MipsMCExpr>(getSubExpr()))
  274     if (const MipsMCExpr *E = dyn_cast<const MipsMCExpr>(getSubExpr()))
  292     if (const MipsMCExpr *S1 = dyn_cast<const MipsMCExpr>(getSubExpr())) {
  292     if (const MipsMCExpr *S1 = dyn_cast<const MipsMCExpr>(getSubExpr())) {
  293       if (const MipsMCExpr *S2 = dyn_cast<const MipsMCExpr>(S1->getSubExpr())) {
  293       if (const MipsMCExpr *S2 = dyn_cast<const MipsMCExpr>(S1->getSubExpr())) {
lib/Target/Mips/MCTargetDesc/MipsMCExpr.h
   58   static const MipsMCExpr *create(MipsExprKind Kind, const MCExpr *Expr,
   60   static const MipsMCExpr *createGpOff(MipsExprKind Kind, const MCExpr *Expr,
lib/Target/Mips/MCTargetDesc/MipsTargetStreamer.cpp
 1171   const MCExpr *HiSym = MipsMCExpr::create(
 1172       MipsMCExpr::MEK_HI,
 1184   const MCExpr *LoSym = MipsMCExpr::create(
 1185       MipsMCExpr::MEK_LO,
 1253     const MipsMCExpr *HiExpr = MipsMCExpr::create(
 1253     const MipsMCExpr *HiExpr = MipsMCExpr::create(
 1254         MipsMCExpr::MEK_HI, MCSymbolRefExpr::create(GPSym, MCA.getContext()),
 1256     const MipsMCExpr *LoExpr = MipsMCExpr::create(
 1256     const MipsMCExpr *LoExpr = MipsMCExpr::create(
 1257         MipsMCExpr::MEK_LO, MCSymbolRefExpr::create(GPSym, MCA.getContext()),
 1270   const MipsMCExpr *HiExpr = MipsMCExpr::createGpOff(
 1270   const MipsMCExpr *HiExpr = MipsMCExpr::createGpOff(
 1271       MipsMCExpr::MEK_HI, MCSymbolRefExpr::create(&Sym, MCA.getContext()),
 1273   const MipsMCExpr *LoExpr = MipsMCExpr::createGpOff(
 1273   const MipsMCExpr *LoExpr = MipsMCExpr::createGpOff(
 1274       MipsMCExpr::MEK_LO, MCSymbolRefExpr::create(&Sym, MCA.getContext()),
lib/Target/Mips/MipsAsmPrinter.cpp
 1253   if (auto *MipsExpr = dyn_cast<MipsMCExpr>(Value)) {
 1254     if (MipsExpr && MipsExpr->getKind() == MipsMCExpr::MEK_DTPREL) {
lib/Target/Mips/MipsMCInstLower.cpp
   39   MipsMCExpr::MipsExprKind TargetKind = MipsMCExpr::MEK_None;
   39   MipsMCExpr::MipsExprKind TargetKind = MipsMCExpr::MEK_None;
   49     TargetKind = MipsMCExpr::MEK_GPREL;
   52     TargetKind = MipsMCExpr::MEK_GOT_CALL;
   55     TargetKind = MipsMCExpr::MEK_GOT;
   58     TargetKind = MipsMCExpr::MEK_HI;
   61     TargetKind = MipsMCExpr::MEK_LO;
   64     TargetKind = MipsMCExpr::MEK_TLSGD;
   67     TargetKind = MipsMCExpr::MEK_TLSLDM;
   70     TargetKind = MipsMCExpr::MEK_DTPREL_HI;
   73     TargetKind = MipsMCExpr::MEK_DTPREL_LO;
   76     TargetKind = MipsMCExpr::MEK_GOTTPREL;
   79     TargetKind = MipsMCExpr::MEK_TPREL_HI;
   82     TargetKind = MipsMCExpr::MEK_TPREL_LO;
   85     TargetKind = MipsMCExpr::MEK_HI;
   89     TargetKind = MipsMCExpr::MEK_LO;
   93     TargetKind = MipsMCExpr::MEK_GOT_DISP;
   96     TargetKind = MipsMCExpr::MEK_GOT_HI16;
   99     TargetKind = MipsMCExpr::MEK_GOT_LO16;
  102     TargetKind = MipsMCExpr::MEK_GOT_PAGE;
  105     TargetKind = MipsMCExpr::MEK_GOT_OFST;
  108     TargetKind = MipsMCExpr::MEK_HIGHER;
  111     TargetKind = MipsMCExpr::MEK_HIGHEST;
  114     TargetKind = MipsMCExpr::MEK_CALL_HI16;
  117     TargetKind = MipsMCExpr::MEK_CALL_LO16;
  172     Expr = MipsMCExpr::createGpOff(TargetKind, Expr, *Ctx);
  173   else if (TargetKind != MipsMCExpr::MEK_None)
  174     Expr = MipsMCExpr::create(TargetKind, Expr, *Ctx);
  208                                      MipsMCExpr::MipsExprKind Kind) const {
  213   return MCOperand::createExpr(MipsMCExpr::create(Kind, Sub, *Ctx));
  223   MipsMCExpr::MipsExprKind Kind;
  227     Kind = MipsMCExpr::MEK_HIGHEST;
  230     Kind = MipsMCExpr::MEK_HIGHER;
  233     Kind = MipsMCExpr::MEK_HI;
  236     Kind = MipsMCExpr::MEK_LO;
  245     const MipsMCExpr *MipsExpr = MipsMCExpr::create(Kind, Expr, *Ctx);
  245     const MipsMCExpr *MipsExpr = MipsMCExpr::create(Kind, Expr, *Ctx);
  258   MipsMCExpr::MipsExprKind Kind;
  262     Kind = MipsMCExpr::MEK_HIGHEST;
  265     Kind = MipsMCExpr::MEK_HIGHER;
  268     Kind = MipsMCExpr::MEK_HI;
  271     Kind = MipsMCExpr::MEK_LO;
  287     const MipsMCExpr *MipsExpr = MipsMCExpr::create(Kind, Expr, *Ctx);
  287     const MipsMCExpr *MipsExpr = MipsMCExpr::create(Kind, Expr, *Ctx);
lib/Target/Mips/MipsMCInstLower.h
   44                       MipsMCExpr::MipsExprKind Kind) const;
lib/Target/Mips/MipsTargetObjectFile.cpp
  194   return MipsMCExpr::create(MipsMCExpr::MEK_DTPREL, Expr, getContext());
  194   return MipsMCExpr::create(MipsMCExpr::MEK_DTPREL, Expr, getContext());