<s> void LLVMInitializeCell<ISA_LIT>TargetInfo ( ) { RegisterTarget < Triple :: cellspu > X ( TheCell<ISA_LIT>Target , <STR_LIT> , <STR_LIT> ) ;


<s> inline bool isU10Constant ( uint64_t Value ) {

return ( Value == ( Value & <NUM_LIT> ) ) ;


<s> inline bool isU10Constant ( uint64_t Value ) { return ( Value == ( Value & <NUM_LIT> ) ) ;


<s> FunctionPass * llvm :: create<ISA_LIT>AsmPrinterPass ( raw_ostream & o , <ISA_LIT>TargetMachine & tm , bool fast ) {

return new LinuxAsmPrinter ( o , tm , tm . getTargetAsmInfo ( ) , fast ) ;


<s> I != E ; ++ I ) printModuleLevelGV ( I ) ; DW -> EndModule ( ) ;

return AsmPrinter :: doFinalization ( M ) ;


<s> for ( Module :: const_global_iterator I = M . global_begin ( ) , E = M . global_end ( ) ;

I != E ; ++ I ) printModuleLevelGV ( I ) ;


<s> SwitchToTextSection ( <STR_LIT> ) ; DW = getAnalysisIfAvailable < DwarfWriter > ( ) ; assert ( DW && <STR_LIT> ) ; MMI = getAnalysisIfAvailable < MachineModuleInfo > ( ) ; DW -> BeginModule ( & M , MMI , O , this , TAI ) ; return Result ;


<s> if ( ! GVar -> hasInitializer ( ) ) return ; if ( EmitSpecialLLVMGlobal ( GVar ) ) return ; std :: string name = Mang -> getValueName ( GVar ) ; printVisibility ( name , GVar -> getVisibility ( ) ) ; Constant * C = GVar -> getInitializer ( ) ; const Type * Type = C -> getType ( ) ; unsigned Size = TD -> getTypePaddedSize ( Type ) ; unsigned Align = TD -> getPreferredAlignmentLog ( GVar ) ; SwitchToSection ( TAI -> SectionForGlobal ( GVar ) ) ; if ( C -> isNullValue ( ) && ! GVar -> hasSection ( ) && ( GVar -> hasLocalLinkage ( ) || GVar -> hasExternalLinkage ( ) || GVar -> isWeakForLinker ( ) ) ) { if ( Size == <NUM_LIT> ) Size = <NUM_LIT> ; if ( GVar -> hasExternalLinkage ( ) ) { O << <STR_LIT> << name << '\n' ; O << <STR_LIT> << name << <STR_LIT> ; O << name << <STR_LIT> ; O << <STR_LIT> << Size << '\n' ; } else if ( GVar -> hasLocalLinkage ( ) ) { O << TAI -> getLCOMMDirective ( ) << name << ',' << Size ; } else { O << <STR_LIT> << name << ',' << Size ; } O << <STR_LIT> << TAI -> getCommentString ( ) << <STR_LIT> ; PrintUnmangledNameSafely ( GVar , O ) ; O << <STR_LIT> ; return ; } switch ( GVar -> getLinkage ( ) ) { case GlobalValue :: LinkOnceAnyLinkage : case GlobalValue :: LinkOnceODRLinkage : case GlobalValue :: WeakAnyLinkage : case GlobalValue :: WeakODRLinkage : case GlobalValue :: CommonLinkage : O << <STR_LIT> << name << '\n' << <STR_LIT> << name << <STR_LIT> << <STR_LIT> << name << '\n' ; break ; case GlobalValue :: AppendingLinkage : case GlobalValue :: ExternalLinkage : O << <STR_LIT> << name << '\n' << <STR_LIT> << name << <STR_LIT> ; case GlobalValue :: PrivateLinkage : case GlobalValue :: InternalLinkage : break ; default : cerr << <STR_LIT> ;


<s> Constant * C = GVar -> getInitializer ( ) ; const Type * Type = C -> getType ( ) ; unsigned Size = TD -> getTypePaddedSize ( Type ) ; unsigned Align = TD -> getPreferredAlignmentLog ( GVar ) ; SwitchToSection ( TAI -> SectionForGlobal ( GVar ) ) ; if ( C -> isNullValue ( ) && ! GVar -> hasSection ( ) && ( GVar -> hasLocalLinkage ( ) || GVar -> hasExternalLinkage ( ) || GVar -> isWeakForLinker ( ) ) ) { if ( Size == <NUM_LIT> ) Size = <NUM_LIT> ; if ( GVar -> hasExternalLinkage ( ) ) { O << <STR_LIT> << name << '\n' ; O << <STR_LIT> << name << <STR_LIT> ; O << name << <STR_LIT> ; O << <STR_LIT> << Size << '\n' ; } else if ( GVar -> hasLocalLinkage ( ) ) { O << TAI -> getLCOMMDirective ( ) << name << ',' << Size ; } else { O << <STR_LIT> << name << ',' << Size ; } O << <STR_LIT> << TAI -> getCommentString ( ) << <STR_LIT> ; PrintUnmangledNameSafely ( GVar , O ) ; O << <STR_LIT> ; return ; } switch ( GVar -> getLinkage ( ) ) { case GlobalValue :: LinkOnceAnyLinkage : case GlobalValue :: LinkOnceODRLinkage : case GlobalValue :: WeakAnyLinkage : case GlobalValue :: WeakODRLinkage : case GlobalValue :: CommonLinkage : O << <STR_LIT> << name << '\n' << <STR_LIT> << name << <STR_LIT> << <STR_LIT> << name << '\n' ; break ; case GlobalValue :: AppendingLinkage : case GlobalValue :: ExternalLinkage : O << <STR_LIT> << name << '\n' << <STR_LIT> << name << <STR_LIT> ; case GlobalValue :: PrivateLinkage : case GlobalValue :: InternalLinkage : break ;


<s> O << <STR_LIT> << Name << <STR_LIT> ; return ; } O << TAI -> getGlobalPrefix ( ) << MO . getSymbolName ( ) ; return ; case MachineOperand :: MO_GlobalAddress : { GlobalValue * GV = MO . getGlobal ( ) ; std :: string Name = Mang -> getValueName ( GV ) ; if ( TM . getRelocationModel ( ) != Reloc :: Static ) {

if ( ( ( GV -> isDeclaration ( ) || GV -> hasWeakLinkage ( ) || GV -> hasLinkOnceLinkage ( ) || GV -> hasCommonLinkage ( ) ) ) ) {


<s> if ( MI -> getOperand ( OpNo ) . isImm ( ) ) { int value = ( int ) MI -> getOperand ( OpNo ) . getImm ( ) ; assert ( ( value >= <NUM_LIT> && value < <NUM_LIT> ) && <STR_LIT> ) ; O << - value ;


<s> assert ( ( value >= <NUM_LIT> && value <= <NUM_LIT> ) && <STR_LIT> ) ; O << - value ; } else { assert ( <NUM_LIT> && <STR_LIT> ) ;


<s> static void PrintUnmangledNameSafely ( const Value * V , raw_ostream & OS ) { for ( const char * Name = V -> getNameStart ( ) , * E = Name + V -> getNameLen ( ) ;

Name != E ; ++ Name ) if ( isprint ( * Name ) ) OS << * Name ;


<s> Name != E ; ++ Name ) if ( isprint ( * Name ) ) OS << * Name ;


<s> switch ( F -> getLinkage ( ) ) { default : assert ( <NUM_LIT> && <STR_LIT> ) ; case Function :: PrivateLinkage : case Function :: InternalLinkage : break ; case Function :: ExternalLinkage : O << <STR_LIT> << CurrentFnName << <STR_LIT> << <STR_LIT> << CurrentFnName << <STR_LIT> ; break ; case Function :: WeakAnyLinkage : case Function :: WeakODRLinkage : case Function :: LinkOnceAnyLinkage : case Function :: LinkOnceODRLinkage : O << <STR_LIT> << CurrentFnName << <STR_LIT> ; O << <STR_LIT> << CurrentFnName << <STR_LIT> ;


<s> default : assert ( <NUM_LIT> && <STR_LIT> ) ; case Function :: PrivateLinkage : case Function :: InternalLinkage : break ; case Function :: ExternalLinkage : O << <STR_LIT> << CurrentFnName << <STR_LIT> << <STR_LIT> << CurrentFnName << <STR_LIT> ; break ; case Function :: WeakAnyLinkage : case Function :: WeakODRLinkage : case Function :: LinkOnceAnyLinkage : case Function :: LinkOnceODRLinkage : O << <STR_LIT> << CurrentFnName << <STR_LIT> ; O << <STR_LIT> << CurrentFnName << <STR_LIT> ; break ; } O << CurrentFnName << <STR_LIT> ; DW -> BeginFunction ( & MF ) ; for ( MachineFunction :: const_iterator I = MF . begin ( ) , E = MF . end ( ) ; I != E ; ++ I ) { if ( I != MF . begin ( ) ) { printBasicBlockLabel ( I , true , true ) ; O << '\n' ; } for ( MachineBasicBlock :: const_iterator II = I -> begin ( ) , E = I -> end ( ) ; II != E ; ++ II ) { printMachineInstruction ( II ) ; } } O << <STR_LIT> << CurrentFnName << <STR_LIT> << CurrentFnName << <STR_LIT> ; EmitJumpTableInfo ( MF . getJumpTableInfo ( ) , MF ) ; DW -> EndFunction ( & MF ) ; return false ;


<s> case MachineOperand :: MO_JumpTableIndex : O << MAI -> getPrivateGlobalPrefix ( ) << <STR_LIT> << getFunctionNumber ( ) << '_' << MO . getIndex ( ) ; return ; case MachineOperand :: MO_ConstantPoolIndex : O << MAI -> getPrivateGlobalPrefix ( ) << <STR_LIT> << getFunctionNumber ( ) << '_' << MO . getIndex ( ) ; return ; case MachineOperand :: MO_ExternalSymbol : if ( TM . getRelocationModel ( ) != Reloc :: Static ) { O << <STR_LIT> << MAI -> getGlobalPrefix ( ) << MO . getSymbolName ( ) << <STR_LIT> ; return ; } O << * GetExternalSymbolSymbol ( MO . getSymbolName ( ) ) ; return ; case MachineOperand :: MO_GlobalAddress :


<s> case MachineOperand :: MO_JumpTableIndex : O << MAI -> getPrivateGlobalPrefix ( ) << <STR_LIT> << getFunctionNumber ( ) << '_' << MO . getIndex ( ) ; return ; case MachineOperand :: MO_ConstantPoolIndex : O << MAI -> getPrivateGlobalPrefix ( ) << <STR_LIT> << getFunctionNumber ( ) << '_' << MO . getIndex ( ) ; return ; case MachineOperand :: MO_ExternalSymbol : if ( TM . getRelocationModel ( ) != Reloc :: Static ) { O << <STR_LIT> << MAI -> getGlobalPrefix ( ) << MO . getSymbolName ( ) << <STR_LIT> ; return ; } O << * GetExternalSymbolSymbol ( MO . getSymbolName ( ) ) ; return ; case MachineOperand :: MO_GlobalAddress : if ( TM . getRelocationModel ( ) != Reloc :: Static ) { const GlobalValue * GV = MO . getGlobal ( ) ; if ( ( ( GV -> isDeclaration ( ) || GV -> hasWeakLinkage ( ) || GV -> hasLinkOnceLinkage ( ) || GV -> hasCommonLinkage ( ) ) ) ) { O << * GetSymbolWithGlobalValueBase ( GV , <STR_LIT> ) ; return ; } } O << * Mang -> getSymbol ( MO . getGlobal ( ) ) ; return ; case MachineOperand :: MO_MCSymbol : O << * ( MO . getMCSymbol ( ) ) ; return ; default : O << <STR_LIT> << MO . getType ( ) << <STR_LIT> ; return ;


<s> O << getRegisterName ( MO . getReg ( ) ) << <STR_LIT> ; printOperand ( MI , OpNo + <NUM_LIT> ) ;


<s> O << * GetExternalSymbolSymbol ( MO . getSymbolName ( ) ) ; return ; case MachineOperand :: MO_GlobalAddress : if ( TM . getRelocationModel ( ) != Reloc :: Static ) { GlobalValue * GV = MO . getGlobal ( ) ; if ( ( ( GV -> isDeclaration ( ) || GV -> hasWeakLinkage ( ) || GV -> hasLinkOnceLinkage ( ) || GV -> hasCommonLinkage ( ) ) ) ) {

O << * GetSymbolWithGlobalValueBase ( GV , <STR_LIT> ) ;


<s> void printOperand ( const MachineInstr * MI , unsigned OpNo ) { const MachineOperand & MO = MI -> getOperand ( OpNo ) ; if ( MO . isReg ( ) ) {

O << getRegisterName ( MO . getReg ( ) ) ;


<s> void printRegister ( const MachineOperand & MO , bool R0AsZero ) { unsigned RegNo = MO . getReg ( ) ; assert ( TargetRegisterInfo :: isPhysicalRegister ( RegNo ) && <STR_LIT> ) ;


<s> DW = getAnalysisIfAvailable < DwarfWriter > ( ) ;


<s> AU . setPreservesAll ( ) ; AU . addRequired < MachineModuleInfo > ( ) ; AU . addRequired < DwarfWriter > ( ) ; <ISA_LIT>AsmPrinter :: getAnalysisUsage ( AU ) ;


<s> AU . addRequired < MachineModuleInfo > ( ) ;


<s> <ISA_LIT>TargetMachine & getTM ( ) {

return static_cast < <ISA_LIT>TargetMachine & > ( TM ) ;


<s> RegisterAsmPrinter < LinuxAsmPrinter > X ( TheCell<ISA_LIT>Target ) ;


<s> void printAddr256K ( const MachineInstr * MI , unsigned OpNo ) { if ( MI -> getOperand ( OpNo ) . isImm ( ) ) { printS16ImmOperand ( MI , OpNo ) ; } else { printOp ( MI -> getOperand ( OpNo ) ) ; if ( MI -> getOperand ( OpNo + <NUM_LIT> ) . isImm ( ) ) {

int displ = int ( MI -> getOperand ( OpNo + <NUM_LIT> ) . getImm ( ) ) ;


<s> if ( ExtraCode && ExtraCode [ <NUM_LIT> ] ) return true ; printMemRegReg ( MI , OpNo ) ;


<s> bool <ISA_LIT>AsmPrinter :: PrintAsmMemoryOperand ( const MachineInstr * MI , unsigned OpNo , unsigned AsmVariant , const char * ExtraCode ) { if ( ExtraCode && ExtraCode [ <NUM_LIT> ] ) return true ;


if ( ! MI -> getOperand ( OpNo ) . isReg ( ) || OpNo + <NUM_LIT> == MI -> getNumOperands ( ) || ! MI -> getOperand ( OpNo + <NUM_LIT> ) . isReg ( ) ) return true ;


<s> void printCallOperand ( const MachineInstr * MI , unsigned OpNo ) { printOp ( MI -> getOperand ( OpNo ) ) ;


<s> printOp ( MI -> getOperand ( OpNo ) ) ;


<s> assert ( MI -> getOperand ( OpNo ) . isImm ( ) && <STR_LIT> ) ; int64_t value = int64_t ( MI -> getOperand ( OpNo ) . getImm ( ) ) ; int16_t value16 = int16_t ( value ) ; assert ( ( value16 >= - ( <NUM_LIT> << ( <NUM_LIT> + <NUM_LIT> ) ) && value16 <= ( <NUM_LIT> << ( <NUM_LIT> + <NUM_LIT> ) ) - <NUM_LIT> ) && <STR_LIT> ) ; O << ( value16 & ~ <NUM_LIT> ) << <STR_LIT> ;

printOperand ( MI , OpNo + <NUM_LIT> ) ;


<s> if ( GVar -> hasExternalLinkage ( ) ) { O << <STR_LIT> << name << '\n' ; O << <STR_LIT> << name << <STR_LIT> ; O << name << <STR_LIT> ; O << <STR_LIT> << Size << '\n' ; } else if ( GVar -> hasLocalLinkage ( ) ) { O << TAI -> getLCOMMDirective ( ) << name << ',' << Size ; } else { O << <STR_LIT> << name << ',' << Size ; } O << <STR_LIT> << TAI -> getCommentString ( ) << <STR_LIT> ; WriteAsOperand ( O , GVar , false , GVar -> getParent ( ) ) ; O << <STR_LIT> ; return ; } switch ( GVar -> getLinkage ( ) ) { case GlobalValue :: LinkOnceAnyLinkage : case GlobalValue :: LinkOnceODRLinkage : case GlobalValue :: WeakAnyLinkage : case GlobalValue :: WeakODRLinkage :


<s> std :: string name = Mang -> getMangledName ( GVar ) ; printVisibility ( name , GVar -> getVisibility ( ) ) ; Constant * C = GVar -> getInitializer ( ) ; const Type * Type = C -> getType ( ) ; unsigned Size = TD -> getTypeAllocSize ( Type ) ; unsigned Align = TD -> getPreferredAlignmentLog ( GVar ) ; OutStreamer . SwitchSection ( getObjFileLowering ( ) . SectionForGlobal ( GVar , Mang , TM ) ) ; if ( C -> isNullValue ( ) && ! GVar -> hasSection ( ) && ( GVar -> hasLocalLinkage ( ) || GVar -> hasExternalLinkage ( ) || GVar -> isWeakForLinker ( ) ) ) { if ( Size == <NUM_LIT> ) Size = <NUM_LIT> ; if ( GVar -> hasExternalLinkage ( ) ) { O << <STR_LIT> << name << '\n' ; O << <STR_LIT> << name << <STR_LIT> ; O << name << <STR_LIT> ; O << <STR_LIT> << Size << '\n' ; } else if ( GVar -> hasLocalLinkage ( ) ) { O << TAI -> getLCOMMDirective ( ) << name << ',' << Size ; } else { O << <STR_LIT> << name << ',' << Size ; } O << <STR_LIT> << TAI -> getCommentString ( ) << <STR_LIT> ; WriteAsOperand ( O , GVar , false , GVar -> getParent ( ) ) ; O << <STR_LIT> ; return ; } switch ( GVar -> getLinkage ( ) ) { case GlobalValue :: LinkOnceAnyLinkage : case GlobalValue :: LinkOnceODRLinkage : case GlobalValue :: WeakAnyLinkage : case GlobalValue :: WeakODRLinkage : case GlobalValue :: CommonLinkage : O << <STR_LIT> << name << '\n' << <STR_LIT> << name << <STR_LIT> << <STR_LIT> << name << '\n' ; break ; case GlobalValue :: AppendingLinkage : case GlobalValue :: ExternalLinkage : O << <STR_LIT> << name << '\n' << <STR_LIT> << name << <STR_LIT> ; case GlobalValue :: PrivateLinkage : case GlobalValue :: LinkerPrivateLinkage : case GlobalValue :: InternalLinkage : break ; default : llvm_report_error ( <STR_LIT> ) ; } EmitAlignment ( Align , GVar ) ;

O << name << <STR_LIT> << TAI -> getCommentString ( ) << <STR_LIT> ;


<s> void printHBROperand ( const MachineInstr * MI , unsigned OpNo ) { O << <STR_LIT> ;


<s> ++ EmittedInsts ; printInstruction ( MI ) ;


<s> void printMemRegReg ( const MachineInstr * MI , unsigned OpNo ) { const MachineOperand & MO = MI -> getOperand ( OpNo ) ; O << TM . getRegisterInfo ( ) -> get ( MO . getReg ( ) ) . AsmName ; O << <STR_LIT> ;


<s> O << TM . getRegisterInfo ( ) -> get ( MO . getReg ( ) ) . AsmName ; O << <STR_LIT> ;


<s> case MachineOperand :: MO_Immediate : llvm_report_error ( <STR_LIT> ) ; return ; case MachineOperand :: MO_MachineBasicBlock : printBasicBlockLabel ( MO . getMBB ( ) ) ; return ; case MachineOperand :: MO_JumpTableIndex : O << TAI -> getPrivateGlobalPrefix ( ) << <STR_LIT> << getFunctionNumber ( ) << '_' << MO . getIndex ( ) ; return ; case MachineOperand :: MO_ConstantPoolIndex : O << TAI -> getPrivateGlobalPrefix ( ) << <STR_LIT> << getFunctionNumber ( ) << '_' << MO . getIndex ( ) ; return ; case MachineOperand :: MO_ExternalSymbol : if ( TM . getRelocationModel ( ) != Reloc :: Static ) { std :: string Name ( TAI -> getGlobalPrefix ( ) ) ; Name += MO . getSymbolName ( ) ; GVStubs . insert ( Name ) ; O << <STR_LIT> << Name << <STR_LIT> ; return ; } O << TAI -> getGlobalPrefix ( ) << MO . getSymbolName ( ) ; return ;

case MachineOperand :: MO_GlobalAddress : {


<s> O << TM . getRegisterInfo ( ) -> get ( MO . getReg ( ) ) . AsmName ; } else if ( MO . isImm ( ) ) { O << MO . getImm ( ) ; } else { printOp ( MO ) ;


<s> assert ( TargetRegisterInfo :: isPhysicalRegister ( MO . getReg ( ) ) && <STR_LIT> ) ; O << TM . getRegisterInfo ( ) -> get ( MO . getReg ( ) ) . AsmName ; } else if ( MO . isImm ( ) ) { O << MO . getImm ( ) ;


<s> void printPCRelativeOperand ( const MachineInstr * MI , unsigned OpNo ) { printOp ( MI -> getOperand ( OpNo ) ) ;


<s> void printPCRelativeOperand ( const MachineInstr * MI , unsigned OpNo ) {


<s> int value = ( int ) MI -> getOperand ( OpNo ) . getImm ( ) ; assert ( ( value >= <NUM_LIT> && value < <NUM_LIT> ) && <STR_LIT> ) ; O << - value ;


<s> int value = ( int ) MI -> getOperand ( OpNo ) . getImm ( ) ; assert ( ( value >= <NUM_LIT> && value <= <NUM_LIT> ) && <STR_LIT> ) ; O << - value ; } else {


<s> void printS10ImmOperand ( const MachineInstr * MI , unsigned OpNo ) {

short value = ( short ) ( ( ( int ) MI -> getOperand ( OpNo ) . getImm ( ) << <NUM_LIT> ) >> <NUM_LIT> ) ;


<s> O << ( short ) MI -> getOperand ( OpNo ) . getImm ( ) ;


<s> } else { printOp ( MI -> getOperand ( OpNo ) ) ; O << <STR_LIT> ;


<s> } else { printOp ( MI -> getOperand ( OpNo ) ) ; O << <STR_LIT> ; }


<s> printS16ImmOperand ( MI , OpNo ) ; } else { printOp ( MI -> getOperand ( OpNo ) ) ; O << <STR_LIT> ; }


<s> void printSymbolLSA ( const MachineInstr * MI , unsigned OpNo ) { printOp ( MI -> getOperand ( OpNo ) ) ;


<s> printOp ( MI -> getOperand ( OpNo ) ) ;


<s> assert ( ( value <= ( <NUM_LIT> << <NUM_LIT> ) - <NUM_LIT> ) && <STR_LIT> ) ; O << value ;


<s> void printU16ImmOperand ( const MachineInstr * MI , unsigned OpNo ) { O << ( unsigned short ) MI -> getOperand ( OpNo ) . getImm ( ) ;


<s> void printU18ImmOperand ( const MachineInstr * MI , unsigned OpNo ) {

unsigned int value = MI -> getOperand ( OpNo ) . getImm ( ) ;


<s> O << ( unsigned ) MI -> getOperand ( OpNo ) . getImm ( ) ;


<s> void printU7ImmOperand ( const MachineInstr * MI , unsigned OpNo ) { unsigned int value = MI -> getOperand ( OpNo ) . getImm ( ) ; assert ( value < ( <NUM_LIT> << <NUM_LIT> ) && <STR_LIT> ) ;


<s> void printHBROperand ( const MachineInstr * MI , unsigned OpNo , raw_ostream & O ) { O << <STR_LIT> ;

printOp ( MI -> getOperand ( OpNo ) , O ) ;


<s> O << <STR_LIT> ; printOp ( MI -> getOperand ( OpNo ) , O ) ;


<s> case MachineOperand :: MO_JumpTableIndex : O << MAI -> getPrivateGlobalPrefix ( ) << <STR_LIT> << getFunctionNumber ( ) << '_' << MO . getIndex ( ) ; return ; case MachineOperand :: MO_ConstantPoolIndex : O << MAI -> getPrivateGlobalPrefix ( ) << <STR_LIT> << getFunctionNumber ( ) << '_' << MO . getIndex ( ) ; return ; case MachineOperand :: MO_ExternalSymbol : if ( TM . getRelocationModel ( ) != Reloc :: Static ) { O << <STR_LIT> << MAI -> getGlobalPrefix ( ) << MO . getSymbolName ( ) << <STR_LIT> ; return ; } O << * GetExternalSymbolSymbol ( MO . getSymbolName ( ) ) ; return ; case MachineOperand :: MO_GlobalAddress : if ( TM . getRelocationModel ( ) != Reloc :: Static ) {

const GlobalValue * GV = MO . getGlobal ( ) ;


<s> return ; } O << * GetExternalSymbolSymbol ( MO . getSymbolName ( ) ) ; return ; case MachineOperand :: MO_GlobalAddress : if ( TM . getRelocationModel ( ) != Reloc :: Static ) { const GlobalValue * GV = MO . getGlobal ( ) ; if ( ( ( GV -> isDeclaration ( ) || GV -> hasWeakLinkage ( ) || GV -> hasLinkOnceLinkage ( ) || GV -> hasCommonLinkage ( ) ) ) ) {


<s> assert ( TargetRegisterInfo :: isPhysicalRegister ( RegNo ) && <STR_LIT> ) ;


<s> void printS7ImmOperand ( const MachineInstr * MI , unsigned OpNo , raw_ostream & O ) { int value = MI -> getOperand ( OpNo ) . getImm ( ) ;

value = ( value << ( <NUM_LIT> - <NUM_LIT> ) ) >> ( <NUM_LIT> - <NUM_LIT> ) ;


<s> value = ( value << ( <NUM_LIT> - <NUM_LIT> ) ) >> ( <NUM_LIT> - <NUM_LIT> ) ; assert ( ( value >= - ( <NUM_LIT> << <NUM_LIT> ) && value <= ( <NUM_LIT> << <NUM_LIT> ) - <NUM_LIT> ) && <STR_LIT> ) ;


<s> if ( EmitSpecialLLVMGlobal ( GVar ) ) return ; std :: string name = Mang -> getValueName ( GVar ) ; printVisibility ( name , GVar -> getVisibility ( ) ) ; Constant * C = GVar -> getInitializer ( ) ; const Type * Type = C -> getType ( ) ; unsigned Size = TD -> getTypeAllocSize ( Type ) ; unsigned Align = TD -> getPreferredAlignmentLog ( GVar ) ; SwitchToSection ( TAI -> SectionForGlobal ( GVar ) ) ; if ( C -> isNullValue ( ) && ! GVar -> hasSection ( ) && ( GVar -> hasLocalLinkage ( ) || GVar -> hasExternalLinkage ( ) || GVar -> isWeakForLinker ( ) ) ) { if ( Size == <NUM_LIT> ) Size = <NUM_LIT> ; if ( GVar -> hasExternalLinkage ( ) ) { O << <STR_LIT> << name << '\n' ; O << <STR_LIT> << name << <STR_LIT> ; O << name << <STR_LIT> ; O << <STR_LIT> << Size << '\n' ; } else if ( GVar -> hasLocalLinkage ( ) ) { O << TAI -> getLCOMMDirective ( ) << name << ',' << Size ; } else { O << <STR_LIT> << name << ',' << Size ; } O << <STR_LIT> << TAI -> getCommentString ( ) << <STR_LIT> ; PrintUnmangledNameSafely ( GVar , O ) ;


<s> if ( ! MI -> getOperand ( OpNo ) . isReg ( ) || OpNo + <NUM_LIT> == MI -> getNumOperands ( ) || ! MI -> getOperand ( OpNo + <NUM_LIT> ) . isReg ( ) ) return true ; ++ OpNo ; break ; } }


<s> short value = MI -> getOperand ( OpNo ) . getImm ( ) ; assert ( ( value >= - ( <NUM_LIT> << <NUM_LIT> ) && value <= ( <NUM_LIT> << <NUM_LIT> ) - <NUM_LIT> ) && <STR_LIT> ) ; O << value ;


<s> void printS10ImmOperand ( const MachineInstr * MI , unsigned OpNo , raw_ostream & O ) { short value = MI -> getOperand ( OpNo ) . getImm ( ) ; assert ( ( value >= - ( <NUM_LIT> << <NUM_LIT> ) && value <= ( <NUM_LIT> << <NUM_LIT> ) - <NUM_LIT> ) && <STR_LIT> ) ; O << value ;


<s> short value = MI -> getOperand ( OpNo ) . getImm ( ) ; assert ( ( value <= ( <NUM_LIT> << <NUM_LIT> ) - <NUM_LIT> ) && <STR_LIT> ) ; O << value ;


<s> assert ( ( value <= ( <NUM_LIT> << <NUM_LIT> ) - <NUM_LIT> ) && <STR_LIT> ) ; O << value ;


<s> switch ( MO . getType ( ) ) { case MachineOperand :: MO_Immediate : llvm_report_error ( <STR_LIT> ) ; return ; case MachineOperand :: MO_MachineBasicBlock : O << * MO . getMBB ( ) -> getSymbol ( OutContext ) ; return ; case MachineOperand :: MO_JumpTableIndex : O << MAI -> getPrivateGlobalPrefix ( ) << <STR_LIT> << getFunctionNumber ( ) << '_' << MO . getIndex ( ) ; return ; case MachineOperand :: MO_ConstantPoolIndex :


<s> AsmPrinter ( O , TM , Ctx , Streamer , T ) {


<s> explicit <ISA_LIT>AsmPrinter ( formatted_raw_ostream & O , TargetMachine & TM , MCContext & Ctx , MCStreamer & Streamer , const MCAsmInfo * T ) : AsmPrinter ( O , TM , Ctx , Streamer , T ) {


<s> printInstruction ( MI , OS ) ; OutStreamer . EmitRawText ( OS . str ( ) ) ;


<s> virtual const char * getPassName ( ) const {


<s> void LLVMInitializeCell<ISA_LIT>AsmPrinter ( ) { RegisterAsmPrinter < <ISA_LIT>AsmPrinter > X ( TheCell<ISA_LIT>Target ) ;


<s> int displ = int ( MI -> getOperand ( OpNo + <NUM_LIT> ) . getImm ( ) ) ; if ( displ > <NUM_LIT> ) O << <STR_LIT> << displ ; else if ( displ < <NUM_LIT> ) O << displ ;


<s> bool <ISA_LIT>AsmPrinter :: PrintAsmMemoryOperand ( const MachineInstr * MI , unsigned OpNo , unsigned AsmVariant , const char * ExtraCode , raw_ostream & O ) {

if ( ExtraCode && ExtraCode [ <NUM_LIT> ] ) return true ;


<s> switch ( ExtraCode [ <NUM_LIT> ] ) { default : return true ; case 'L' :


<s> if ( ExtraCode && ExtraCode [ <NUM_LIT> ] ) { if ( ExtraCode [ <NUM_LIT> ] != <NUM_LIT> ) return true ; switch ( ExtraCode [ <NUM_LIT> ] ) { default : return true ; case 'L' :


<s> void printCallOperand ( const MachineInstr * MI , unsigned OpNo , raw_ostream & O ) {


<s> int16_t value16 = int16_t ( value ) ;

assert ( ( value16 >= - ( <NUM_LIT> << ( <NUM_LIT> + <NUM_LIT> ) ) && value16 <= ( <NUM_LIT> << ( <NUM_LIT> + <NUM_LIT> ) ) - <NUM_LIT> ) && <STR_LIT> ) ;


<s> void printDFormAddr ( const MachineInstr * MI , unsigned OpNo , raw_ostream & O ) { assert ( MI -> getOperand ( OpNo ) . isImm ( ) && <STR_LIT> ) ; int64_t value = int64_t ( MI -> getOperand ( OpNo ) . getImm ( ) ) ; int16_t value16 = int16_t ( value ) ;


<s> void printHBROperand ( const MachineInstr * MI , unsigned OpNo , raw_ostream & O ) { printOp ( MI -> getOperand ( OpNo ) , O ) ;


<s> void printMemRegReg ( const MachineInstr * MI , unsigned OpNo , raw_ostream & O ) { const MachineOperand & MO = MI -> getOperand ( OpNo ) ;

O << getRegisterName ( MO . getReg ( ) ) << <STR_LIT> ;


<s> O << getRegisterName ( MO . getReg ( ) ) << <STR_LIT> ; printOperand ( MI , OpNo + <NUM_LIT> , O ) ;


<s> return ; case MachineOperand :: MO_ExternalSymbol : if ( TM . getRelocationModel ( ) != Reloc :: Static ) { O << <STR_LIT> << MAI -> getGlobalPrefix ( ) << MO . getSymbolName ( ) << <STR_LIT> ; return ; } O << * GetExternalSymbolSymbol ( MO . getSymbolName ( ) ) ; return ; case MachineOperand :: MO_GlobalAddress : if ( TM . getRelocationModel ( ) != Reloc :: Static ) { const GlobalValue * GV = MO . getGlobal ( ) ; if ( ( ( GV -> isDeclaration ( ) || GV -> hasWeakLinkage ( ) || GV -> hasLinkOnceLinkage ( ) || GV -> hasCommonLinkage ( ) ) ) ) { O << * GetSymbolWithGlobalValueBase ( GV , <STR_LIT> ) ; return ; } } O << * Mang -> getSymbol ( MO . getGlobal ( ) ) ; return ; case MachineOperand :: MO_MCSymbol : O << * ( MO . getMCSymbol ( ) ) ; return ; default :

O << <STR_LIT> << MO . getType ( ) << <STR_LIT> ;


<s> O << getRegisterName ( MO . getReg ( ) ) ; } else if ( MO . isImm ( ) ) { O << MO . getImm ( ) ;


<s> void printPCRelativeOperand ( const MachineInstr * MI , unsigned OpNo , raw_ostream & O ) { printOp ( MI -> getOperand ( OpNo ) , O ) ;


<s> if ( MI -> getOperand ( OpNo ) . isImm ( ) ) { int value = ( int ) MI -> getOperand ( OpNo ) . getImm ( ) ; assert ( ( value >= <NUM_LIT> && value < <NUM_LIT> ) && <STR_LIT> ) ; O << - value ; } else { llvm_unreachable ( <STR_LIT> ) ; }


<s> assert ( ( value >= <NUM_LIT> && value < <NUM_LIT> ) && <STR_LIT> ) ; O << - value ; } else { llvm_unreachable ( <STR_LIT> ) ; }


<s> int value = ( int ) MI -> getOperand ( OpNo ) . getImm ( ) ; assert ( ( value >= <NUM_LIT> && value <= <NUM_LIT> ) && <STR_LIT> ) ; O << - value ;


<s> assert ( ( value >= - ( <NUM_LIT> << <NUM_LIT> ) && value <= ( <NUM_LIT> << <NUM_LIT> ) - <NUM_LIT> ) && <STR_LIT> ) ; O << value ;


<s> void printS16ImmOperand ( const MachineInstr * MI , unsigned OpNo , raw_ostream & O ) {

O << ( short ) MI -> getOperand ( OpNo ) . getImm ( ) ;


<s> if ( MI -> getOperand ( OpNo ) . isImm ( ) ) { printS16ImmOperand ( MI , OpNo , O ) ; } else {


<s> assert ( ( value <= ( <NUM_LIT> << <NUM_LIT> ) - <NUM_LIT> ) && <STR_LIT> ) ;


<s> void printU10ImmOperand ( const MachineInstr * MI , unsigned OpNo , raw_ostream & O ) { short value = ( short ) ( ( ( int ) MI -> getOperand ( OpNo ) . getImm ( ) << <NUM_LIT> ) >> <NUM_LIT> ) ;

assert ( ( value <= ( <NUM_LIT> << <NUM_LIT> ) - <NUM_LIT> ) && <STR_LIT> ) ;


<s> void printU16ImmOperand ( const MachineInstr * MI , unsigned OpNo , raw_ostream & O ) { O << ( unsigned short ) MI -> getOperand ( OpNo ) . getImm ( ) ;


<s> void printU16ImmOperand ( const MachineInstr * MI , unsigned OpNo , raw_ostream & O ) {

O << ( unsigned short ) MI -> getOperand ( OpNo ) . getImm ( ) ;


<s> unsigned int value = MI -> getOperand ( OpNo ) . getImm ( ) ; assert ( value < ( <NUM_LIT> << <NUM_LIT> ) && <STR_LIT> ) ; O << value ;


<s> unsigned int value = MI -> getOperand ( OpNo ) . getImm ( ) ; assert ( value < ( <NUM_LIT> << <NUM_LIT> ) && <STR_LIT> ) ;


<s> LR [ <NUM_LIT> ] . first = <STR_LIT> ; LR [ <NUM_LIT> ] . second = <NUM_LIT> ;


<s> LR [ <NUM_LIT> ] . first = <STR_LIT> ;


<s> return ( <ISA_LIT>RegisterInfo :: getNumArgRegs ( ) * stackSlotSize ( ) ) ;


<s> unsigned Align = std :: max ( TargetAlign , MFI -> getMaxAlignment ( ) ) ; assert ( isPowerOf2_32 ( Align ) && <STR_LIT> ) ; unsigned AlignMask = Align - <NUM_LIT> ;

unsigned maxCallFrameSize = MFI -> getMaxCallFrameSize ( ) ;


<s> BuildMI ( MBB , MBBI , dl , TII . get ( <STR_LIT> ) , <STR_LIT> ) . addReg ( <STR_LIT> ) . addImm ( FrameSize ) ; } else if ( FrameSize <= ( <NUM_LIT> << <NUM_LIT> ) - <NUM_LIT> && FrameSize >= - ( <NUM_LIT> << <NUM_LIT> ) ) { BuildMI ( MBB , MBBI , dl , TII . get ( <STR_LIT> ) , <STR_LIT> ) . addImm ( <NUM_LIT> ) . addReg ( <STR_LIT> ) ; BuildMI ( MBB , MBBI , dl , TII . get ( <STR_LIT> ) , <STR_LIT> ) . addImm ( FrameSize ) ; BuildMI ( MBB , MBBI , dl , TII . get ( <STR_LIT> ) , <STR_LIT> ) . addReg ( <STR_LIT> ) . addReg ( <STR_LIT> ) ; BuildMI ( MBB , MBBI , dl , TII . get ( <STR_LIT> ) , <STR_LIT> ) . addImm ( <NUM_LIT> ) . addReg ( <STR_LIT> ) ; BuildMI ( MBB , MBBI , dl , TII . get ( <STR_LIT> ) , <STR_LIT> ) . addReg ( <STR_LIT> ) . addImm ( <NUM_LIT> ) ; BuildMI ( MBB , MBBI , dl , TII . get ( <STR_LIT> ) , <STR_LIT> ) . addReg ( <STR_LIT> ) . addReg ( <STR_LIT> ) ;


<s> if ( isInt < <NUM_LIT> > ( FrameSize ) ) { BuildMI ( MBB , MBBI , dl , TII . get ( <STR_LIT> ) , <STR_LIT> ) . addImm ( FrameSize ) . addReg ( <STR_LIT> ) ; BuildMI ( MBB , MBBI , dl , TII . get ( <STR_LIT> ) , <STR_LIT> ) . addReg ( <STR_LIT> ) . addImm ( FrameSize ) ; } else if ( isInt < <NUM_LIT> > ( FrameSize ) ) { BuildMI ( MBB , MBBI , dl , TII . get ( <STR_LIT> ) , <STR_LIT> ) . addImm ( - <NUM_LIT> ) . addReg ( <STR_LIT> ) ; BuildMI ( MBB , MBBI , dl , TII . get ( <STR_LIT> ) , <STR_LIT> ) . addImm ( FrameSize ) ; BuildMI ( MBB , MBBI , dl , TII . get ( <STR_LIT> ) , <STR_LIT> ) . addReg ( <STR_LIT> ) . addReg ( <STR_LIT> ) ; BuildMI ( MBB , MBBI , dl , TII . get ( <STR_LIT> ) , <STR_LIT> ) . addReg ( <STR_LIT> ) . addReg ( <STR_LIT> ) ; BuildMI ( MBB , MBBI , dl , TII . get ( <STR_LIT> ) , <STR_LIT> ) . addReg ( <STR_LIT> ) . addImm ( <NUM_LIT> ) ; BuildMI ( MBB , MBBI , dl , TII . get ( <STR_LIT> ) , <STR_LIT> ) . addReg ( <STR_LIT> ) . addReg ( <STR_LIT> ) ; } else { report_fatal_error ( <STR_LIT> + Twine ( FrameSize ) ) ; } if ( hasDebugInfo ) { std :: vector < MachineMove > & Moves = MMI . getFrameMoves ( ) ; MachineLocation SPDst ( MachineLocation :: VirtualFP ) ; MachineLocation SPSrc ( MachineLocation :: VirtualFP , - FrameSize ) ; Moves . push_back ( MachineMove ( FrameLabel , SPDst , SPSrc ) ) ; const std :: vector < CalleeSavedInfo > & CSI = MFI -> getCalleeSavedInfo ( ) ;

for ( unsigned I = <NUM_LIT> , E = CSI . size ( ) ; I != E ; ++ I ) {


<s> static int FItoStackOffset ( int frame_index ) { return frame_index * stackSlotSize ( ) ;


<s> return frame_index * stackSlotSize ( ) ;


<s> MachineLocation Dst ( MachineLocation :: VirtualFP ) ; MachineLocation Src ( <STR_LIT> , <NUM_LIT> ) ;

Moves . push_back ( MachineMove ( <NUM_LIT> , Dst , Src ) ) ;


<s> MachineLocation Dst ( MachineLocation :: VirtualFP ) ; MachineLocation Src ( <STR_LIT> , <NUM_LIT> ) ; Moves . push_back ( MachineMove ( <NUM_LIT> , Dst , Src ) ) ;


<s> const MachineFrameInfo * MFI = MF . getFrameInfo ( ) ;

return MFI -> getStackSize ( ) && ( DisableFramePointerElim ( MF ) || MFI -> hasVarSizedObjects ( ) ) ;


<s> return ( ( <NUM_LIT> << <NUM_LIT> ) - <NUM_LIT> ) * stackSlotSize ( ) ;


return - ( <NUM_LIT> << <NUM_LIT> ) * stackSlotSize ( ) ;


<s> return ( <NUM_LIT> * stackSlotSize ( ) ) ;


<s> MF . getRegInfo ( ) . setPhysRegUnused ( <STR_LIT> ) ; MF . getRegInfo ( ) . setPhysRegUnused ( <STR_LIT> ) ;

MachineFrameInfo * MFI = MF . getFrameInfo ( ) ;


return MFI -> getStackSize ( ) && ( MF . getTarget ( ) . Options . DisableFramePointerElim ( MF ) || MFI -> hasVarSizedObjects ( ) ) ;


<s> MF . getRegInfo ( ) . setPhysRegUnused ( <STR_LIT> ) ; MF . getRegInfo ( ) . setPhysRegUnused ( <STR_LIT> ) ; MF . getRegInfo ( ) . setPhysRegUnused ( <STR_LIT> ) ; MachineFrameInfo * MFI = MF . getFrameInfo ( ) ;

const TargetRegisterClass * RC = & <STR_LIT> ;


<s> MF . getRegInfo ( ) . setPhysRegUnused ( <STR_LIT> ) ; MF . getRegInfo ( ) . setPhysRegUnused ( <STR_LIT> ) ; MF . getRegInfo ( ) . setPhysRegUnused ( <STR_LIT> ) ; MachineFrameInfo * MFI = MF . getFrameInfo ( ) ; const TargetRegisterClass * RC = & <STR_LIT> ; RS -> setScavengingFrameIndex ( MFI -> CreateStackObject ( RC -> getSize ( ) / <NUM_LIT> , RC -> getAlignment ( ) / <NUM_LIT> , false ) ) ;


<s> MachineLocation Dst ( MachineLocation :: VirtualFP ) ;

MachineLocation Src ( <STR_LIT> , <NUM_LIT> ) ;


<s> unsigned FrameSize = MFI -> getStackSize ( ) ; unsigned TargetAlign = getStackAlignment ( ) ; unsigned Align = std :: max ( TargetAlign , MFI -> getMaxAlignment ( ) ) ; assert ( isPowerOf2_32 ( Align ) && <STR_LIT> ) ; unsigned AlignMask = Align - <NUM_LIT> ; unsigned maxCallFrameSize = MFI -> getMaxCallFrameSize ( ) ; if ( MFI -> hasVarSizedObjects ( ) ) maxCallFrameSize = ( maxCallFrameSize + AlignMask ) & ~ AlignMask ; MFI -> setMaxCallFrameSize ( maxCallFrameSize ) ;


<s> assert ( ( FrameSize & <NUM_LIT> ) == <NUM_LIT> && <STR_LIT> ) ; if ( FrameSize > <NUM_LIT> || MFI -> adjustsStack ( ) ) { FrameSize = FrameSize + <ISA_LIT>FrameLowering :: minStackSize ( ) ; if ( isInt < <NUM_LIT> > ( FrameSize + LinkSlotOffset ) ) { BuildMI ( MBB , MBBI , dl , TII . get ( <STR_LIT> ) , <STR_LIT> ) . addImm ( FrameSize + LinkSlotOffset ) . addReg ( <STR_LIT> ) ; BuildMI ( MBB , MBBI , dl , TII . get ( <STR_LIT> ) , <STR_LIT> ) . addReg ( <STR_LIT> ) . addImm ( FrameSize ) ; } else if ( FrameSize <= ( <NUM_LIT> << <NUM_LIT> ) - <NUM_LIT> && FrameSize >= - ( <NUM_LIT> << <NUM_LIT> ) ) { BuildMI ( MBB , MBBI , dl , TII . get ( <STR_LIT> ) , <STR_LIT> ) . addImm ( <NUM_LIT> ) . addReg ( <STR_LIT> ) ; BuildMI ( MBB , MBBI , dl , TII . get ( <STR_LIT> ) , <STR_LIT> ) . addImm ( FrameSize ) ;

BuildMI ( MBB , MBBI , dl , TII . get ( <STR_LIT> ) , <STR_LIT> ) . addReg ( <STR_LIT> ) . addReg ( <STR_LIT> ) ;


<s> void <ISA_LIT>FrameLowering :: processFunctionBeforeCalleeSavedScan ( MachineFunction & MF , RegScavenger * RS ) const { MF . getRegInfo ( ) . setPhysRegUnused ( <STR_LIT> ) ; MF . getRegInfo ( ) . setPhysRegUnused ( <STR_LIT> ) ; MF . getRegInfo ( ) . setPhysRegUnused ( <STR_LIT> ) ; MachineFrameInfo * MFI = MF . getFrameInfo ( ) ; const TargetRegisterClass * RC = & <STR_LIT> ; RS -> setScavengingFrameIndex ( MFI -> CreateStackObject ( RC -> getSize ( ) , RC -> getAlignment ( ) , false ) ) ;


<s> MF . getRegInfo ( ) . setPhysRegUnused ( <STR_LIT> ) ; MF . getRegInfo ( ) . setPhysRegUnused ( <STR_LIT> ) ; MF . getRegInfo ( ) . setPhysRegUnused ( <STR_LIT> ) ;


<s> <ISA_LIT>FrameLowering :: <ISA_LIT>FrameLowering ( const <ISA_LIT>Subtarget & sti ) : TargetFrameLowering ( TargetFrameLowering :: StackGrowsDown , <NUM_LIT> , <NUM_LIT> ) , Subtarget ( sti ) { LR [ <NUM_LIT> ] . first = <STR_LIT> ; LR [ <NUM_LIT> ] . second = <NUM_LIT> ;


<s> void <ISA_LIT>HazardRecognizer :: AdvanceCycle ( ) { DOUT << <STR_LIT> ;


<s> void <ISA_LIT>HazardRecognizer :: EmitInstruction ( SUnit * SU ) {


<s> void <ISA_LIT>HazardRecognizer :: EmitNoop ( ) {


<s> case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : mustBeOdd = true ;


<s> <ISA_LIT>HazardRecognizer ( const TargetInstrInfo & ) {


<s> void <ISA_LIT>HazardRecognizer :: AdvanceCycle ( ) { DOUT ( llvm :: dbgs ( ) << <STR_LIT> ;


<s> case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : mustBeOdd = true ; break ; default : break ;


<s> void <ISA_LIT>HazardRecognizer :: AdvanceCycle ( ) {


<s> case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> :


<s> switch ( Node -> getOpcode ( ) ) { case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> :


<s> if ( mem ) return MIB . addImm ( Offset ) . addFrameIndex ( FI ) ; else return MIB . addFrameIndex ( FI ) . addImm ( Offset ) ;


<s> void <ISA_LIT>InstrInfo :: storeRegToStackSlot ( MachineBasicBlock & MBB , MachineBasicBlock :: iterator MI , unsigned SrcReg , bool isKill , int FrameIdx , const TargetRegisterClass * RC , const TargetRegisterInfo * TRI ) const { unsigned opc ; bool isValidFrameIdx = ( FrameIdx < <ISA_LIT>FrameLowering :: maxFrameOffset ( ) ) ; if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ;


<s> if ( isUncondBranch ( LastInst ) ) { if ( ! LastInst -> getOperand ( <NUM_LIT> ) . isMBB ( ) ) return true ; TBB = LastInst -> getOperand ( <NUM_LIT> ) . getMBB ( ) ; return false ; } else if ( isCondBranch ( LastInst ) ) { TBB = LastInst -> getOperand ( <NUM_LIT> ) . getMBB ( ) ; DEBUG ( errs ( ) << <STR_LIT> ) ; DEBUG ( LastInst -> dump ( ) ) ; Cond . push_back ( MachineOperand :: CreateImm ( LastInst -> getOpcode ( ) ) ) ; Cond . push_back ( LastInst -> getOperand ( <NUM_LIT> ) ) ; return false ; } return true ; } MachineInstr * SecondLastInst = I ; if ( SecondLastInst && I != MBB . begin ( ) && isUnpredicatedTerminator ( -- I ) ) return true ; if ( isCondBranch ( SecondLastInst ) && isUncondBranch ( LastInst ) ) { TBB = SecondLastInst -> getOperand ( <NUM_LIT> ) . getMBB ( ) ; DEBUG ( errs ( ) << <STR_LIT> ) ; DEBUG ( SecondLastInst -> dump ( ) ) ; Cond . push_back ( MachineOperand :: CreateImm ( SecondLastInst -> getOpcode ( ) ) ) ; Cond . push_back ( SecondLastInst -> getOperand ( <NUM_LIT> ) ) ; FBB = LastInst -> getOperand ( <NUM_LIT> ) . getMBB ( ) ; return false ; }

if ( isUncondBranch ( SecondLastInst ) && isUncondBranch ( LastInst ) ) {


<s> void <ISA_LIT>InstrInfo :: copyPhysReg ( MachineBasicBlock & MBB , MachineBasicBlock :: iterator I , DebugLoc DL , unsigned DestReg , unsigned SrcReg , bool KillSrc ) const {

BuildMI ( MBB , I , DL , get ( <STR_LIT> ) , DestReg ) . addReg ( SrcReg , getKillRegState ( KillSrc ) ) ;


<s> void <ISA_LIT>InstrInfo :: copyPhysReg ( MachineBasicBlock & MBB , MachineBasicBlock :: iterator I , DebugLoc DL , unsigned DestReg , unsigned SrcReg , bool KillSrc ) const { BuildMI ( MBB , I , DL , get ( <STR_LIT> ) , DestReg ) . addReg ( SrcReg , getKillRegState ( KillSrc ) ) ;


return new <ISA_LIT>HazardRecognizer ( * TII ) ;


<s> assert ( TII && <STR_LIT> ) ; return new <ISA_LIT>HazardRecognizer ( * TII ) ;


<s> static MachineBasicBlock :: iterator findHBRPosition ( MachineBasicBlock & MBB ) {

MachineBasicBlock :: iterator J = MBB . end ( ) ;


<s> virtual const <ISA_LIT>RegisterInfo & getRegisterInfo ( ) const {


<s> } else { MIB = BuildMI ( & MBB , DL , get ( Cond [ <NUM_LIT> ] . getImm ( ) ) ) ; MIB . addReg ( Cond [ <NUM_LIT> ] . getReg ( ) ) . addMBB ( TBB ) ; if ( haveHBR ) { MIB = BuildMI ( MBB , findHBRPosition ( MBB ) , DL , get ( <STR_LIT> ) ) ; MIB . addSym ( branchLabel ) ; MIB . addMBB ( TBB ) ; } DEBUG ( errs ( ) << <STR_LIT> ) ; DEBUG ( ( * MIB ) . dump ( ) ) ; } return <NUM_LIT> ; } else { MIB = BuildMI ( & MBB , DL , get ( Cond [ <NUM_LIT> ] . getImm ( ) ) ) ; MachineInstrBuilder MIB2 = BuildMI ( & MBB , DL , get ( <STR_LIT> ) ) ; MIB . addReg ( Cond [ <NUM_LIT> ] . getReg ( ) ) . addMBB ( TBB ) ;


<s> MIB . addMBB ( TBB ) ; DEBUG ( errs ( ) << <STR_LIT> ) ; DEBUG ( ( * MIB ) . dump ( ) ) ; if ( haveHBR ) { MIB = BuildMI ( MBB , findHBRPosition ( MBB ) , DL , get ( <STR_LIT> ) ) ; MIB . addSym ( branchLabel ) ; MIB . addMBB ( TBB ) ; } } else { MIB = BuildMI ( & MBB , DL , get ( Cond [ <NUM_LIT> ] . getImm ( ) ) ) ; MIB . addReg ( Cond [ <NUM_LIT> ] . getReg ( ) ) . addMBB ( TBB ) ; if ( haveHBR ) { MIB = BuildMI ( MBB , findHBRPosition ( MBB ) , DL , get ( <STR_LIT> ) ) ; MIB . addSym ( branchLabel ) ; MIB . addMBB ( TBB ) ; } DEBUG ( errs ( ) << <STR_LIT> ) ; DEBUG ( ( * MIB ) . dump ( ) ) ; } return <NUM_LIT> ; } else {


<s> else if ( RC == & <STR_LIT> ) opc = isValidFrameIdx ? <STR_LIT> : <STR_LIT> ; else if ( RC == & <STR_LIT> ) opc = isValidFrameIdx ? <STR_LIT> : <STR_LIT> ; else if ( RC == & <STR_LIT> ) opc = isValidFrameIdx ? <STR_LIT> : <STR_LIT> ; else if ( RC == & <STR_LIT> ) opc = isValidFrameIdx ? <STR_LIT> : <STR_LIT> ; else if ( RC == & <STR_LIT> ) opc = isValidFrameIdx ? <STR_LIT> : <STR_LIT> ; else if ( RC == & <STR_LIT> ) opc = isValidFrameIdx ? <STR_LIT> : <STR_LIT> ; else if ( RC == & <STR_LIT> ) opc = isValidFrameIdx ? <STR_LIT> : <STR_LIT> ; else llvm_unreachable ( <STR_LIT> ) ; DebugLoc DL ; if ( MI != MBB . end ( ) ) DL = MI -> getDebugLoc ( ) ; addFrameReference ( BuildMI ( MBB , MI , DL , get ( opc ) , DestReg ) , FrameIdx ) ;


<s> MachineBasicBlock :: iterator I = MBB . end ( ) ; removeHBR ( MBB ) ; if ( I == MBB . begin ( ) ) return <NUM_LIT> ; -- I ; while ( I -> isDebugValue ( ) ) { if ( I == MBB . begin ( ) ) return <NUM_LIT> ; -- I ; } if ( ! isCondBranch ( I ) && ! isUncondBranch ( I ) ) return <NUM_LIT> ; DEBUG ( errs ( ) << <STR_LIT> ) ; DEBUG ( I -> dump ( ) ) ; I -> eraseFromParent ( ) ; I = MBB . end ( ) ; if ( I == MBB . begin ( ) ) return <NUM_LIT> ; -- I ; if ( ! ( isCondBranch ( I ) || isUncondBranch ( I ) ) ) return <NUM_LIT> ;


<s> I = MBB . end ( ) ; if ( I == MBB . begin ( ) ) return <NUM_LIT> ; -- I ; if ( ! ( isCondBranch ( I ) || isUncondBranch ( I ) ) ) return <NUM_LIT> ; DEBUG ( errs ( ) << <STR_LIT> ) ; DEBUG ( I -> dump ( ) ) ; I -> eraseFromParent ( ) ;


<s> if ( I -> getOpcode ( ) == <STR_LIT> || I -> getOpcode ( ) == <STR_LIT> ) {


<s> <ISA_LIT>InstrInfo :: <ISA_LIT>InstrInfo ( <ISA_LIT>TargetMachine & tm ) : <ISA_LIT>GenInstrInfo ( <STR_LIT> , <STR_LIT> ) , TM ( tm ) , RI ( * TM . getSubtargetImpl ( ) , * this ) {


<s> else if ( RC == & <STR_LIT> ) opc = isValidFrameIdx ? <STR_LIT> : <STR_LIT> ; else if ( RC == & <STR_LIT> ) opc = isValidFrameIdx ? <STR_LIT> : <STR_LIT> ; else if ( RC == & <STR_LIT> ) opc = isValidFrameIdx ? <STR_LIT> : <STR_LIT> ; else if ( RC == & <STR_LIT> ) opc = isValidFrameIdx ? <STR_LIT> : <STR_LIT> ; else if ( RC == & <STR_LIT> ) opc = isValidFrameIdx ? <STR_LIT> : <STR_LIT> ; else if ( RC == & <STR_LIT> ) opc = isValidFrameIdx ? <STR_LIT> : <STR_LIT> ; else llvm_unreachable ( <STR_LIT> ) ; DebugLoc DL ; if ( MI != MBB . end ( ) ) DL = MI -> getDebugLoc ( ) ; addFrameReference ( BuildMI ( MBB , MI , DL , get ( opc ) ) . addReg ( SrcReg , getKillRegState ( isKill ) ) , FrameIdx ) ;


<s> } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ) ? <STR_LIT> : <STR_LIT> ; } else { llvm_unreachable ( <STR_LIT> ) ; } DebugLoc DL ; if ( MI != MBB . end ( ) ) DL = MI -> getDebugLoc ( ) ;

addFrameReference ( BuildMI ( MBB , MI , DL , get ( opc ) , DestReg ) , FrameIdx ) ;


<s> opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ) ? <STR_LIT> : <STR_LIT> ; } else {


<s> TBB = LastInst -> getOperand ( <NUM_LIT> ) . getMBB ( ) ; DEBUG ( cerr << <STR_LIT> ) ; DEBUG ( LastInst -> dump ( ) ) ; Cond . push_back ( MachineOperand :: CreateImm ( LastInst -> getOpcode ( ) ) ) ; Cond . push_back ( LastInst -> getOperand ( <NUM_LIT> ) ) ; return false ; } return true ; } MachineInstr * SecondLastInst = I ; if ( SecondLastInst && I != MBB . begin ( ) && isUnpredicatedTerminator ( -- I ) ) return true ; if ( isCondBranch ( SecondLastInst ) && isUncondBranch ( LastInst ) ) { TBB = SecondLastInst -> getOperand ( <NUM_LIT> ) . getMBB ( ) ; DEBUG ( cerr << <STR_LIT> ) ; DEBUG ( SecondLastInst -> dump ( ) ) ; Cond . push_back ( MachineOperand :: CreateImm ( SecondLastInst -> getOpcode ( ) ) ) ;

Cond . push_back ( SecondLastInst -> getOperand ( <NUM_LIT> ) ) ;


<s> bool <ISA_LIT>InstrInfo :: BlockHasNoFallThrough ( const MachineBasicBlock & MBB ) const { return ( ! MBB . empty ( ) && isUncondBranch ( & MBB . back ( ) ) ) ;


<s> bool <ISA_LIT>InstrInfo :: BlockHasNoFallThrough ( const MachineBasicBlock & MBB ) const {

return ( ! MBB . empty ( ) && isUncondBranch ( & MBB . back ( ) ) ) ;


<s> bool <ISA_LIT>InstrInfo :: copyRegToReg ( MachineBasicBlock & MBB , MachineBasicBlock :: iterator MI , unsigned DestReg , unsigned SrcReg , const TargetRegisterClass * DestRC , const TargetRegisterClass * SrcRC ) const { DebugLoc DL = DebugLoc :: getUnknownLoc ( ) ; if ( MI != MBB . end ( ) ) DL = MI -> getDebugLoc ( ) ; if ( DestRC == <STR_LIT> ) { BuildMI ( MBB , MI , DL , get ( <STR_LIT> ) , DestReg ) . addReg ( SrcReg ) ; } else if ( DestRC == <STR_LIT> ) { BuildMI ( MBB , MI , DL , get ( <STR_LIT> ) , DestReg ) . addReg ( SrcReg ) ; } else if ( DestRC == <STR_LIT> ) { BuildMI ( MBB , MI , DL , get ( <STR_LIT> ) , DestReg ) . addReg ( SrcReg ) ; } else if ( DestRC == <STR_LIT> ) { BuildMI ( MBB , MI , DL , get ( <STR_LIT> ) , DestReg ) . addReg ( SrcReg ) ; } else if ( DestRC == <STR_LIT> ) { BuildMI ( MBB , MI , DL , get ( <STR_LIT> ) , DestReg ) . addReg ( SrcReg ) ;


<s> BuildMI ( MBB , MI , DL , get ( <STR_LIT> ) , DestReg ) . addReg ( SrcReg ) ; } else if ( DestRC == <STR_LIT> ) { BuildMI ( MBB , MI , DL , get ( <STR_LIT> ) , DestReg ) . addReg ( SrcReg ) ; } else if ( DestRC == <STR_LIT> ) { BuildMI ( MBB , MI , DL , get ( <STR_LIT> ) , DestReg ) . addReg ( SrcReg ) ; } else if ( DestRC == <STR_LIT> ) { BuildMI ( MBB , MI , DL , get ( <STR_LIT> ) , DestReg ) . addReg ( SrcReg ) ; } else if ( DestRC == <STR_LIT> ) {


<s> case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : if ( OpNum == <NUM_LIT> ) { unsigned InReg = MI -> getOperand ( <NUM_LIT> ) . getReg ( ) ; bool isKill = MI -> getOperand ( <NUM_LIT> ) . isKill ( ) ; if ( FrameIndex < <ISA_LIT>FrameInfo :: maxFrameOffset ( ) ) { MachineInstrBuilder MIB = BuildMI ( MF , MI -> getDebugLoc ( ) , get ( <STR_LIT> ) ) ; MIB . addReg ( InReg , getKillRegState ( isKill ) ) ; NewMI = addFrameReference ( MIB , FrameIndex ) ; } } else { unsigned OutReg = MI -> getOperand ( <NUM_LIT> ) . getReg ( ) ; bool isDead = MI -> getOperand ( <NUM_LIT> ) . isDead ( ) ; MachineInstrBuilder MIB = BuildMI ( MF , MI -> getDebugLoc ( ) , get ( Opc ) ) ; MIB . addReg ( OutReg , RegState :: Define | getDeadRegState ( isDead ) ) ; Opc = ( FrameIndex < <ISA_LIT>FrameInfo :: maxFrameOffset ( ) ) ? <STR_LIT> : <STR_LIT> ;


<s> unsigned OpNum = Ops [ <NUM_LIT> ] ; unsigned Opc = MI -> getOpcode ( ) ; MachineInstr * NewMI = <NUM_LIT> ; switch ( Opc ) { case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : if ( OpNum == <NUM_LIT> ) { unsigned InReg = MI -> getOperand ( <NUM_LIT> ) . getReg ( ) ; bool isKill = MI -> getOperand ( <NUM_LIT> ) . isKill ( ) ; if ( FrameIndex < <ISA_LIT>FrameInfo :: maxFrameOffset ( ) ) { MachineInstrBuilder MIB = BuildMI ( MF , MI -> getDebugLoc ( ) , get ( <STR_LIT> ) ) ; MIB . addReg ( InReg , getKillRegState ( isKill ) ) ; NewMI = addFrameReference ( MIB , FrameIndex ) ; } } else { unsigned OutReg = MI -> getOperand ( <NUM_LIT> ) . getReg ( ) ; bool isDead = MI -> getOperand ( <NUM_LIT> ) . isDead ( ) ; MachineInstrBuilder MIB = BuildMI ( MF , MI -> getDebugLoc ( ) , get ( Opc ) ) ;

MIB . addReg ( OutReg , RegState :: Define | getDeadRegState ( isDead ) ) ;


<s> MachineInstrBuilder MIB = BuildMI ( & MBB , dl , get ( Cond [ <NUM_LIT> ] . getImm ( ) ) ) ; MIB . addReg ( Cond [ <NUM_LIT> ] . getReg ( ) ) . addMBB ( TBB ) ; DEBUG ( cerr << <STR_LIT> ) ; DEBUG ( ( * MIB ) . dump ( ) ) ; } return <NUM_LIT> ; } else { MachineInstrBuilder MIB = BuildMI ( & MBB , dl , get ( Cond [ <NUM_LIT> ] . getImm ( ) ) ) ; MachineInstrBuilder MIB2 = BuildMI ( & MBB , dl , get ( <STR_LIT> ) ) ; MIB . addReg ( Cond [ <NUM_LIT> ] . getReg ( ) ) . addMBB ( TBB ) ; MIB2 . addMBB ( FBB ) ; DEBUG ( cerr << <STR_LIT> ) ; DEBUG ( ( * MIB ) . dump ( ) ) ;


<s> } else { MachineInstrBuilder MIB = BuildMI ( & MBB , dl , get ( Cond [ <NUM_LIT> ] . getImm ( ) ) ) ; MIB . addReg ( Cond [ <NUM_LIT> ] . getReg ( ) ) . addMBB ( TBB ) ; DEBUG ( cerr << <STR_LIT> ) ; DEBUG ( ( * MIB ) . dump ( ) ) ; } return <NUM_LIT> ; } else { MachineInstrBuilder MIB = BuildMI ( & MBB , dl , get ( Cond [ <NUM_LIT> ] . getImm ( ) ) ) ; MachineInstrBuilder MIB2 = BuildMI ( & MBB , dl , get ( <STR_LIT> ) ) ; MIB . addReg ( Cond [ <NUM_LIT> ] . getReg ( ) ) . addMBB ( TBB ) ; MIB2 . addMBB ( FBB ) ; DEBUG ( cerr << <STR_LIT> ) ; DEBUG ( ( * MIB ) . dump ( ) ) ;


<s> abort ( ) ; if ( Addr [ <NUM_LIT> ] . isFI ( ) ) { } else { unsigned Opc = <NUM_LIT> ; if ( RC == <STR_LIT> ) { } else if ( RC == <STR_LIT> ) { } else if ( RC == <STR_LIT> ) { } else if ( RC == <STR_LIT> ) { } else if ( RC == <STR_LIT> ) { } else if ( RC == <STR_LIT> ) {


<s> bool isValidFrameIdx = ( FrameIdx < <ISA_LIT>FrameInfo :: maxFrameOffset ( ) ) ; if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ) ? <STR_LIT> : <STR_LIT> ; } else { assert ( <NUM_LIT> && <STR_LIT> ) ; abort ( ) ; } DebugLoc DL = DebugLoc :: getUnknownLoc ( ) ; if ( MI != MBB . end ( ) ) DL = MI -> getDebugLoc ( ) ; addFrameReference ( BuildMI ( MBB , MI , DL , get ( opc ) , DestReg ) , FrameIdx ) ;


<s> if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ) ? <STR_LIT> : <STR_LIT> ; } else { assert ( <NUM_LIT> && <STR_LIT> ) ; abort ( ) ; } DebugLoc DL = DebugLoc :: getUnknownLoc ( ) ; if ( MI != MBB . end ( ) ) DL = MI -> getDebugLoc ( ) ;


<s> unsigned <ISA_LIT>InstrInfo :: RemoveBranch ( MachineBasicBlock & MBB ) const { MachineBasicBlock :: iterator I = MBB . end ( ) ; if ( I == MBB . begin ( ) ) return <NUM_LIT> ; -- I ;

if ( ! isCondBranch ( I ) && ! isUncondBranch ( I ) ) return <NUM_LIT> ;


<s> DEBUG ( cerr << <STR_LIT> ) ; DEBUG ( I -> dump ( ) ) ; I -> eraseFromParent ( ) ; I = MBB . end ( ) ; if ( I == MBB . begin ( ) ) return <NUM_LIT> ; -- I ; if ( ! ( isCondBranch ( I ) || isUncondBranch ( I ) ) ) return <NUM_LIT> ; DEBUG ( cerr << <STR_LIT> ) ; DEBUG ( I -> dump ( ) ) ; I -> eraseFromParent ( ) ;


<s> } else if ( RC == <STR_LIT> ) { } else if ( RC == <STR_LIT> ) { } else if ( RC == <STR_LIT> ) { } else { assert ( <NUM_LIT> && <STR_LIT> ) ; abort ( ) ; } DebugLoc DL = DebugLoc :: getUnknownLoc ( ) ; MachineInstrBuilder MIB = BuildMI ( MF , DL , get ( Opc ) ) . addReg ( SrcReg , getKillRegState ( isKill ) ) ; for ( unsigned i = <NUM_LIT> , e = Addr . size ( ) ; i != e ; ++ i ) MIB . addOperand ( Addr [ i ] ) ; NewMIs . push_back ( MIB ) ; }


<s> opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ;


<s> void <ISA_LIT>InstrInfo :: storeRegToStackSlot ( MachineBasicBlock & MBB , MachineBasicBlock :: iterator MI , unsigned SrcReg , bool isKill , int FrameIdx , const TargetRegisterClass * RC ) const { unsigned opc ; bool isValidFrameIdx = ( FrameIdx < <ISA_LIT>FrameInfo :: maxFrameOffset ( ) ) ; if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) {

opc = ( isValidFrameIdx ) ? <STR_LIT> : <STR_LIT> ;


<s> } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ) ? <STR_LIT> : <STR_LIT> ; } else { llvm_unreachable ( <STR_LIT> ) ; } DebugLoc DL = DebugLoc :: getUnknownLoc ( ) ;

if ( MI != MBB . end ( ) ) DL = MI -> getDebugLoc ( ) ;


<s> } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ) ? <STR_LIT> : <STR_LIT> ; } else { llvm_unreachable ( <STR_LIT> ) ; }

DebugLoc DL = DebugLoc :: getUnknownLoc ( ) ;


<s> if ( SecondLastInst && I != MBB . begin ( ) && isUnpredicatedTerminator ( -- I ) ) return true ; if ( isCondBranch ( SecondLastInst ) && isUncondBranch ( LastInst ) ) { TBB = SecondLastInst -> getOperand ( <NUM_LIT> ) . getMBB ( ) ; DEBUG ( errs ( ) << <STR_LIT> ) ; DEBUG ( SecondLastInst -> dump ( ) ) ; Cond . push_back ( MachineOperand :: CreateImm ( SecondLastInst -> getOpcode ( ) ) ) ; Cond . push_back ( SecondLastInst -> getOperand ( <NUM_LIT> ) ) ; FBB = LastInst -> getOperand ( <NUM_LIT> ) . getMBB ( ) ; return false ; } if ( isUncondBranch ( SecondLastInst ) && isUncondBranch ( LastInst ) ) { TBB = SecondLastInst -> getOperand ( <NUM_LIT> ) . getMBB ( ) ; I = LastInst ; if ( AllowModify ) I -> eraseFromParent ( ) ;


<s> assert ( ( Cond . size ( ) == <NUM_LIT> || Cond . size ( ) == <NUM_LIT> ) && <STR_LIT> ) ; if ( FBB == <NUM_LIT> ) { if ( Cond . empty ( ) ) { MachineInstrBuilder MIB = BuildMI ( & MBB , dl , get ( <STR_LIT> ) ) ; MIB . addMBB ( TBB ) ; DEBUG ( errs ( ) << <STR_LIT> ) ; DEBUG ( ( * MIB ) . dump ( ) ) ; } else { MachineInstrBuilder MIB = BuildMI ( & MBB , dl , get ( Cond [ <NUM_LIT> ] . getImm ( ) ) ) ; MIB . addReg ( Cond [ <NUM_LIT> ] . getReg ( ) ) . addMBB ( TBB ) ; DEBUG ( errs ( ) << <STR_LIT> ) ; DEBUG ( ( * MIB ) . dump ( ) ) ; } return <NUM_LIT> ; } else { MachineInstrBuilder MIB = BuildMI ( & MBB , dl , get ( Cond [ <NUM_LIT> ] . getImm ( ) ) ) ; MachineInstrBuilder MIB2 = BuildMI ( & MBB , dl , get ( <STR_LIT> ) ) ; MIB . addReg ( Cond [ <NUM_LIT> ] . getReg ( ) ) . addMBB ( TBB ) ; MIB2 . addMBB ( FBB ) ; DEBUG ( errs ( ) << <STR_LIT> ) ; DEBUG ( ( * MIB ) . dump ( ) ) ; DEBUG ( errs ( ) << <STR_LIT> ) ;


<s> -- I ; if ( ! ( isCondBranch ( I ) || isUncondBranch ( I ) ) ) return <NUM_LIT> ; DEBUG ( errs ( ) << <STR_LIT> ) ; DEBUG ( I -> dump ( ) ) ; I -> eraseFromParent ( ) ;


<s> unsigned OutReg = MI -> getOperand ( <NUM_LIT> ) . getReg ( ) ; bool isDead = MI -> getOperand ( <NUM_LIT> ) . isDead ( ) ; MachineInstrBuilder MIB = BuildMI ( MF , MI -> getDebugLoc ( ) , get ( Opc ) ) ; MIB . addReg ( OutReg , true , false , false , isDead ) ; Opc = ( FrameIndex < <ISA_LIT>FrameInfo :: maxFrameOffset ( ) ) ? <STR_LIT> : <STR_LIT> ; NewMI = addFrameReference ( MIB , FrameIndex ) ; break ; } }


<s> case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : if ( OpNum == <NUM_LIT> ) { unsigned InReg = MI -> getOperand ( <NUM_LIT> ) . getReg ( ) ; bool isKill = MI -> getOperand ( <NUM_LIT> ) . isKill ( ) ; if ( FrameIndex < <ISA_LIT>FrameInfo :: maxFrameOffset ( ) ) { MachineInstrBuilder MIB = BuildMI ( MF , MI -> getDebugLoc ( ) , get ( <STR_LIT> ) ) ; MIB . addReg ( InReg , false , false , isKill ) ; NewMI = addFrameReference ( MIB , FrameIndex ) ; } } else { unsigned OutReg = MI -> getOperand ( <NUM_LIT> ) . getReg ( ) ; bool isDead = MI -> getOperand ( <NUM_LIT> ) . isDead ( ) ; MachineInstrBuilder MIB = BuildMI ( MF , MI -> getDebugLoc ( ) , get ( Opc ) ) ; MIB . addReg ( OutReg , true , false , false , isDead ) ;

Opc = ( FrameIndex < <ISA_LIT>FrameInfo :: maxFrameOffset ( ) ) ? <STR_LIT> : <STR_LIT> ;


<s> bool isValidFrameIdx = ( FrameIdx < <ISA_LIT>FrameInfo :: maxFrameOffset ( ) ) ; if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ) ? <STR_LIT> : <STR_LIT> ; } else { assert ( <NUM_LIT> && <STR_LIT> ) ; abort ( ) ; } DebugLoc DL = DebugLoc :: getUnknownLoc ( ) ;


<s> } DebugLoc DL = DebugLoc :: getUnknownLoc ( ) ; MachineInstrBuilder MIB = BuildMI ( MF , DL , get ( Opc ) ) . addReg ( SrcReg , false , false , isKill ) ;

for ( unsigned i = <NUM_LIT> , e = Addr . size ( ) ; i != e ; ++ i ) MIB . addOperand ( Addr [ i ] ) ;


<s> DebugLoc DL = DebugLoc :: getUnknownLoc ( ) ; MachineInstrBuilder MIB = BuildMI ( MF , DL , get ( Opc ) ) . addReg ( SrcReg , false , false , isKill ) ;


<s> } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ) ? <STR_LIT> : <STR_LIT> ; } else { assert ( <NUM_LIT> && <STR_LIT> ) ; abort ( ) ; } DebugLoc DL = DebugLoc :: getUnknownLoc ( ) ; if ( MI != MBB . end ( ) ) DL = MI -> getDebugLoc ( ) ;

addFrameReference ( BuildMI ( MBB , MI , DL , get ( opc ) ) . addReg ( SrcReg , false , false , isKill ) , FrameIdx ) ;


<s> opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ) ? <STR_LIT> : <STR_LIT> ; } else { assert ( <NUM_LIT> && <STR_LIT> ) ; abort ( ) ; } DebugLoc DL = DebugLoc :: getUnknownLoc ( ) ; if ( MI != MBB . end ( ) ) DL = MI -> getDebugLoc ( ) ; addFrameReference ( BuildMI ( MBB , MI , DL , get ( opc ) ) . addReg ( SrcReg , false , false , isKill ) , FrameIdx ) ;


<s> if ( isUncondBranch ( LastInst ) ) { TBB = LastInst -> getOperand ( <NUM_LIT> ) . getMBB ( ) ; return false ; } else if ( isCondBranch ( LastInst ) ) { TBB = LastInst -> getOperand ( <NUM_LIT> ) . getMBB ( ) ; DEBUG ( errs ( ) << <STR_LIT> ) ; DEBUG ( LastInst -> dump ( ) ) ; Cond . push_back ( MachineOperand :: CreateImm ( LastInst -> getOpcode ( ) ) ) ; Cond . push_back ( LastInst -> getOperand ( <NUM_LIT> ) ) ; return false ; } return true ; } MachineInstr * SecondLastInst = I ; if ( SecondLastInst && I != MBB . begin ( ) && isUnpredicatedTerminator ( -- I ) ) return true ; if ( isCondBranch ( SecondLastInst ) && isUncondBranch ( LastInst ) ) { TBB = SecondLastInst -> getOperand ( <NUM_LIT> ) . getMBB ( ) ; DEBUG ( errs ( ) << <STR_LIT> ) ; DEBUG ( SecondLastInst -> dump ( ) ) ; Cond . push_back ( MachineOperand :: CreateImm ( SecondLastInst -> getOpcode ( ) ) ) ; Cond . push_back ( SecondLastInst -> getOperand ( <NUM_LIT> ) ) ; FBB = LastInst -> getOperand ( <NUM_LIT> ) . getMBB ( ) ; return false ;


<s> return false ; } else if ( isCondBranch ( LastInst ) ) { TBB = LastInst -> getOperand ( <NUM_LIT> ) . getMBB ( ) ; DEBUG ( errs ( ) << <STR_LIT> ) ; DEBUG ( LastInst -> dump ( ) ) ; Cond . push_back ( MachineOperand :: CreateImm ( LastInst -> getOpcode ( ) ) ) ; Cond . push_back ( LastInst -> getOperand ( <NUM_LIT> ) ) ; return false ; } return true ; } MachineInstr * SecondLastInst = I ; if ( SecondLastInst && I != MBB . begin ( ) && isUnpredicatedTerminator ( -- I ) ) return true ; if ( isCondBranch ( SecondLastInst ) && isUncondBranch ( LastInst ) ) { TBB = SecondLastInst -> getOperand ( <NUM_LIT> ) . getMBB ( ) ; DEBUG ( errs ( ) << <STR_LIT> ) ; DEBUG ( SecondLastInst -> dump ( ) ) ; Cond . push_back ( MachineOperand :: CreateImm ( SecondLastInst -> getOpcode ( ) ) ) ; Cond . push_back ( SecondLastInst -> getOperand ( <NUM_LIT> ) ) ; FBB = LastInst -> getOperand ( <NUM_LIT> ) . getMBB ( ) ; return false ; } if ( isUncondBranch ( SecondLastInst ) && isUncondBranch ( LastInst ) ) { TBB = SecondLastInst -> getOperand ( <NUM_LIT> ) . getMBB ( ) ; I = LastInst ; if ( AllowModify ) I -> eraseFromParent ( ) ; return false ; } return true ;


<s> unsigned Opc = MI -> getOpcode ( ) ; switch ( Opc ) { case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> :


<s> } else if ( DestRC == <STR_LIT> ) { BuildMI ( MBB , MI , DL , get ( <STR_LIT> ) , DestReg ) . addReg ( SrcReg ) ; } else if ( DestRC == <STR_LIT> ) { BuildMI ( MBB , MI , DL , get ( <STR_LIT> ) , DestReg ) . addReg ( SrcReg ) ; } else if ( DestRC == <STR_LIT> ) { BuildMI ( MBB , MI , DL , get ( <STR_LIT> ) , DestReg ) . addReg ( SrcReg ) ; } else if ( DestRC == <STR_LIT> ) { BuildMI ( MBB , MI , DL , get ( <STR_LIT> ) , DestReg ) . addReg ( SrcReg ) ; } else if ( DestRC == <STR_LIT> ) { BuildMI ( MBB , MI , DL , get ( <STR_LIT> ) , DestReg ) . addReg ( SrcReg ) ; } else if ( DestRC == <STR_LIT> ) { BuildMI ( MBB , MI , DL , get ( <STR_LIT> ) , DestReg ) . addReg ( SrcReg ) ; } else {


<s> case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : if ( OpNum == <NUM_LIT> ) { unsigned InReg = MI -> getOperand ( <NUM_LIT> ) . getReg ( ) ; bool isKill = MI -> getOperand ( <NUM_LIT> ) . isKill ( ) ; bool isUndef = MI -> getOperand ( <NUM_LIT> ) . isUndef ( ) ; if ( FrameIndex < <ISA_LIT>FrameInfo :: maxFrameOffset ( ) ) { MachineInstrBuilder MIB = BuildMI ( MF , MI -> getDebugLoc ( ) , get ( <STR_LIT> ) ) ; MIB . addReg ( InReg , getKillRegState ( isKill ) | getUndefRegState ( isUndef ) ) ;


<s> unsigned InReg = MI -> getOperand ( <NUM_LIT> ) . getReg ( ) ; bool isKill = MI -> getOperand ( <NUM_LIT> ) . isKill ( ) ; bool isUndef = MI -> getOperand ( <NUM_LIT> ) . isUndef ( ) ; if ( FrameIndex < <ISA_LIT>FrameInfo :: maxFrameOffset ( ) ) { MachineInstrBuilder MIB = BuildMI ( MF , MI -> getDebugLoc ( ) , get ( <STR_LIT> ) ) ; MIB . addReg ( InReg , getKillRegState ( isKill ) | getUndefRegState ( isUndef ) ) ; NewMI = addFrameReference ( MIB , FrameIndex ) ; } } else { unsigned OutReg = MI -> getOperand ( <NUM_LIT> ) . getReg ( ) ; bool isDead = MI -> getOperand ( <NUM_LIT> ) . isDead ( ) ; bool isUndef = MI -> getOperand ( <NUM_LIT> ) . isUndef ( ) ; MachineInstrBuilder MIB = BuildMI ( MF , MI -> getDebugLoc ( ) , get ( Opc ) ) ; MIB . addReg ( OutReg , RegState :: Define | getDeadRegState ( isDead ) | getUndefRegState ( isUndef ) ) ; Opc = ( FrameIndex < <ISA_LIT>FrameInfo :: maxFrameOffset ( ) ) ? <STR_LIT> : <STR_LIT> ; NewMI = addFrameReference ( MIB , FrameIndex ) ; break ; } } return NewMI ;


<s> } return <NUM_LIT> ; } else { MachineInstrBuilder MIB = BuildMI ( & MBB , dl , get ( Cond [ <NUM_LIT> ] . getImm ( ) ) ) ; MachineInstrBuilder MIB2 = BuildMI ( & MBB , dl , get ( <STR_LIT> ) ) ; MIB . addReg ( Cond [ <NUM_LIT> ] . getReg ( ) ) . addMBB ( TBB ) ; MIB2 . addMBB ( FBB ) ; DEBUG ( errs ( ) << <STR_LIT> ) ; DEBUG ( ( * MIB ) . dump ( ) ) ;


<s> return ( opc == <STR_LIT> || opc == <STR_LIT> || opc == <STR_LIT> || opc == <STR_LIT> || opc == <STR_LIT> || opc == <STR_LIT> || opc == <STR_LIT> || opc == <STR_LIT> ) ;


<s> case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : { const MachineOperand MOp1 = MI -> getOperand ( <NUM_LIT> ) ; const MachineOperand MOp2 = MI -> getOperand ( <NUM_LIT> ) ; if ( MOp1 . isImm ( ) && MOp2 . isFI ( ) ) {


<s> const MachineOperand MOp1 = MI -> getOperand ( <NUM_LIT> ) ; const MachineOperand MOp2 = MI -> getOperand ( <NUM_LIT> ) ; if ( MOp1 . isImm ( ) && MOp2 . isFI ( ) ) { FrameIndex = MOp2 . getIndex ( ) ; return MI -> getOperand ( <NUM_LIT> ) . getReg ( ) ;


<s> case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : { assert ( MI . getNumOperands ( ) == <NUM_LIT> && MI . getOperand ( <NUM_LIT> ) . isReg ( ) && MI . getOperand ( <NUM_LIT> ) . isReg ( ) && <STR_LIT> ) ; if ( MI . getOperand ( <NUM_LIT> ) . getReg ( ) == MI . getOperand ( <NUM_LIT> ) . getReg ( ) ) { sourceReg = MI . getOperand ( <NUM_LIT> ) . getReg ( ) ; destReg = MI . getOperand ( <NUM_LIT> ) . getReg ( ) ; return true ; } break ; } case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : assert ( MI . getNumOperands ( ) == <NUM_LIT> && MI . getOperand ( <NUM_LIT> ) . isReg ( ) && MI . getOperand ( <NUM_LIT> ) . isReg ( ) && MI . getOperand ( <NUM_LIT> ) . isReg ( ) && <STR_LIT> ) ; if ( MI . getOperand ( <NUM_LIT> ) . getReg ( ) == MI . getOperand ( <NUM_LIT> ) . getReg ( ) ) {


<s> case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : { const MachineOperand MOp1 = MI -> getOperand ( <NUM_LIT> ) ; const MachineOperand MOp2 = MI -> getOperand ( <NUM_LIT> ) ; if ( MOp1 . isImm ( ) && MOp2 . isFI ( ) ) { FrameIndex = MOp2 . getIndex ( ) ; return MI -> getOperand ( <NUM_LIT> ) . getReg ( ) ;


<s> inline bool isUncondBranch ( const MachineInstr * I ) {


<s> unsigned opc = I -> getOpcode ( ) ; return ( opc == <STR_LIT> || opc == <STR_LIT> || opc == <STR_LIT> ) ;


<s> opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ;


<s> unsigned <ISA_LIT>InstrInfo :: RemoveBranch ( MachineBasicBlock & MBB ) const { MachineBasicBlock :: iterator I = MBB . end ( ) ; if ( I == MBB . begin ( ) ) return <NUM_LIT> ; -- I ; while ( I -> isDebugValue ( ) ) { if ( I == MBB . begin ( ) ) return <NUM_LIT> ; -- I ; } if ( ! isCondBranch ( I ) && ! isUncondBranch ( I ) ) return <NUM_LIT> ; DEBUG ( errs ( ) << <STR_LIT> ) ; DEBUG ( I -> dump ( ) ) ; I -> eraseFromParent ( ) ; I = MBB . end ( ) ; if ( I == MBB . begin ( ) ) return <NUM_LIT> ; -- I ; if ( ! ( isCondBranch ( I ) || isUncondBranch ( I ) ) ) return <NUM_LIT> ; DEBUG ( errs ( ) << <STR_LIT> ) ;


<s> I -> eraseFromParent ( ) ; I = MBB . end ( ) ; if ( I == MBB . begin ( ) ) return <NUM_LIT> ; -- I ; if ( ! ( isCondBranch ( I ) || isUncondBranch ( I ) ) ) return <NUM_LIT> ;


<s> } ; unsigned Opc = unsigned ( Cond [ <NUM_LIT> ] . getImm ( ) ) ; for ( int i = sizeof ( revconds ) / sizeof ( revconds [ <NUM_LIT> ] ) - <NUM_LIT> ; i >= <NUM_LIT> ; -- i ) { if ( revconds [ i ] . Opc == Opc ) { Cond [ <NUM_LIT> ] . setImm ( revconds [ i ] . RevCondOpc ) ;


<s> <ISA_LIT>InstrInfo :: <ISA_LIT>InstrInfo ( <ISA_LIT>TargetMachine & tm ) : TargetInstrInfoImpl ( <ISA_LIT>Insts , sizeof ( <ISA_LIT>Insts ) / sizeof ( <ISA_LIT>Insts [ <NUM_LIT> ] ) ) , TM ( tm ) , RI ( * TM . getSubtargetImpl ( ) , * this ) {


<s> opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ? <STR_LIT> : <STR_LIT> ) ; } else if ( RC == <STR_LIT> ) { opc = ( isValidFrameIdx ) ? <STR_LIT> : <STR_LIT> ; } else { llvm_unreachable ( <STR_LIT> ) ; } DebugLoc DL ;


<s> return CurDAG -> getTargetConstant ( <STR_LIT> . getID ( ) , <STR_LIT> ) ; break ; case <STR_LIT> : return CurDAG -> getTargetConstant ( <STR_LIT> . getID ( ) , <STR_LIT> ) ; break ; case <STR_LIT> : return CurDAG -> getTargetConstant ( <STR_LIT> . getID ( ) , <STR_LIT> ) ; break ; case <STR_LIT> : return CurDAG -> getTargetConstant ( <STR_LIT> . getID ( ) , <STR_LIT> ) ; break ; case <STR_LIT> : return CurDAG -> getTargetConstant ( <STR_LIT> . getID ( ) , <STR_LIT> ) ; break ; case <STR_LIT> : return CurDAG -> getTargetConstant ( <STR_LIT> . getID ( ) , <STR_LIT> ) ; break ; case <STR_LIT> : case <STR_LIT> : case <STR_LIT> :


<s> SDValue Zero = CurDAG -> getTargetConstant ( <NUM_LIT> , OffsVT ) ; int64_t val ; switch ( N . getOpcode ( ) ) { case <STR_LIT> : val = dyn_cast < ConstantSDNode > ( N . getNode ( ) ) -> getSExtValue ( ) ; Base = CurDAG -> getTargetConstant ( val , <STR_LIT> ) ; Index = Zero ; return true ; break ; case <STR_LIT> : case <STR_LIT> : report_fatal_error ( <STR_LIT> ) ; case <STR_LIT> : case <STR_LIT> :


<s> } std :: vector < Constant * > CV ; for ( size_t i = <NUM_LIT> ; i < bvNode -> getNumOperands ( ) ; ++ i ) { ConstantSDNode * V = cast < ConstantSDNode > ( bvNode -> getOperand ( i ) ) ; CV . push_back ( const_cast < ConstantInt * > ( V -> getConstantIntValue ( ) ) ) ; } const Constant * CP = ConstantVector :: get ( CV ) ; SDValue CPIdx = CurDAG -> getConstantPool ( CP , <ISA_LIT>tli . getPointerTy ( ) ) ; unsigned Alignment = cast < ConstantPoolSDNode > ( CPIdx ) -> getAlignment ( ) ; SDValue CGPoolOffset = <STR_LIT> ( CPIdx , * CurDAG , TM ) ; HandleSDNode Dummy ( CurDAG -> getLoad ( vecVT , dl , CurDAG -> getEntryNode ( ) , CGPoolOffset , MachinePointerInfo :: getConstantPool ( ) , false , false , Alignment ) ) ; CurDAG -> ReplaceAllUsesWith ( SDValue ( bvNode , <NUM_LIT> ) , Dummy . getValue ( ) ) ; if ( SDNode * N = SelectCode ( Dummy . getValue ( ) . getNode ( ) ) ) return N ; return Dummy . getValue ( ) . getNode ( ) ;


<s> EVT vecVT = bvNode -> getValueType ( <NUM_LIT> ) ; DebugLoc dl = bvNode -> getDebugLoc ( ) ; if ( ( ( vecVT == <STR_LIT> ) && ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) ) || ( ( vecVT == <STR_LIT> ) && ( ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) || ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) || ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) || ( <STR_LIT> ( bvNode , * CurDAG ) . getNode ( ) != <NUM_LIT> ) ) ) || ( ( vecVT == <STR_LIT> ) && ( ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) || ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) || ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) ) ) ) { HandleSDNode Dummy ( SDValue ( bvNode , <NUM_LIT> ) ) ; if ( SDNode * N = Select ( bvNode ) ) return N ; return Dummy . getValue ( ) . getNode ( ) ; } std :: vector < Constant * > CV ; for ( size_t i = <NUM_LIT> ; i < bvNode -> getNumOperands ( ) ; ++ i ) { ConstantSDNode * V = cast < ConstantSDNode > ( bvNode -> getOperand ( i ) ) ; CV . push_back ( const_cast < ConstantInt * > ( V -> getConstantIntValue ( ) ) ) ;


<s> assert ( II && <STR_LIT> ) ; return new <ISA_LIT>HazardRecognizer ( * II ) ;


<s> ConstantSDNode * CN = dyn_cast < ConstantSDNode > ( Op0 ) ; int32_t offset = int32_t ( CN -> getSExtValue ( ) ) ; if ( Op1 . getOpcode ( ) == <STR_LIT> ) { FrameIndexSDNode * FIN = dyn_cast < FrameIndexSDNode > ( Op1 ) ; int FI = int ( FIN -> getIndex ( ) ) ; DEBUG ( errs ( ) << <STR_LIT> << offset << <STR_LIT> << FI << <STR_LIT> ) ; if ( <ISA_LIT>FrameInfo :: FItoStackOffset ( FI ) < maxOffset ) { Base = CurDAG -> getTargetConstant ( offset , PtrTy ) ; Index = CurDAG -> getTargetFrameIndex ( FI , PtrTy ) ; return true ; } } else if ( offset > minOffset && offset < maxOffset ) { Base = CurDAG -> getTargetConstant ( offset , PtrTy ) ; Index = Op1 ; return true ; } } } else if ( Opc == <STR_LIT> ) { const SDValue Op0 = N . getOperand ( <NUM_LIT> ) ; const SDValue Op1 = N . getOperand ( <NUM_LIT> ) ; if ( Op0 . getOpcode ( ) == <STR_LIT> && Op1 . getOpcode ( ) == <STR_LIT> ) { Base = CurDAG -> getTargetConstant ( <NUM_LIT> , PtrTy ) ; Index = N ; return true ; } else if ( isa < ConstantSDNode > ( Op0 ) || isa < ConstantSDNode > ( Op1 ) ) { int32_t offset = <NUM_LIT> ; SDValue idxOp ; if ( isa < ConstantSDNode > ( Op1 ) ) { ConstantSDNode * CN = cast < ConstantSDNode > ( Op1 ) ; offset = int32_t ( CN -> getSExtValue ( ) ) ; idxOp = Op0 ; } else if ( isa < ConstantSDNode > ( Op0 ) ) { ConstantSDNode * CN = cast < ConstantSDNode > ( Op0 ) ; offset = int32_t ( CN -> getSExtValue ( ) ) ; idxOp = Op1 ; } if ( offset >= minOffset && offset <= maxOffset ) { Base = CurDAG -> getTargetConstant ( offset , PtrTy ) ; Index = idxOp ; return true ; } } } else if ( Opc == <STR_LIT> ) { Base = CurDAG -> getTargetConstant ( <NUM_LIT> , N . getValueType ( ) ) ; Index = N ; return true ; } else if ( Opc == <STR_LIT> ) { Base = CurDAG -> getTargetConstant ( <NUM_LIT> , N . getValueType ( ) ) ; Index = N ; return true ; } else if ( Opc == <STR_LIT> || Opc == <STR_LIT> ) { unsigned OpOpc = Op -> getOpcode ( ) ; if ( OpOpc == <STR_LIT> || OpOpc == <STR_LIT> ) { SDValue Addr , Offs ; if ( Opc == <STR_LIT> ) Addr = N . getOperand ( <NUM_LIT> ) ;


<s> DEBUG ( errs ( ) << <STR_LIT> << offset << <STR_LIT> << FI << <STR_LIT> ) ; if ( <ISA_LIT>FrameInfo :: FItoStackOffset ( FI ) < maxOffset ) { Base = CurDAG -> getTargetConstant ( offset , PtrTy ) ; Index = CurDAG -> getTargetFrameIndex ( FI , PtrTy ) ; return true ; } } else if ( offset > minOffset && offset < maxOffset ) { Base = CurDAG -> getTargetConstant ( offset , PtrTy ) ; Index = Op0 ; return true ; } } else if ( Op0 . getOpcode ( ) == <STR_LIT> || Op0 . getOpcode ( ) == <STR_LIT> ) { ConstantSDNode * CN = dyn_cast < ConstantSDNode > ( Op0 ) ; int32_t offset = int32_t ( CN -> getSExtValue ( ) ) ; if ( Op1 . getOpcode ( ) == <STR_LIT> ) { FrameIndexSDNode * FIN = dyn_cast < FrameIndexSDNode > ( Op1 ) ; int FI = int ( FIN -> getIndex ( ) ) ; DEBUG ( errs ( ) << <STR_LIT> << offset << <STR_LIT> << FI << <STR_LIT> ) ; if ( <ISA_LIT>FrameInfo :: FItoStackOffset ( FI ) < maxOffset ) { Base = CurDAG -> getTargetConstant ( offset , PtrTy ) ; Index = CurDAG -> getTargetFrameIndex ( FI , PtrTy ) ; return true ; } } else if ( offset > minOffset && offset < maxOffset ) { Base = CurDAG -> getTargetConstant ( offset , PtrTy ) ; Index = Op1 ; return true ; } } } else if ( Opc == <STR_LIT> ) { const SDValue Op0 = N . getOperand ( <NUM_LIT> ) ; const SDValue Op1 = N . getOperand ( <NUM_LIT> ) ; if ( Op0 . getOpcode ( ) == <STR_LIT> && Op1 . getOpcode ( ) == <STR_LIT> ) { Base = CurDAG -> getTargetConstant ( <NUM_LIT> , PtrTy ) ; Index = N ; return true ; } else if ( isa < ConstantSDNode > ( Op0 ) || isa < ConstantSDNode > ( Op1 ) ) { int32_t offset = <NUM_LIT> ; SDValue idxOp ; if ( isa < ConstantSDNode > ( Op1 ) ) { ConstantSDNode * CN = cast < ConstantSDNode > ( Op1 ) ; offset = int32_t ( CN -> getSExtValue ( ) ) ; idxOp = Op0 ; } else if ( isa < ConstantSDNode > ( Op0 ) ) { ConstantSDNode * CN = cast < ConstantSDNode > ( Op0 ) ; offset = int32_t ( CN -> getSExtValue ( ) ) ;


<s> std :: vector < Constant * > CV ; for ( size_t i = <NUM_LIT> ; i < bvNode -> getNumOperands ( ) ; ++ i ) { ConstantSDNode * V = dyn_cast < ConstantSDNode > ( bvNode -> getOperand ( i ) ) ; CV . push_back ( const_cast < ConstantInt * > ( V -> getConstantIntValue ( ) ) ) ; } const Constant * CP = ConstantVector :: get ( CV ) ; SDValue CPIdx = CurDAG -> getConstantPool ( CP , <ISA_LIT>tli . getPointerTy ( ) ) ; unsigned Alignment = cast < ConstantPoolSDNode > ( CPIdx ) -> getAlignment ( ) ; SDValue CGPoolOffset = <STR_LIT> ( CPIdx , * CurDAG , <ISA_LIT>tli . get<ISA_LIT>TargetMachine ( ) ) ; HandleSDNode Dummy ( CurDAG -> getLoad ( vecVT , dl , CurDAG -> getEntryNode ( ) , CGPoolOffset , PseudoSourceValue :: getConstantPool ( ) , <NUM_LIT> , false , false , Alignment ) ) ; CurDAG -> ReplaceAllUsesWith ( SDValue ( bvNode , <NUM_LIT> ) , Dummy . getValue ( ) ) ;

if ( SDNode * N = SelectCode ( Dummy . getValue ( ) . getNode ( ) ) ) return N ;


<s> inline SDValue getI64Imm ( uint64_t Imm ) {

return CurDAG -> getTargetConstant ( Imm , <STR_LIT> ) ;


<s> break ; } } if ( retval == <NUM_LIT> ) { report_fatal_error ( <STR_LIT> <STR_LIT> + Twine ( VT . getEVTString ( ) ) ) ; } return retval ;


<s> bool isHighLow ( const SDValue & Op ) { return ( Op . getOpcode ( ) == <STR_LIT> && ( ( Op . getOperand ( <NUM_LIT> ) . getOpcode ( ) == <STR_LIT> && Op . getOperand ( <NUM_LIT> ) . getOpcode ( ) == <STR_LIT> ) || ( Op . getOperand ( <NUM_LIT> ) . getOpcode ( ) == <STR_LIT> && Op . getOperand ( <NUM_LIT> ) . getOpcode ( ) == <STR_LIT> ) ) ) ;


<s> ConstantSDNode * CN = dyn_cast < ConstantSDNode > ( N ) ;

return ( CN != <NUM_LIT> && isI16IntS10Immediate ( CN ) ) ;


<s> bool isI16IntU10Immediate ( SDNode * N ) {

return ( N -> getOpcode ( ) == <STR_LIT> && isI16IntU10Immediate ( cast < ConstantSDNode > ( N ) ) ) ;


<s> bool isIntS16Immediate ( SDNode * N , short & Imm ) {

return ( N -> getOpcode ( ) == <STR_LIT> && isIntS16Immediate ( cast < ConstantSDNode > ( N ) , Imm ) ) ;


<s> return ( N -> getOpcode ( ) == <STR_LIT> && isIntS16Immediate ( cast < ConstantSDNode > ( N ) , Imm ) ) ;


<s> case <STR_LIT> : case <STR_LIT> : report_fatal_error ( <STR_LIT> <STR_LIT> ) ; case <STR_LIT> : if ( N . hasOneUse ( ) ) { SDValue Op0 = N . getOperand ( <NUM_LIT> ) ; switch ( Op0 . getOpcode ( ) ) { case <STR_LIT> : case <STR_LIT> : Base = Op0 ; Index = Zero ; return true ; case <STR_LIT> : { GlobalAddressSDNode * GSDN = cast < GlobalAddressSDNode > ( Op0 ) ; const GlobalValue * GV = GSDN -> getGlobal ( ) ; if ( GV -> getAlignment ( ) == <NUM_LIT> ) { Base = Op0 ; Index = Zero ;


<s> bool <ISA_LIT>DAGToDAGISel :: SelectDFormAddr ( SDNode * Op , SDValue N , SDValue & Base , SDValue & Index ) { return DFormAddressPredicate ( Op , N , Base , Index , <ISA_LIT>FrameInfo :: minFrameOffset ( ) , <ISA_LIT>FrameInfo :: maxFrameOffset ( ) ) ;


<s> EVT OpVecVT = EVT :: getVectorVT ( * CurDAG -> getContext ( ) , OpVT , <NUM_LIT> ) ; SDValue i64vec = <STR_LIT> ( OpVecVT , * CurDAG , Value64 , dl ) ; if ( i64vec . getOpcode ( ) == <STR_LIT> ) { SDValue Op0 = i64vec . getOperand ( <NUM_LIT> ) ; ReplaceUses ( i64vec , Op0 ) ; return CurDAG -> getMachineNode ( <STR_LIT> , dl , OpVT , SDValue ( emitBuildVector ( Op0 . getNode ( ) ) , <NUM_LIT> ) ) ; } else if ( i64vec . getOpcode ( ) == <STR_LIT> ) { SDValue lhs = i64vec . getOperand ( <NUM_LIT> ) ; SDValue rhs = i64vec . getOperand ( <NUM_LIT> ) ; SDValue shufmask = i64vec . getOperand ( <NUM_LIT> ) ; if ( lhs . getOpcode ( ) == <STR_LIT> ) { ReplaceUses ( lhs , lhs . getOperand ( <NUM_LIT> ) ) ; lhs = lhs . getOperand ( <NUM_LIT> ) ; } SDNode * lhsNode = ( lhs . getNode ( ) -> isMachineOpcode ( ) ? lhs . getNode ( ) : emitBuildVector ( lhs . getNode ( ) ) ) ; if ( rhs . getOpcode ( ) == <STR_LIT> ) { ReplaceUses ( rhs , rhs . getOperand ( <NUM_LIT> ) ) ; rhs = rhs . getOperand ( <NUM_LIT> ) ; } SDNode * rhsNode = ( rhs . getNode ( ) -> isMachineOpcode ( ) ? rhs . getNode ( ) : emitBuildVector ( rhs . getNode ( ) ) ) ; if ( shufmask . getOpcode ( ) == <STR_LIT> ) { ReplaceUses ( shufmask , shufmask . getOperand ( <NUM_LIT> ) ) ; shufmask = shufmask . getOperand ( <NUM_LIT> ) ; } SDNode * shufMaskNode = ( shufmask . getNode ( ) -> isMachineOpcode ( ) ? shufmask . getNode ( ) : emitBuildVector ( shufmask . getNode ( ) ) ) ; SDValue shufNode = CurDAG -> getNode ( <STR_LIT> , dl , OpVecVT , SDValue ( lhsNode , <NUM_LIT> ) , SDValue ( rhsNode , <NUM_LIT> ) , SDValue ( shufMaskNode , <NUM_LIT> ) ) ; HandleSDNode Dummy ( shufNode ) ; SDNode * SN = SelectCode ( Dummy . getValue ( ) . getNode ( ) ) ;

if ( SN == <NUM_LIT> ) SN = Dummy . getValue ( ) . getNode ( ) ;


<s> EVT VecVT = EVT :: getVectorVT ( * CurDAG -> getContext ( ) , OpVT , ( <NUM_LIT> / OpVT . getSizeInBits ( ) ) ) ; SDValue ShiftAmt = N -> getOperand ( <NUM_LIT> ) ; EVT ShiftAmtVT = ShiftAmt . getValueType ( ) ; SDNode * VecOp0 , * SelMask , * ZeroFill , * Shift = <NUM_LIT> ; SDValue SelMaskVal ; DebugLoc dl = N -> getDebugLoc ( ) ; VecOp0 = CurDAG -> getMachineNode ( <STR_LIT> , dl , VecVT , Op0 ) ; SelMaskVal = CurDAG -> getTargetConstant ( <NUM_LIT> , <STR_LIT> ) ; SelMask = CurDAG -> getMachineNode ( <STR_LIT> , dl , VecVT , SelMaskVal ) ; ZeroFill = CurDAG -> getMachineNode ( <STR_LIT> , dl , VecVT , CurDAG -> getTargetConstant ( <NUM_LIT> , OpVT ) ) ; VecOp0 = CurDAG -> getMachineNode ( <STR_LIT> , dl , VecVT , SDValue ( ZeroFill , <NUM_LIT> ) , SDValue ( VecOp0 , <NUM_LIT> ) , SDValue ( SelMask , <NUM_LIT> ) ) ; if ( ConstantSDNode * CN = dyn_cast < ConstantSDNode > ( ShiftAmt ) ) { unsigned bytes = unsigned ( CN -> getZExtValue ( ) ) >> <NUM_LIT> ; unsigned bits = unsigned ( CN -> getZExtValue ( ) ) & <NUM_LIT> ; if ( bytes > <NUM_LIT> ) { Shift = CurDAG -> getMachineNode ( <STR_LIT> , dl , VecVT , SDValue ( VecOp0 , <NUM_LIT> ) , CurDAG -> getTargetConstant ( bytes , ShiftAmtVT ) ) ; }


<s> SDNode * SignRot = CurDAG -> getMachineNode ( <STR_LIT> , dl , <STR_LIT> , SDValue ( VecOp0 , <NUM_LIT> ) , SignRotAmt ) ; SDNode * UpperHalfSign = CurDAG -> getMachineNode ( <STR_LIT> , dl , <STR_LIT> , SDValue ( SignRot , <NUM_LIT> ) ) ; SDNode * UpperHalfSignMask = CurDAG -> getMachineNode ( <STR_LIT> , dl , VecVT , SDValue ( UpperHalfSign , <NUM_LIT> ) ) ; SDNode * UpperLowerMask = CurDAG -> getMachineNode ( <STR_LIT> , dl , VecVT , CurDAG -> getTargetConstant ( <NUM_LIT> , <STR_LIT> ) ) ; SDNode * UpperLowerSelect = CurDAG -> getMachineNode ( <STR_LIT> , dl , VecVT , SDValue ( UpperHalfSignMask , <NUM_LIT> ) , SDValue ( VecOp0 , <NUM_LIT> ) , SDValue ( UpperLowerMask , <NUM_LIT> ) ) ; SDNode * Shift = <NUM_LIT> ; if ( ConstantSDNode * CN = dyn_cast < ConstantSDNode > ( ShiftAmt ) ) { unsigned bytes = unsigned ( CN -> getZExtValue ( ) ) >> <NUM_LIT> ; unsigned bits = unsigned ( CN -> getZExtValue ( ) ) & <NUM_LIT> ; if ( bytes > <NUM_LIT> ) { bytes = <NUM_LIT> - bytes ; Shift = CurDAG -> getMachineNode ( <STR_LIT> , dl , VecVT , SDValue ( UpperLowerSelect , <NUM_LIT> ) , CurDAG -> getTargetConstant ( bytes , ShiftAmtVT ) ) ; } if ( bits > <NUM_LIT> ) { bits = <NUM_LIT> - bits ; Shift = CurDAG -> getMachineNode ( <STR_LIT> , dl , VecVT , SDValue ( ( Shift != <NUM_LIT> ? Shift : UpperLowerSelect ) , <NUM_LIT> ) , CurDAG -> getTargetConstant ( bits , ShiftAmtVT ) ) ; } } else { SDNode * NegShift = CurDAG -> getMachineNode ( <STR_LIT> , dl , ShiftAmtVT , ShiftAmt , CurDAG -> getTargetConstant ( <NUM_LIT> , ShiftAmtVT ) ) ; Shift = CurDAG -> getMachineNode ( <STR_LIT> , dl , VecVT , SDValue ( UpperLowerSelect , <NUM_LIT> ) , SDValue ( NegShift , <NUM_LIT> ) ) ; Shift = CurDAG -> getMachineNode ( <STR_LIT> , dl , VecVT , SDValue ( Shift , <NUM_LIT> ) , SDValue ( NegShift , <NUM_LIT> ) ) ; } return CurDAG -> getMachineNode ( <STR_LIT> , dl , OpVT , SDValue ( Shift , <NUM_LIT> ) ) ;


<s> VecOp0 = CurDAG -> getMachineNode ( <STR_LIT> , dl , VecVT , Op0 ) ; if ( ConstantSDNode * CN = dyn_cast < ConstantSDNode > ( ShiftAmt ) ) { unsigned bytes = unsigned ( CN -> getZExtValue ( ) ) >> <NUM_LIT> ; unsigned bits = unsigned ( CN -> getZExtValue ( ) ) & <NUM_LIT> ; if ( bytes > <NUM_LIT> ) { Shift = CurDAG -> getMachineNode ( <STR_LIT> , dl , VecVT , SDValue ( VecOp0 , <NUM_LIT> ) , CurDAG -> getTargetConstant ( bytes , ShiftAmtVT ) ) ; } if ( bits > <NUM_LIT> ) { Shift = CurDAG -> getMachineNode ( <STR_LIT> , dl , VecVT , SDValue ( ( Shift != <NUM_LIT> ? Shift : VecOp0 ) , <NUM_LIT> ) , CurDAG -> getTargetConstant ( bits , ShiftAmtVT ) ) ; }


<s> SDNode * <ISA_LIT>DAGToDAGISel :: SelectSRLi64 ( SDNode * N , EVT OpVT ) { SDValue Op0 = N -> getOperand ( <NUM_LIT> ) ; EVT VecVT = EVT :: getVectorVT ( * CurDAG -> getContext ( ) , OpVT , ( <NUM_LIT> / OpVT . getSizeInBits ( ) ) ) ; SDValue ShiftAmt = N -> getOperand ( <NUM_LIT> ) ; EVT ShiftAmtVT = ShiftAmt . getValueType ( ) ; SDNode * VecOp0 , * Shift = <NUM_LIT> ; DebugLoc dl = N -> getDebugLoc ( ) ; VecOp0 = CurDAG -> getMachineNode ( <STR_LIT> , dl , VecVT , Op0 ) ; if ( ConstantSDNode * CN = dyn_cast < ConstantSDNode > ( ShiftAmt ) ) { unsigned bytes = unsigned ( CN -> getZExtValue ( ) ) >> <NUM_LIT> ; unsigned bits = unsigned ( CN -> getZExtValue ( ) ) & <NUM_LIT> ; if ( bytes > <NUM_LIT> ) { Shift = CurDAG -> getMachineNode ( <STR_LIT> , dl , VecVT , SDValue ( VecOp0 , <NUM_LIT> ) , CurDAG -> getTargetConstant ( bytes , ShiftAmtVT ) ) ; } if ( bits > <NUM_LIT> ) { Shift = CurDAG -> getMachineNode ( <STR_LIT> , dl , VecVT , SDValue ( ( Shift != <NUM_LIT> ? Shift : VecOp0 ) , <NUM_LIT> ) , CurDAG -> getTargetConstant ( bits , ShiftAmtVT ) ) ; } } else {

SDNode * Bytes = CurDAG -> getMachineNode ( <STR_LIT> , dl , ShiftAmtVT , ShiftAmt , CurDAG -> getTargetConstant ( <NUM_LIT> , ShiftAmtVT ) ) ;


<s> FrameIndexSDNode * FIN = dyn_cast < FrameIndexSDNode > ( Op1 ) ; int FI = int ( FIN -> getIndex ( ) ) ; DEBUG ( cerr << <STR_LIT> << offset << <STR_LIT> << FI << <STR_LIT> ) ; if ( <ISA_LIT>FrameInfo :: FItoStackOffset ( FI ) < maxOffset ) { Base = CurDAG -> getTargetConstant ( offset , PtrTy ) ; Index = CurDAG -> getTargetFrameIndex ( FI , PtrTy ) ; return true ; } } else if ( offset > minOffset && offset < maxOffset ) { Base = CurDAG -> getTargetConstant ( offset , PtrTy ) ; Index = Op1 ; return true ; } } } else if ( Opc == <STR_LIT> ) { const SDValue Op0 = N . getOperand ( <NUM_LIT> ) ; const SDValue Op1 = N . getOperand ( <NUM_LIT> ) ; if ( Op0 . getOpcode ( ) == <STR_LIT> && Op1 . getOpcode ( ) == <STR_LIT> ) { Base = CurDAG -> getTargetConstant ( <NUM_LIT> , PtrTy ) ; Index = N ; return true ; } else if ( isa < ConstantSDNode > ( Op0 ) || isa < ConstantSDNode > ( Op1 ) ) { int32_t offset = <NUM_LIT> ; SDValue idxOp ; if ( isa < ConstantSDNode > ( Op1 ) ) { ConstantSDNode * CN = cast < ConstantSDNode > ( Op1 ) ; offset = int32_t ( CN -> getSExtValue ( ) ) ; idxOp = Op0 ; } else if ( isa < ConstantSDNode > ( Op0 ) ) { ConstantSDNode * CN = cast < ConstantSDNode > ( Op0 ) ; offset = int32_t ( CN -> getSExtValue ( ) ) ; idxOp = Op1 ; } if ( offset >= minOffset && offset <= maxOffset ) { Base = CurDAG -> getTargetConstant ( offset , PtrTy ) ; Index = idxOp ; return true ; } } } else if ( Opc == <STR_LIT> ) { Base = CurDAG -> getTargetConstant ( <NUM_LIT> , N . getValueType ( ) ) ; Index = N ;


<s> MVT eltVT = vecVT . getVectorElementType ( ) ; SDNode * bvNode = build_vec . getNode ( ) ; DebugLoc dl = bvNode -> getDebugLoc ( ) ; if ( ( ( vecVT == <STR_LIT> ) && ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) ) || ( ( vecVT == <STR_LIT> ) && ( ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) || ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) || ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) || ( <STR_LIT> ( bvNode , * CurDAG ) . getNode ( ) != <NUM_LIT> ) ) ) || ( ( vecVT == <STR_LIT> ) && ( ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) || ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) || ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) ) ) ) return Select ( build_vec ) ; std :: vector < Constant * > CV ; for ( size_t i = <NUM_LIT> ; i < build_vec . getNumOperands ( ) ; ++ i ) { ConstantSDNode * V = dyn_cast < ConstantSDNode > ( build_vec . getOperand ( i ) ) ; CV . push_back ( const_cast < ConstantInt * > ( V -> getConstantIntValue ( ) ) ) ; } Constant * CP = ConstantVector :: get ( CV ) ;

SDValue CPIdx = CurDAG -> getConstantPool ( CP , <ISA_LIT>tli . getPointerTy ( ) ) ;


<s> DebugLoc dl = bvNode -> getDebugLoc ( ) ; if ( ( ( vecVT == <STR_LIT> ) && ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) ) || ( ( vecVT == <STR_LIT> ) && ( ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) || ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) || ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) || ( <STR_LIT> ( bvNode , * CurDAG ) . getNode ( ) != <NUM_LIT> ) ) ) || ( ( vecVT == <STR_LIT> ) && ( ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) || ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) || ( <STR_LIT> ( bvNode , * CurDAG , <STR_LIT> ) . getNode ( ) != <NUM_LIT> ) ) ) ) return Select ( build_vec ) ; std :: vector < Constant * > CV ; for ( size_t i = <NUM_LIT> ; i < build_vec . getNumOperands ( ) ; ++ i ) { ConstantSDNode * V = dyn_cast < ConstantSDNode > ( build_vec . getOperand ( i ) ) ;

CV . push_back ( const_cast < ConstantInt * > ( V -> getConstantIntValue ( ) ) ) ;


<s> } } if ( retval == <NUM_LIT> ) { cerr << <STR_LIT> << VT . getMVTString ( ) << <STR_LIT> ;


<s> SelectRoot ( * CurDAG ) ; CurDAG -> RemoveDeadNodes ( ) ;


<s> DEBUG ( BB -> dump ( ) ) ; SelectRoot ( * CurDAG ) ;


<s> int sval = ( int ) ( ( val << <NUM_LIT> ) >> <NUM_LIT> ) ; Imm = ( short ) val ; return val == sval ; }


<s> return isS10Constant ( CN -> getSExtValue ( ) ) ;


<s> bool isI32IntS10Immediate ( ConstantSDNode * CN ) { return isS10Constant ( CN -> getSExtValue ( ) ) ;


<s> return isU10Constant ( CN -> getSExtValue ( ) ) ;


<s> bool isI64IntS10Immediate ( ConstantSDNode * CN ) {

return isS10Constant ( CN -> getSExtValue ( ) ) ;


<s> Imm = ( short ) CN -> getZExtValue ( ) ; if ( vt . getSimpleVT ( ) >= <STR_LIT> && vt . getSimpleVT ( ) <= <STR_LIT> ) { return true ; } else if ( vt == <STR_LIT> ) {

int32_t i_val = ( int32_t ) CN -> getZExtValue ( ) ;


<s> virtual bool runOnFunction ( Function & Fn ) { GlobalBaseReg = <NUM_LIT> ; SelectionDAGISel :: runOnFunction ( Fn ) ;


<s> SelectionDAGISel :: runOnFunction ( Fn ) ; return true ;


<s> case <STR_LIT> : case <STR_LIT> : cerr << <STR_LIT> ; abort ( ) ; case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : cerr << <STR_LIT> << <STR_LIT> ; abort ( ) ; case <STR_LIT> : if ( N . hasOneUse ( ) ) { SDValue Op0 = N . getOperand ( <NUM_LIT> ) ; switch ( Op0 . getOpcode ( ) ) { case <STR_LIT> : case <STR_LIT> : Base = Op0 ; Index = Zero ; return true ; case <STR_LIT> : { GlobalAddressSDNode * GSDN = cast < GlobalAddressSDNode > ( Op0 ) ; GlobalValue * GV = GSDN -> getGlobal ( ) ; if ( GV -> getAlignment ( ) == <NUM_LIT> ) { Base = Op0 ; Index = Zero ; return true ; } break ; } } } break ; }


<s> case <STR_LIT> : case <STR_LIT> : case <STR_LIT> : cerr << <STR_LIT> << <STR_LIT> ; abort ( ) ; case <STR_LIT> : if ( N . hasOneUse ( ) ) { SDValue Op0 = N . getOperand ( <NUM_LIT> ) ; switch ( Op0 . getOpcode ( ) ) { case <STR_LIT> : case <STR_LIT> : Base = Op0 ; Index = Zero ; return true ; case <STR_LIT> : { GlobalAddressSDNode * GSDN = cast < GlobalAddressSDNode > ( Op0 ) ; GlobalValue * GV = GSDN -> getGlobal ( ) ; if ( GV -> getAlignment ( ) == <NUM_LIT> ) { Base = Op0 ; Index = Zero ; return true ; } break ; } } }


<s> const int maxDForm2Offset = ( <NUM_LIT> << <NUM_LIT> ) - <NUM_LIT> ;

return DFormAddressPredicate ( Op , N , Disp , Base , minDForm2Offset , maxDForm2Offset ) ;


<s> bool <ISA_LIT>DAGToDAGISel :: SelectDFormAddr ( SDValue Op , SDValue N , SDValue & Base , SDValue & Index ) {

return DFormAddressPredicate ( Op , N , Base , Index , <ISA_LIT>FrameInfo :: minFrameOffset ( ) , <ISA_LIT>FrameInfo :: maxFrameOffset ( ) ) ;


<s> if ( lhs . getOpcode ( ) == <STR_LIT> ) { ReplaceUses ( lhs , lhs . getOperand ( <NUM_LIT> ) ) ; lhs = lhs . getOperand ( <NUM_LIT> ) ; } SDNode * lhsNode = ( lhs . getNode ( ) -> isMachineOpcode ( ) ? lhs . getNode ( ) : emitBuildVector ( lhs ) ) ; if ( rhs . getOpcode ( ) == <STR_LIT> ) { ReplaceUses ( rhs , rhs . getOperand ( <NUM_LIT> ) ) ; rhs = rhs . getOperand ( <NUM_LIT> ) ; } SDNode * rhsNode = ( rhs . getNode ( ) -> isMachineOpcode ( ) ? rhs . getNode ( ) : emitBuildVector ( rhs ) ) ; if ( shufmask . getOpcode ( ) == <STR_LIT> ) { ReplaceUses ( shufmask , shufmask . getOperand ( <NUM_LIT> ) ) ; shufmask = shufmask . getOperand ( <NUM_LIT> ) ; }

SDNode * shufMaskNode = ( shufmask . getNode ( ) -> isMachineOpcode ( ) ? shufmask . getNode ( ) : emitBuildVector ( shufmask ) ) ;


<s> if ( ConstantSDNode * CN = dyn_cast < ConstantSDNode > ( ShiftAmt ) ) { unsigned bytes = unsigned ( CN -> getZExtValue ( ) ) >> <NUM_LIT> ; unsigned bits = unsigned ( CN -> getZExtValue ( ) ) & <NUM_LIT> ; if ( bytes > <NUM_LIT> ) { Shift = CurDAG -> getTargetNode ( <STR_LIT> , dl , VecVT , SDValue ( VecOp0 , <NUM_LIT> ) , CurDAG -> getTargetConstant ( bytes , ShiftAmtVT ) ) ; } if ( bits > <NUM_LIT> ) { Shift = CurDAG -> getTargetNode ( <STR_LIT> , dl , VecVT , SDValue ( ( Shift != <NUM_LIT> ? Shift : VecOp0 ) , <NUM_LIT> ) , CurDAG -> getTargetConstant ( bits , ShiftAmtVT ) ) ; } } else { SDNode * Bytes = CurDAG -> getTargetNode ( <STR_LIT> , dl , ShiftAmtVT , ShiftAmt , CurDAG -> getTargetConstant ( <NUM_LIT> , ShiftAmtVT ) ) ; SDNode * Bits = CurDAG -> getTargetNode ( <STR_LIT> , dl , ShiftAmtVT , ShiftAmt , CurDAG -> getTargetConstant ( <NUM_LIT> , ShiftAmtVT ) ) ; Shift = CurDAG -> getTargetNode ( <STR_LIT> , dl , VecVT , SDValue ( VecOp0 , <NUM_LIT> ) , SDValue ( Bytes , <NUM_LIT> ) ) ; Shift = CurDAG -> getTargetNode ( <STR_LIT> , dl , VecVT , SDValue ( Shift , <NUM_LIT> ) , SDValue ( Bits , <NUM_LIT> ) ) ; } return CurDAG -> getTargetNode ( <STR_LIT> , dl , OpVT , SDValue ( Shift , <NUM_LIT> ) ) ;


<s> SDNode * UpperHalfSignMask = CurDAG -> getTargetNode ( <STR_LIT> , dl , VecVT , SDValue ( UpperHalfSign , <NUM_LIT> ) ) ; SDNode * UpperLowerMask = CurDAG -> getTargetNode ( <STR_LIT> , dl , VecVT , CurDAG -> getTargetConstant ( <NUM_LIT> , <STR_LIT> ) ) ; SDNode * UpperLowerSelect = CurDAG -> getTargetNode ( <STR_LIT> , dl , VecVT , SDValue ( UpperHalfSignMask , <NUM_LIT> ) , SDValue ( VecOp0 , <NUM_LIT> ) , SDValue ( UpperLowerMask , <NUM_LIT> ) ) ; SDNode * Shift = <NUM_LIT> ; if ( ConstantSDNode * CN = dyn_cast < ConstantSDNode > ( ShiftAmt ) ) { unsigned bytes = unsigned ( CN -> getZExtValue ( ) ) >> <NUM_LIT> ; unsigned bits = unsigned ( CN -> getZExtValue ( ) ) & <NUM_LIT> ; if ( bytes > <NUM_LIT> ) { bytes = <NUM_LIT> - bytes ; Shift = CurDAG -> getTargetNode ( <STR_LIT> , dl , VecVT , SDValue ( UpperLowerSelect , <NUM_LIT> ) , CurDAG -> getTargetConstant ( bytes , ShiftAmtVT ) ) ; } if ( bits > <NUM_LIT> ) { bits = <NUM_LIT> - bits ;

Shift = CurDAG -> getTargetNode ( <STR_LIT> , dl , VecVT , SDValue ( ( Shift != <NUM_LIT> ? Shift : UpperLowerSelect ) , <NUM_LIT> ) , CurDAG -> getTargetConstant ( bits , ShiftAmtVT ) ) ;


<s> unsigned bytes = unsigned ( CN -> getZExtValue ( ) ) >> <NUM_LIT> ; unsigned bits = unsigned ( CN -> getZExtValue ( ) ) & <NUM_LIT> ; if ( bytes > <NUM_LIT> ) { Shift = CurDAG -> getTargetNode ( <STR_LIT> , dl , VecVT , SDValue ( VecOp0 , <NUM_LIT> ) , CurDAG -> getTargetConstant ( bytes , ShiftAmtVT ) ) ; } if ( bits > <NUM_LIT> ) { Shift = CurDAG -> getTargetNode ( <STR_LIT> , dl , VecVT , SDValue ( ( Shift != <NUM_LIT> ? Shift : VecOp0 ) , <NUM_LIT> ) , CurDAG -> getTargetConstant ( bits , ShiftAmtVT ) ) ; } } else { SDNode * Bytes = CurDAG -> getTargetNode ( <STR_LIT> , dl , ShiftAmtVT , ShiftAmt , CurDAG -> getTargetConstant ( <NUM_LIT> , ShiftAmtVT ) ) ; SDNode * Bits = CurDAG -> getTargetNode ( <STR_LIT> , dl , ShiftAmtVT , ShiftAmt , CurDAG -> getTargetConstant ( <NUM_LIT> , ShiftAmtVT ) ) ;

Bytes = CurDAG -> getTargetNode ( <STR_LIT> , dl , ShiftAmtVT , SDValue ( Bytes , <NUM_LIT> ) , CurDAG -> getTargetConstant ( <NUM_LIT> , ShiftAmtVT ) ) ;


<s> Base = N . getOperand ( <NUM_LIT> ) ; Index = N . getOperand ( <NUM_LIT> ) ; return true ;


<s> if ( ! SelectAFormAddr ( Op , N , Base , Index ) && ! SelectDFormAddr ( Op , N , Base , Index ) ) { Base = N . getOperand ( <NUM_LIT> ) ; Index = N . getOperand ( <NUM_LIT> ) ; return true ;