Lines Matching refs:AVR
63 BuildMI(MBB, MBBI, DL, TII.get(AVR::BSETs)) in emitPrologue()
71 BuildMI(MBB, MBBI, DL, TII.get(AVR::PUSHWRr)) in emitPrologue()
72 .addReg(AVR::R1R0, RegState::Kill) in emitPrologue()
75 BuildMI(MBB, MBBI, DL, TII.get(AVR::INRdA), AVR::R0) in emitPrologue()
78 BuildMI(MBB, MBBI, DL, TII.get(AVR::PUSHRr)) in emitPrologue()
79 .addReg(AVR::R0, RegState::Kill) in emitPrologue()
81 BuildMI(MBB, MBBI, DL, TII.get(AVR::EORRdRr)) in emitPrologue()
82 .addReg(AVR::R0, RegState::Define) in emitPrologue()
83 .addReg(AVR::R0, RegState::Kill) in emitPrologue()
84 .addReg(AVR::R0, RegState::Kill) in emitPrologue()
99 (MBBI->getOpcode() == AVR::PUSHRr || MBBI->getOpcode() == AVR::PUSHWRr)) { in emitPrologue()
104 BuildMI(MBB, MBBI, DL, TII.get(AVR::SPREAD), AVR::R29R28) in emitPrologue()
105 .addReg(AVR::SP) in emitPrologue()
111 I->addLiveIn(AVR::R29R28); in emitPrologue()
119 unsigned Opcode = (isUInt<6>(FrameSize)) ? AVR::SBIWRdK : AVR::SUBIWRdK; in emitPrologue()
121 MachineInstr *MI = BuildMI(MBB, MBBI, DL, TII.get(Opcode), AVR::R29R28) in emitPrologue()
122 .addReg(AVR::R29R28, RegState::Kill) in emitPrologue()
129 BuildMI(MBB, MBBI, DL, TII.get(AVR::SPWRITE), AVR::SP) in emitPrologue()
130 .addReg(AVR::R29R28) in emitPrologue()
146 BuildMI(MBB, MBBI, DL, TII.get(AVR::POPRd), AVR::R0); in restoreStatusRegister()
147 BuildMI(MBB, MBBI, DL, TII.get(AVR::OUTARr)) in restoreStatusRegister()
149 .addReg(AVR::R0, RegState::Kill); in restoreStatusRegister()
150 BuildMI(MBB, MBBI, DL, TII.get(AVR::POPWRd), AVR::R1R0); in restoreStatusRegister()
185 if (Opc != AVR::POPRd && Opc != AVR::POPWRd && !PI->isTerminator()) { in emitEpilogue()
196 Opcode = AVR::ADIWRdK; in emitEpilogue()
198 Opcode = AVR::SUBIWRdK; in emitEpilogue()
203 MachineInstr *MI = BuildMI(MBB, MBBI, DL, TII.get(Opcode), AVR::R29R28) in emitEpilogue()
204 .addReg(AVR::R29R28, RegState::Kill) in emitEpilogue()
210 BuildMI(MBB, MBBI, DL, TII.get(AVR::SPWRITE), AVR::SP) in emitEpilogue()
211 .addReg(AVR::R29R28, RegState::Kill); in emitEpilogue()
261 BuildMI(MBB, MI, DL, TII.get(AVR::PUSHRr)) in spillCalleeSavedRegisters()
290 BuildMI(MBB, MI, DL, TII.get(AVR::POPRd), Reg); in restoreCalleeSavedRegisters()
308 if (Opcode != AVR::STDSPQRr && Opcode != AVR::STDWSPQRr) { in fixStackStores()
313 assert(MI.getOperand(0).getReg() == AVR::SP && in fixStackStores()
319 (Opcode == AVR::STDWSPQRr) ? AVR::STDWPtrQRr : AVR::STDPtrQRr; in fixStackStores()
338 fixStackStores(MBB, MI, TII, AVR::R29R28); in eliminateCallFramePseudoInstr()
357 BuildMI(MBB, MI, DL, TII.get(AVR::SPREAD), AVR::R31R30).addReg(AVR::SP); in eliminateCallFramePseudoInstr()
359 MachineInstr *New = BuildMI(MBB, MI, DL, TII.get(AVR::SUBIWRdK), AVR::R31R30) in eliminateCallFramePseudoInstr()
360 .addReg(AVR::R31R30, RegState::Kill) in eliminateCallFramePseudoInstr()
364 BuildMI(MBB, MI, DL, TII.get(AVR::SPWRITE), AVR::SP) in eliminateCallFramePseudoInstr()
365 .addReg(AVR::R31R30, RegState::Kill); in eliminateCallFramePseudoInstr()
369 fixStackStores(MBB, MI, TII, AVR::R31R30); in eliminateCallFramePseudoInstr()
380 addOpcode = AVR::ADIWRdK; in eliminateCallFramePseudoInstr()
382 addOpcode = AVR::SUBIWRdK; in eliminateCallFramePseudoInstr()
387 BuildMI(MBB, MI, DL, TII.get(AVR::SPREAD), AVR::R31R30).addReg(AVR::SP); in eliminateCallFramePseudoInstr()
389 MachineInstr *New = BuildMI(MBB, MI, DL, TII.get(addOpcode), AVR::R31R30) in eliminateCallFramePseudoInstr()
390 .addReg(AVR::R31R30, RegState::Kill) in eliminateCallFramePseudoInstr()
394 BuildMI(MBB, MI, DL, TII.get(AVR::SPWRITE), AVR::SP) in eliminateCallFramePseudoInstr()
395 .addReg(AVR::R31R30, RegState::Kill); in eliminateCallFramePseudoInstr()
409 SavedRegs.set(AVR::R29); in determineCalleeSaves()
410 SavedRegs.set(AVR::R28); in determineCalleeSaves()
452 if ((Opcode != AVR::LDDRdPtrQ) && (Opcode != AVR::LDDWRdPtrQ) && in runOnMachineFunction()
453 (Opcode != AVR::STDPtrQRr) && (Opcode != AVR::STDWPtrQRr)) { in runOnMachineFunction()
502 MF.getRegInfo().createVirtualRegister(&AVR::DREGSRegClass); in runOnMachineFunction()
506 BuildMI(EntryMBB, MBBI, DL, TII.get(AVR::COPY), SPCopy).addReg(AVR::SP); in runOnMachineFunction()
514 BuildMI(MBB, MBBI, DL, TII.get(AVR::COPY), AVR::SP) in runOnMachineFunction()