Lines Matching refs:AVR
1 //===-- AVRISelDAGToDAG.cpp - A dag to dag inst selector for AVR ----------===//
9 // This file defines an instruction selector for the AVR target.
13 #include "AVR.h"
22 #define DEBUG_TYPE "avr-isel"
26 /// Lowers LLVM IR (in DAG form) to AVR MC instructions (in DAG form).
33 return "AVR DAG->DAG Instruction Selection";
144 Opcode = (isPre) ? AVR::LDRdPtrPd : AVR::LDRdPtrPi;
152 Opcode = (isPre) ? AVR::LDWRdPtrPd : AVR::LDWRdPtrPi;
185 Opcode = AVR::LPMRdZPi;
192 Opcode = AVR::LPMWRdZPi;
219 RI.getRegClass(RegNode->getReg()) == &AVR::PTRDISPREGSRegClass) {
252 AVR::PTRDISPREGSRegClass.contains(Reg));
262 if (RI.getRegClass(Reg) != &AVR::PTRDISPREGSRegClass) {
265 Register VReg = RI.createVirtualRegister(&AVR::PTRDISPREGSRegClass);
294 Register VReg = RI.createVirtualRegister(&AVR::PTRDISPREGSRegClass);
314 CurDAG->SelectNodeTo(N, AVR::FRMIDX,
334 if (!RN || (RN->getReg() != AVR::SP)) {
344 unsigned Opc = (VT == MVT::i16) ? AVR::STDWSPQRr : AVR::STDSPQRr;
359 if (!AVR::isProgramMemoryAccess(LD)) {
374 Chain = CurDAG->getCopyToReg(Chain, DL, AVR::R31R30, Ptr, SDValue());
375 Ptr = CurDAG->getCopyFromReg(Chain, DL, AVR::R31R30, MVT::i16,
378 SDValue RegZ = CurDAG->getRegister(AVR::R31R30, MVT::i16);
390 ResNode = CurDAG->getMachineNode(AVR::LPMRdZ, DL, MVT::i8, MVT::Other,
394 ResNode = CurDAG->getMachineNode(AVR::LPMWRdZ, DL, MVT::i16,
431 Chain = CurDAG->getCopyToReg(Chain, DL, AVR::R31R30, Callee, InFlag);
433 Ops.push_back(CurDAG->getRegister(AVR::R31R30, MVT::i16));
444 CurDAG->getMachineNode(AVR::ICALL, DL, MVT::Other, MVT::Glue, Ops);
459 Chain = CurDAG->getCopyToReg(Chain, DL, AVR::R31R30, JmpAddr);
460 SDNode *ResNode = CurDAG->getMachineNode(AVR::IJMP, DL, MVT::Other, Chain);
475 unsigned MachineOp = isSigned ? AVR::MULSRdRr : AVR::MULRdRr;
486 CurDAG->getCopyFromReg(InChain, DL, AVR::R0, Type, InGlue);
497 CurDAG->getCopyFromReg(InChain, DL, AVR::R1, Type, InGlue);