• Home
  • Raw
  • Download

Lines Matching refs:AVR

54   const Register SCRATCH_REGISTER = AVR::R0;
56 const Register ZERO_REGISTER = AVR::R1;
211 if (Op == AVR::ANDIRdK && ImmVal == 0xff) in isLogicImmOpRedundant()
215 if (Op == AVR::ORIRdK && ImmVal == 0x0) in isLogicImmOpRedundant()
259 bool AVRExpandPseudo::expand<AVR::ADDWRdRr>(Block &MBB, BlockIt MBBI) { in expand()
260 return expandArith(AVR::ADDRdRr, AVR::ADCRdRr, MBB, MBBI); in expand()
264 bool AVRExpandPseudo::expand<AVR::ADCWRdRr>(Block &MBB, BlockIt MBBI) { in expand()
265 return expandArith(AVR::ADCRdRr, AVR::ADCRdRr, MBB, MBBI); in expand()
269 bool AVRExpandPseudo::expand<AVR::SUBWRdRr>(Block &MBB, BlockIt MBBI) { in expand()
270 return expandArith(AVR::SUBRdRr, AVR::SBCRdRr, MBB, MBBI); in expand()
274 bool AVRExpandPseudo::expand<AVR::SUBIWRdK>(Block &MBB, BlockIt MBBI) { in expand()
283 auto MIBLO = buildMI(MBB, MBBI, AVR::SUBIRdK) in expand()
287 auto MIBHI = buildMI(MBB, MBBI, AVR::SBCIRdK) in expand()
321 bool AVRExpandPseudo::expand<AVR::SBCWRdRr>(Block &MBB, BlockIt MBBI) { in expand()
322 return expandArith(AVR::SBCRdRr, AVR::SBCRdRr, MBB, MBBI); in expand()
326 bool AVRExpandPseudo::expand<AVR::SBCIWRdK>(Block &MBB, BlockIt MBBI) { in expand()
336 unsigned OpLo = AVR::SBCIRdK; in expand()
337 unsigned OpHi = AVR::SBCIRdK; in expand()
364 bool AVRExpandPseudo::expand<AVR::ANDWRdRr>(Block &MBB, BlockIt MBBI) { in expand()
365 return expandLogic(AVR::ANDRdRr, MBB, MBBI); in expand()
369 bool AVRExpandPseudo::expand<AVR::ANDIWRdK>(Block &MBB, BlockIt MBBI) { in expand()
370 return expandLogicImm(AVR::ANDIRdK, MBB, MBBI); in expand()
374 bool AVRExpandPseudo::expand<AVR::ORWRdRr>(Block &MBB, BlockIt MBBI) { in expand()
375 return expandLogic(AVR::ORRdRr, MBB, MBBI); in expand()
379 bool AVRExpandPseudo::expand<AVR::ORIWRdK>(Block &MBB, BlockIt MBBI) { in expand()
380 return expandLogicImm(AVR::ORIRdK, MBB, MBBI); in expand()
384 bool AVRExpandPseudo::expand<AVR::EORWRdRr>(Block &MBB, BlockIt MBBI) { in expand()
385 return expandLogic(AVR::EORRdRr, MBB, MBBI); in expand()
389 bool AVRExpandPseudo::expand<AVR::COMWRd>(Block &MBB, BlockIt MBBI) { in expand()
396 unsigned OpLo = AVR::COMRd; in expand()
397 unsigned OpHi = AVR::COMRd; in expand()
419 bool AVRExpandPseudo::expand<AVR::NEGWRd>(Block &MBB, BlockIt MBBI) { in expand()
430 buildMI(MBB, MBBI, AVR::NEGRd) in expand()
437 buildMI(MBB, MBBI, AVR::NEGRd) in expand()
443 buildMI(MBB, MBBI, AVR::SBCIRdK) in expand()
457 bool AVRExpandPseudo::expand<AVR::CPWRdRr>(Block &MBB, BlockIt MBBI) { in expand()
465 unsigned OpLo = AVR::CPRdRr; in expand()
466 unsigned OpHi = AVR::CPCRdRr; in expand()
490 bool AVRExpandPseudo::expand<AVR::CPCWRdRr>(Block &MBB, BlockIt MBBI) { in expand()
498 unsigned OpLo = AVR::CPCRdRr; in expand()
499 unsigned OpHi = AVR::CPCRdRr; in expand()
525 bool AVRExpandPseudo::expand<AVR::LDIWRdK>(Block &MBB, BlockIt MBBI) { in expand()
530 unsigned OpLo = AVR::LDIRdK; in expand()
531 unsigned OpHi = AVR::LDIRdK; in expand()
574 bool AVRExpandPseudo::expand<AVR::LDSWRdK>(Block &MBB, BlockIt MBBI) { in expand()
579 unsigned OpLo = AVR::LDSRdK; in expand()
580 unsigned OpHi = AVR::LDSRdK; in expand()
618 bool AVRExpandPseudo::expand<AVR::LDWRdPtr>(Block &MBB, BlockIt MBBI) { in expand()
625 unsigned OpLo = AVR::LDRdPtr; in expand()
626 unsigned OpHi = AVR::LDDRdPtrQ; in expand()
643 buildMI(MBB, MBBI, AVR::PUSHRr).addReg(TmpReg); in expand()
653 buildMI(MBB, MBBI, AVR::MOVRdRr).addReg(DstHiReg).addReg(TmpReg); in expand()
656 buildMI(MBB, MBBI, AVR::POPRd).addReg(DstLoReg); in expand()
667 bool AVRExpandPseudo::expand<AVR::LDWRdPtrPi>(Block &MBB, BlockIt MBBI) { in expand()
674 unsigned OpLo = AVR::LDRdPtrPi; in expand()
675 unsigned OpHi = AVR::LDRdPtrPi; in expand()
698 bool AVRExpandPseudo::expand<AVR::LDWRdPtrPd>(Block &MBB, BlockIt MBBI) { in expand()
705 unsigned OpLo = AVR::LDRdPtrPd; in expand()
706 unsigned OpHi = AVR::LDRdPtrPd; in expand()
729 bool AVRExpandPseudo::expand<AVR::LDDWRdPtrQ>(Block &MBB, BlockIt MBBI) { in expand()
737 unsigned OpLo = AVR::LDDRdPtrQ; in expand()
738 unsigned OpHi = AVR::LDDRdPtrQ; in expand()
760 buildMI(MBB, MBBI, AVR::PUSHRr).addReg(TmpReg); in expand()
770 buildMI(MBB, MBBI, AVR::MOVRdRr).addReg(DstHiReg).addReg(TmpReg); in expand()
773 buildMI(MBB, MBBI, AVR::POPRd).addReg(DstLoReg); in expand()
784 bool AVRExpandPseudo::expand<AVR::LPMWRdZ>(Block &MBB, BlockIt MBBI) { in expand()
791 unsigned OpLo = AVR::LPMRdZPi; in expand()
792 unsigned OpHi = AVR::LPMRdZ; in expand()
809 buildMI(MBB, MBBI, AVR::PUSHRr).addReg(TmpReg); in expand()
818 buildMI(MBB, MBBI, AVR::MOVRdRr).addReg(DstHiReg).addReg(TmpReg); in expand()
821 buildMI(MBB, MBBI, AVR::POPRd).addReg(DstLoReg); in expand()
832 bool AVRExpandPseudo::expand<AVR::LPMWRdZPi>(Block &MBB, BlockIt MBBI) { in expand()
842 buildMI(MBB, MBBI, AVR::INRdA) in expandAtomic()
847 buildMI(MBB, MBBI, AVR::BCLRs).addImm(7); // CLI in expandAtomic()
852 buildMI(MBB, MBBI, AVR::OUTARr) in expandAtomic()
889 unsigned LoadOpcode = (Width == 8) ? AVR::LDRdPtr : AVR::LDWRdPtr; in expandAtomicArithmeticOp()
890 unsigned StoreOpcode = (Width == 8) ? AVR::STPtrRr : AVR::STWPtrRr; in expandAtomicArithmeticOp()
912 (*MBB.getParent(), &AVR::GPR8RegClass); in scavengeGPR8()
921 BitVector Available = RS.getRegsAvailable(&AVR::GPR8RegClass); in scavengeGPR8()
930 bool AVRExpandPseudo::expand<AVR::AtomicLoad8>(Block &MBB, BlockIt MBBI) { in expand()
931 return expandAtomicBinaryOp(AVR::LDRdPtr, MBB, MBBI); in expand()
935 bool AVRExpandPseudo::expand<AVR::AtomicLoad16>(Block &MBB, BlockIt MBBI) { in expand()
936 return expandAtomicBinaryOp(AVR::LDWRdPtr, MBB, MBBI); in expand()
940 bool AVRExpandPseudo::expand<AVR::AtomicStore8>(Block &MBB, BlockIt MBBI) { in expand()
941 return expandAtomicBinaryOp(AVR::STPtrRr, MBB, MBBI); in expand()
945 bool AVRExpandPseudo::expand<AVR::AtomicStore16>(Block &MBB, BlockIt MBBI) { in expand()
946 return expandAtomicBinaryOp(AVR::STWPtrRr, MBB, MBBI); in expand()
950 bool AVRExpandPseudo::expand<AVR::AtomicLoadAdd8>(Block &MBB, BlockIt MBBI) { in expand()
951 return expandAtomicArithmeticOp(8, AVR::ADDRdRr, MBB, MBBI); in expand()
955 bool AVRExpandPseudo::expand<AVR::AtomicLoadAdd16>(Block &MBB, BlockIt MBBI) { in expand()
956 return expandAtomicArithmeticOp(16, AVR::ADDWRdRr, MBB, MBBI); in expand()
960 bool AVRExpandPseudo::expand<AVR::AtomicLoadSub8>(Block &MBB, BlockIt MBBI) { in expand()
961 return expandAtomicArithmeticOp(8, AVR::SUBRdRr, MBB, MBBI); in expand()
965 bool AVRExpandPseudo::expand<AVR::AtomicLoadSub16>(Block &MBB, BlockIt MBBI) { in expand()
966 return expandAtomicArithmeticOp(16, AVR::SUBWRdRr, MBB, MBBI); in expand()
970 bool AVRExpandPseudo::expand<AVR::AtomicLoadAnd8>(Block &MBB, BlockIt MBBI) { in expand()
971 return expandAtomicArithmeticOp(8, AVR::ANDRdRr, MBB, MBBI); in expand()
975 bool AVRExpandPseudo::expand<AVR::AtomicLoadAnd16>(Block &MBB, BlockIt MBBI) { in expand()
976 return expandAtomicArithmeticOp(16, AVR::ANDWRdRr, MBB, MBBI); in expand()
980 bool AVRExpandPseudo::expand<AVR::AtomicLoadOr8>(Block &MBB, BlockIt MBBI) { in expand()
981 return expandAtomicArithmeticOp(8, AVR::ORRdRr, MBB, MBBI); in expand()
985 bool AVRExpandPseudo::expand<AVR::AtomicLoadOr16>(Block &MBB, BlockIt MBBI) { in expand()
986 return expandAtomicArithmeticOp(16, AVR::ORWRdRr, MBB, MBBI); in expand()
990 bool AVRExpandPseudo::expand<AVR::AtomicLoadXor8>(Block &MBB, BlockIt MBBI) { in expand()
991 return expandAtomicArithmeticOp(8, AVR::EORRdRr, MBB, MBBI); in expand()
995 bool AVRExpandPseudo::expand<AVR::AtomicLoadXor16>(Block &MBB, BlockIt MBBI) { in expand()
996 return expandAtomicArithmeticOp(16, AVR::EORWRdRr, MBB, MBBI); in expand()
1000 bool AVRExpandPseudo::expand<AVR::AtomicFence>(Block &MBB, BlockIt MBBI) { in expand()
1007 bool AVRExpandPseudo::expand<AVR::STSWKRr>(Block &MBB, BlockIt MBBI) { in expand()
1012 unsigned OpLo = AVR::STSKRr; in expand()
1013 unsigned OpHi = AVR::STSKRr; in expand()
1053 bool AVRExpandPseudo::expand<AVR::STWPtrRr>(Block &MBB, BlockIt MBBI) { in expand()
1059 unsigned OpLo = AVR::STPtrRr; in expand()
1060 unsigned OpHi = AVR::STDPtrQRr; in expand()
1081 bool AVRExpandPseudo::expand<AVR::STWPtrPiRr>(Block &MBB, BlockIt MBBI) { in expand()
1089 unsigned OpLo = AVR::STPtrPiRr; in expand()
1090 unsigned OpHi = AVR::STPtrPiRr; in expand()
1115 bool AVRExpandPseudo::expand<AVR::STWPtrPdRr>(Block &MBB, BlockIt MBBI) { in expand()
1123 unsigned OpLo = AVR::STPtrPdRr; in expand()
1124 unsigned OpHi = AVR::STPtrPdRr; in expand()
1149 bool AVRExpandPseudo::expand<AVR::STDWPtrQRr>(Block &MBB, BlockIt MBBI) { in expand()
1157 unsigned OpLo = AVR::STDPtrQRr; in expand()
1158 unsigned OpHi = AVR::STDPtrQRr; in expand()
1183 bool AVRExpandPseudo::expand<AVR::INWRdA>(Block &MBB, BlockIt MBBI) { in expand()
1189 unsigned OpLo = AVR::INRdA; in expand()
1190 unsigned OpHi = AVR::INRdA; in expand()
1213 bool AVRExpandPseudo::expand<AVR::OUTWARr>(Block &MBB, BlockIt MBBI) { in expand()
1219 unsigned OpLo = AVR::OUTARr; in expand()
1220 unsigned OpHi = AVR::OUTARr; in expand()
1244 bool AVRExpandPseudo::expand<AVR::PUSHWRr>(Block &MBB, BlockIt MBBI) { in expand()
1250 unsigned OpLo = AVR::PUSHRr; in expand()
1251 unsigned OpHi = AVR::PUSHRr; in expand()
1269 bool AVRExpandPseudo::expand<AVR::POPWRd>(Block &MBB, BlockIt MBBI) { in expand()
1274 unsigned OpLo = AVR::POPRd; in expand()
1275 unsigned OpHi = AVR::POPRd; in expand()
1286 bool AVRExpandPseudo::expand<AVR::ROLBRd>(Block &MBB, BlockIt MBBI) { in expand()
1297 OpShift = AVR::ADDRdRr; in expand()
1298 OpCarry = AVR::ADCRdRr; in expand()
1323 bool AVRExpandPseudo::expand<AVR::RORBRd>(Block &MBB, BlockIt MBBI) { in expand()
1334 OpShiftOut = AVR::LSRRd; in expand()
1335 OpLoad = AVR::LDIRdK; in expand()
1336 OpShiftIn = AVR::RORRd; in expand()
1337 OpAdd = AVR::ORRdRr; in expand()
1373 bool AVRExpandPseudo::expand<AVR::LSLWRd>(Block &MBB, BlockIt MBBI) { in expand()
1380 unsigned OpLo = AVR::ADDRdRr; // ADD Rd, Rd <==> LSL Rd in expand()
1381 unsigned OpHi = AVR::ADCRdRr; // ADC Rd, Rd <==> ROL Rd in expand()
1406 bool AVRExpandPseudo::expand<AVR::LSRWRd>(Block &MBB, BlockIt MBBI) { in expand()
1413 unsigned OpLo = AVR::RORRd; in expand()
1414 unsigned OpHi = AVR::LSRRd; in expand()
1437 bool AVRExpandPseudo::expand<AVR::RORWRd>(Block &MBB, BlockIt MBBI) { in expand()
1443 bool AVRExpandPseudo::expand<AVR::ROLWRd>(Block &MBB, BlockIt MBBI) { in expand()
1449 bool AVRExpandPseudo::expand<AVR::ASRWRd>(Block &MBB, BlockIt MBBI) { in expand()
1456 unsigned OpLo = AVR::RORRd; in expand()
1457 unsigned OpHi = AVR::ASRRd; in expand()
1479 template <> bool AVRExpandPseudo::expand<AVR::SEXT>(Block &MBB, BlockIt MBBI) { in expand()
1503 auto MOV = buildMI(MBB, MBBI, AVR::MOVRdRr) in expand()
1513 buildMI(MBB, MBBI, AVR::MOVRdRr) in expand()
1518 buildMI(MBB, MBBI, AVR::ADDRdRr) // LSL Rd <==> ADD Rd, Rr in expand()
1523 auto SBC = buildMI(MBB, MBBI, AVR::SBCRdRr) in expand()
1538 template <> bool AVRExpandPseudo::expand<AVR::ZEXT>(Block &MBB, BlockIt MBBI) { in expand()
1557 buildMI(MBB, MBBI, AVR::MOVRdRr) in expand()
1562 auto EOR = buildMI(MBB, MBBI, AVR::EORRdRr) in expand()
1575 bool AVRExpandPseudo::expand<AVR::SPREAD>(Block &MBB, BlockIt MBBI) { in expand()
1581 unsigned OpLo = AVR::INRdA; in expand()
1582 unsigned OpHi = AVR::INRdA; in expand()
1602 bool AVRExpandPseudo::expand<AVR::SPWRITE>(Block &MBB, BlockIt MBBI) { in expand()
1610 buildMI(MBB, MBBI, AVR::INRdA) in expand()
1611 .addReg(AVR::R0, RegState::Define) in expand()
1615 buildMI(MBB, MBBI, AVR::BCLRs).addImm(0x07).setMIFlags(Flags); in expand()
1617 buildMI(MBB, MBBI, AVR::OUTARr) in expand()
1622 buildMI(MBB, MBBI, AVR::OUTARr) in expand()
1624 .addReg(AVR::R0, RegState::Kill) in expand()
1627 buildMI(MBB, MBBI, AVR::OUTARr) in expand()
1645 EXPAND(AVR::ADDWRdRr); in expandMI()
1646 EXPAND(AVR::ADCWRdRr); in expandMI()
1647 EXPAND(AVR::SUBWRdRr); in expandMI()
1648 EXPAND(AVR::SUBIWRdK); in expandMI()
1649 EXPAND(AVR::SBCWRdRr); in expandMI()
1650 EXPAND(AVR::SBCIWRdK); in expandMI()
1651 EXPAND(AVR::ANDWRdRr); in expandMI()
1652 EXPAND(AVR::ANDIWRdK); in expandMI()
1653 EXPAND(AVR::ORWRdRr); in expandMI()
1654 EXPAND(AVR::ORIWRdK); in expandMI()
1655 EXPAND(AVR::EORWRdRr); in expandMI()
1656 EXPAND(AVR::COMWRd); in expandMI()
1657 EXPAND(AVR::NEGWRd); in expandMI()
1658 EXPAND(AVR::CPWRdRr); in expandMI()
1659 EXPAND(AVR::CPCWRdRr); in expandMI()
1660 EXPAND(AVR::LDIWRdK); in expandMI()
1661 EXPAND(AVR::LDSWRdK); in expandMI()
1662 EXPAND(AVR::LDWRdPtr); in expandMI()
1663 EXPAND(AVR::LDWRdPtrPi); in expandMI()
1664 EXPAND(AVR::LDWRdPtrPd); in expandMI()
1665 case AVR::LDDWRdYQ: //:FIXME: remove this once PR13375 gets fixed in expandMI()
1666 EXPAND(AVR::LDDWRdPtrQ); in expandMI()
1667 EXPAND(AVR::LPMWRdZ); in expandMI()
1668 EXPAND(AVR::LPMWRdZPi); in expandMI()
1669 EXPAND(AVR::AtomicLoad8); in expandMI()
1670 EXPAND(AVR::AtomicLoad16); in expandMI()
1671 EXPAND(AVR::AtomicStore8); in expandMI()
1672 EXPAND(AVR::AtomicStore16); in expandMI()
1673 EXPAND(AVR::AtomicLoadAdd8); in expandMI()
1674 EXPAND(AVR::AtomicLoadAdd16); in expandMI()
1675 EXPAND(AVR::AtomicLoadSub8); in expandMI()
1676 EXPAND(AVR::AtomicLoadSub16); in expandMI()
1677 EXPAND(AVR::AtomicLoadAnd8); in expandMI()
1678 EXPAND(AVR::AtomicLoadAnd16); in expandMI()
1679 EXPAND(AVR::AtomicLoadOr8); in expandMI()
1680 EXPAND(AVR::AtomicLoadOr16); in expandMI()
1681 EXPAND(AVR::AtomicLoadXor8); in expandMI()
1682 EXPAND(AVR::AtomicLoadXor16); in expandMI()
1683 EXPAND(AVR::AtomicFence); in expandMI()
1684 EXPAND(AVR::STSWKRr); in expandMI()
1685 EXPAND(AVR::STWPtrRr); in expandMI()
1686 EXPAND(AVR::STWPtrPiRr); in expandMI()
1687 EXPAND(AVR::STWPtrPdRr); in expandMI()
1688 EXPAND(AVR::STDWPtrQRr); in expandMI()
1689 EXPAND(AVR::INWRdA); in expandMI()
1690 EXPAND(AVR::OUTWARr); in expandMI()
1691 EXPAND(AVR::PUSHWRr); in expandMI()
1692 EXPAND(AVR::POPWRd); in expandMI()
1693 EXPAND(AVR::ROLBRd); in expandMI()
1694 EXPAND(AVR::RORBRd); in expandMI()
1695 EXPAND(AVR::LSLWRd); in expandMI()
1696 EXPAND(AVR::LSRWRd); in expandMI()
1697 EXPAND(AVR::RORWRd); in expandMI()
1698 EXPAND(AVR::ROLWRd); in expandMI()
1699 EXPAND(AVR::ASRWRd); in expandMI()
1700 EXPAND(AVR::SEXT); in expandMI()
1701 EXPAND(AVR::ZEXT); in expandMI()
1702 EXPAND(AVR::SPREAD); in expandMI()
1703 EXPAND(AVR::SPWRITE); in expandMI()