ground_truth
sequencelengths
8
512
natrual_language
sequencelengths
1
243
TS_V_token
sequencelengths
1
182
File
stringlengths
2
45
Func
stringlengths
1
56
Target
stringclasses
175 values
Target_Clf
stringclasses
6 values
Compiler_Type
stringclasses
2 values
Idx
int64
0
36.2k
Length
int64
6
510
Cover_Rate
float64
1
1
Template_token
sequencelengths
0
0
[ "<s>", "int", "frv_legitimate_memory_operand", "(", "rtx", "op", ",", "enum", "machine_mode", "mode", ",", "int", "condexec_p", ")", "{", "return", "(", "(", "GET_MODE", "(", "op", ")", "==", "mode", "||", "mode", "==", "VOIDmode", ")", "&&", "GET_CODE", "(", "op", ")", "==", "MEM", "&&", "frv_legitimate_address_p", "(", "mode", ",", "XEXP", "(", "op", ",", "0", ")", ",", "reload_completed", ",", "condexec_p", ",", "FALSE", ")", ")", ";", "}", "</s>" ]
[ "Return", "1", "if", "operand", "is", "a", "valid", "FRV", "address", ".", "CONDEXEC_P", "is", "true", "if", "the", "operand", "is", "used", "by", "a", "predicated", "instruction", "." ]
[ "frv", "0" ]
frv2
frv_legitimate_memory_operand
frv
VLIW
GCC
0
56
1
[]
[ "<s>", "bool", "AArch64FrameLowering", "::", "spillCalleeSavedRegisters", "(", "MachineBasicBlock", "&", "MBB", ",", "MachineBasicBlock", "::", "iterator", "MBBI", ",", "const", "std", "::", "vector", "<", "CalleeSavedInfo", ">", "&", "CSI", ",", "const", "TargetRegisterInfo", "*", "TRI", ")", "const", "{", "if", "(", "CSI", ".", "empty", "(", ")", ")", "return", "false", ";", "static", "const", "LoadStoreMethod", "PossibleClasses", "[", "]", "=", "{", "{", "&", "AArch64", "::", "GPR64RegClass", ",", "AArch64", "::", "LSPair64_STR", ",", "AArch64", "::", "LS64_STR", "}", ",", "{", "&", "AArch64", "::", "FPR64RegClass", ",", "AArch64", "::", "LSFPPair64_STR", ",", "AArch64", "::", "LSFP64_STR", "}", ",", "}", ";", "const", "unsigned", "NumClasses", "=", "llvm", "::", "array_lengthof", "(", "PossibleClasses", ")", ";", "emitFrameMemOps", "(", "true", ",", "MBB", ",", "MBBI", ",", "CSI", ",", "TRI", ",", "PossibleClasses", ",", "NumClasses", ")", ";", "return", "true", ";", "}", "</s>" ]
[ "spillCalleeSavedRegisters", "-", "Issues", "instruction", "(", "s", ")", "to", "spill", "all", "callee", "saved", "registers", "and", "returns", "true", "if", "it", "is", "n't", "possible", "/", "profitable", "to", "do", "so", "by", "issuing", "a", "series", "of", "store", "instructions", "via", "storeRegToStackSlot", "(", ")", "." ]
[ "AArch64", "AArch64", "AArch64::GPR64RegClass", "AArch64::LSPair64_STR", "AArch64::LS64_STR", "AArch64::FPR64RegClass", "AArch64::LSFPPair64_STR", "AArch64::LSFP64_STR" ]
AArch64FrameLowering24
spillCalleeSavedRegisters
AArch64
CPU
LLVM
1
114
1
[]
[ "<s>", "bool", "runOnMachineFunction", "(", "MachineFunction", "&", "F", ")", "{", "bool", "Changed", "=", "false", ";", "if", "(", "TM", ".", "getSubtargetImpl", "(", ")", "->", "getCFLType", "(", ")", "!=", "PatmosSubtarget", "::", "CFL_DELAYED", ")", "{", "DEBUG", "(", "dbgs", "(", ")", "<<", "\"\\n[DelaySlotKiller] \"", "<<", "F", ".", "getFunction", "(", ")", "->", "getName", "(", ")", "<<", "\"\\n\"", ")", ";", "for", "(", "MachineFunction", "::", "iterator", "FI", "=", "F", ".", "begin", "(", ")", ",", "FE", "=", "F", ".", "end", "(", ")", ";", "FI", "!=", "FE", ";", "++", "FI", ")", "Changed", "|=", "killDelaySlots", "(", "*", "FI", ")", ";", "}", "return", "Changed", ";", "}", "</s>" ]
[ "runOnMachineFunction", "-", "Emit", "the", "function", "body", "." ]
[ "Patmos", "Patmos", "\"\\n[DelaySlotKiller] \"", "\"\\n\"" ]
PatmosDelaySlotKiller
runOnMachineFunction
Patmos
VLIW
LLVM
2
92
1
[]
[ "<s>", "void", "WebAssemblyFrameLowering", "::", "writeSPToGlobal", "(", "unsigned", "SrcReg", ",", "MachineFunction", "&", "MF", ",", "MachineBasicBlock", "&", "MBB", ",", "MachineBasicBlock", "::", "iterator", "&", "InsertStore", ",", "const", "DebugLoc", "&", "DL", ")", "const", "{", "const", "auto", "*", "TII", "=", "MF", ".", "getSubtarget", "<", "WebAssemblySubtarget", ">", "(", ")", ".", "getInstrInfo", "(", ")", ";", "const", "char", "*", "ES", "=", "\"__stack_pointer\"", ";", "auto", "*", "SPSymbol", "=", "MF", ".", "createExternalSymbolName", "(", "ES", ")", ";", "BuildMI", "(", "MBB", ",", "InsertStore", ",", "DL", ",", "TII", "->", "get", "(", "getOpcGlobSet", "(", "MF", ")", ")", ")", ".", "addExternalSymbol", "(", "SPSymbol", ")", ".", "addReg", "(", "SrcReg", ")", ";", "}", "</s>" ]
[ "Write", "SP", "back", "to", "__stack_pointer", "global", "." ]
[ "WebAssembly", "WebAssembly", "WebAssembly", "\"__stack_pointer\"" ]
WebAssemblyFrameLowering11
writeSPToGlobal
WebAssembly
Virtual ISA
LLVM
3
95
1
[]
[ "<s>", "static", "bool", "hasReassociableSibling", "(", "const", "MachineInstr", "&", "Inst", ",", "bool", "&", "Commuted", ")", "{", "const", "MachineBasicBlock", "*", "MBB", "=", "Inst", ".", "getParent", "(", ")", ";", "const", "MachineRegisterInfo", "&", "MRI", "=", "MBB", "->", "getParent", "(", ")", "->", "getRegInfo", "(", ")", ";", "MachineInstr", "*", "MI1", "=", "MRI", ".", "getUniqueVRegDef", "(", "Inst", ".", "getOperand", "(", "1", ")", ".", "getReg", "(", ")", ")", ";", "MachineInstr", "*", "MI2", "=", "MRI", ".", "getUniqueVRegDef", "(", "Inst", ".", "getOperand", "(", "2", ")", ".", "getReg", "(", ")", ")", ";", "unsigned", "AssocOpcode", "=", "Inst", ".", "getOpcode", "(", ")", ";", "Commuted", "=", "MI1", "->", "getOpcode", "(", ")", "!=", "AssocOpcode", "&&", "MI2", "->", "getOpcode", "(", ")", "==", "AssocOpcode", ";", "if", "(", "Commuted", ")", "std", "::", "swap", "(", "MI1", ",", "MI2", ")", ";", "if", "(", "MI1", "->", "getOpcode", "(", ")", "==", "AssocOpcode", "&&", "hasReassociableOperands", "(", "*", "MI1", ",", "MBB", ")", "&&", "MRI", ".", "hasOneNonDBGUse", "(", "MI1", "->", "getOperand", "(", "0", ")", ".", "getReg", "(", ")", ")", ")", "return", "true", ";", "return", "false", ";", "}", "</s>" ]
[ "Return", "true", "when", "\\P", "Inst", "has", "reassociable", "sibling", "." ]
[ "X86", "1", "2", "0" ]
X86InstrInfo123
hasReassociableSibling
X86
CPU
LLVM
4
161
1
[]
[ "<s>", "static", "unsigned", "int", "h8300_move_length", "(", "rtx", "*", "operands", ",", "const", "h8300_length_table", "*", "table", ")", "{", "unsigned", "int", "size", ";", "size", "=", "h8300_length_from_table", "(", "operands", "[", "0", "]", ",", "operands", "[", "1", "]", ",", "table", ")", ";", "if", "(", "REG_P", "(", "operands", "[", "0", "]", ")", "&&", "h8300_short_move_mem_p", "(", "operands", "[", "1", "]", ",", "POST_INC", ")", ")", "size", "-=", "2", ";", "if", "(", "REG_P", "(", "operands", "[", "1", "]", ")", "&&", "h8300_short_move_mem_p", "(", "operands", "[", "0", "]", ",", "PRE_DEC", ")", ")", "size", "-=", "2", ";", "return", "size", ";", "}", "</s>" ]
[ "Calculate", "the", "length", "of", "move", "instruction", "INSN", "using", "the", "given", "length", "table", ".", "Although", "the", "tables", "are", "correct", "for", "most", "cases", ",", "there", "is", "some", "irregularity", "in", "the", "length", "of", "mov.b", "and", "mov.w", ".", "The", "following", "forms", ":", "mov", "@", "ERs+", ",", "Rd", "mov", "@", "(", "d:16", ",", "ERs", ")", ",", "Rd", "mov", "Rs", ",", "@", "-ERd", "mov", "Rs", ",", "@", "(", "d:16", ",", "ERd", ")", "are", "two", "bytes", "shorter", "than", "most", "other", "``", "mov", "Rs", ",", "@", "complex", "''", "or", "``", "mov", "@", "complex", ",", "Rd", "''", "combinations", "." ]
[ "h8300", "0", "1", "0", "1", "2", "1", "0", "2" ]
h8300
h8300_move_length
h8300
MPU
GCC
5
88
1
[]
[ "<s>", "void", "ARMPassConfig", "::", "addPreEmitPass", "(", ")", "{", "addPass", "(", "createThumb2SizeReductionPass", "(", ")", ")", ";", "addPass", "(", "createUnpackMachineBundles", "(", "[", "]", "(", "const", "MachineFunction", "&", "MF", ")", "{", "return", "MF", ".", "getSubtarget", "<", "ARMSubtarget", ">", "(", ")", ".", "isThumb2", "(", ")", ";", "}", ")", ")", ";", "if", "(", "getOptLevel", "(", ")", "!=", "CodeGenOpt", "::", "None", ")", "addPass", "(", "createARMOptimizeBarriersPass", "(", ")", ")", ";", "addPass", "(", "createARMConstantIslandPass", "(", ")", ")", ";", "}", "</s>" ]
[ "This", "pass", "may", "be", "implemented", "by", "targets", "that", "want", "to", "run", "passes", "immediately", "before", "machine", "code", "is", "emitted", "." ]
[ "ARM", "ARM", "ARM", "ARM", "ARM" ]
ARMTargetMachine
addPreEmitPass
ARM
CPU
LLVM
6
70
1
[]
[ "<s>", "SDValue", "SparcTargetLowering", "::", "PerformDAGCombine", "(", "SDNode", "*", "N", ",", "DAGCombinerInfo", "&", "DCI", ")", "const", "{", "switch", "(", "N", "->", "getOpcode", "(", ")", ")", "{", "default", ":", "break", ";", "case", "ISD", "::", "BITCAST", ":", "return", "PerformBITCASTCombine", "(", "N", ",", "DCI", ")", ";", "}", "return", "SDValue", "(", ")", ";", "}", "</s>" ]
[ "This", "method", "will", "be", "invoked", "for", "all", "target", "nodes", "and", "for", "any", "target-independent", "nodes", "that", "the", "target", "has", "registered", "with", "invoke", "it", "for", "." ]
[ "Sparc", "Sparc", "ISD::BITCAST" ]
SparcISelLowering (2)2
PerformDAGCombine
Sparc
CPU
LLVM
7
48
1
[]
[ "<s>", "static", "bool", "arm_valid_target_attribute_rec", "(", "tree", "args", ",", "struct", "gcc_options", "*", "opts", ")", "{", "if", "(", "TREE_CODE", "(", "args", ")", "==", "TREE_LIST", ")", "{", "bool", "ret", "=", "true", ";", "for", "(", ";", "args", ";", "args", "=", "TREE_CHAIN", "(", "args", ")", ")", "if", "(", "TREE_VALUE", "(", "args", ")", "&&", "!", "arm_valid_target_attribute_rec", "(", "TREE_VALUE", "(", "args", ")", ",", "opts", ")", ")", "ret", "=", "false", ";", "return", "ret", ";", "}", "else", "if", "(", "TREE_CODE", "(", "args", ")", "!=", "STRING_CST", ")", "{", "error", "(", "\"attribute %<target%> argument not a string\"", ")", ";", "return", "false", ";", "}", "char", "*", "argstr", "=", "ASTRDUP", "(", "TREE_STRING_POINTER", "(", "args", ")", ")", ";", "char", "*", "q", ";", "while", "(", "(", "q", "=", "strtok", "(", "argstr", ",", "\",\"", ")", ")", "!=", "NULL", ")", "{", "while", "(", "ISSPACE", "(", "*", "q", ")", ")", "++", "q", ";", "argstr", "=", "NULL", ";", "if", "(", "!", "strncmp", "(", "q", ",", "\"thumb\"", ",", "5", ")", ")", "opts", "->", "x_target_flags", "|=", "MASK_THUMB", ";", "else", "if", "(", "!", "strncmp", "(", "q", ",", "\"arm\"", ",", "3", ")", ")", "opts", "->", "x_target_flags", "&=", "~", "MASK_THUMB", ";", "else", "if", "(", "!", "strncmp", "(", "q", ",", "\"fpu=\"", ",", "4", ")", ")", "{", "if", "(", "!", "opt_enum_arg_to_value", "(", "OPT_mfpu_", ",", "q", "+", "4", ",", "&", "opts", "->", "x_arm_fpu_index", ",", "CL_TARGET", ")", ")", "{", "error", "(", "\"invalid fpu for attribute(target(\\\"%s\\\"))\"", ",", "q", ")", ";", "return", "false", ";", "}", "}", "else", "{", "error", "(", "\"attribute(target(\\\"%s\\\")) is unknown\"", ",", "q", ")", ";", "return", "false", ";", "}", "arm_option_check_internal", "(", "opts", ")", ";", "}", "return", "true", ";", "}", "</s>" ]
[ "Inner", "function", "to", "process", "the", "attribute", "(", "(", "target", "(", "...", ")", ")", ")", ",", "take", "an", "argument", "and", "set", "the", "current", "options", "from", "the", "argument", ".", "If", "we", "have", "a", "list", ",", "recursively", "go", "over", "the", "list", "." ]
[ "arm", "\"attribute %<target%> argument not a string\"", "\",\"", "\"thumb\"", "5", "\"arm\"", "3", "\"fpu=\"", "4", "4", "\"invalid fpu for attribute(target(\\\"%s\\\"))\"", "\"attribute(target(\\\"%s\\\")) is unknown\"" ]
arm5
arm_valid_target_attribute_rec
arm
CPU
GCC
8
240
1
[]
[ "<s>", "enum", "reg_class", "arm_regno_class", "(", "int", "regno", ")", "{", "if", "(", "regno", "==", "PC_REGNUM", ")", "return", "NO_REGS", ";", "if", "(", "TARGET_THUMB1", ")", "{", "if", "(", "regno", "==", "STACK_POINTER_REGNUM", ")", "return", "STACK_REG", ";", "if", "(", "regno", "==", "CC_REGNUM", ")", "return", "CC_REG", ";", "if", "(", "regno", "<", "8", ")", "return", "LO_REGS", ";", "return", "HI_REGS", ";", "}", "if", "(", "TARGET_THUMB2", "&&", "regno", "<", "8", ")", "return", "LO_REGS", ";", "if", "(", "regno", "<=", "LAST_ARM_REGNUM", "||", "regno", "==", "FRAME_POINTER_REGNUM", "||", "regno", "==", "ARG_POINTER_REGNUM", ")", "return", "TARGET_THUMB2", "?", "HI_REGS", ":", "GENERAL_REGS", ";", "if", "(", "regno", "==", "CC_REGNUM", "||", "regno", "==", "VFPCC_REGNUM", ")", "return", "TARGET_THUMB2", "?", "CC_REG", ":", "NO_REGS", ";", "if", "(", "IS_VFP_REGNUM", "(", "regno", ")", ")", "{", "if", "(", "regno", "<=", "D7_VFP_REGNUM", ")", "return", "VFP_D0_D7_REGS", ";", "else", "if", "(", "regno", "<=", "LAST_LO_VFP_REGNUM", ")", "return", "VFP_LO_REGS", ";", "else", "return", "VFP_HI_REGS", ";", "}", "if", "(", "IS_IWMMXT_REGNUM", "(", "regno", ")", ")", "return", "IWMMXT_REGS", ";", "if", "(", "IS_IWMMXT_GR_REGNUM", "(", "regno", ")", ")", "return", "IWMMXT_GR_REGS", ";", "return", "NO_REGS", ";", "}", "</s>" ]
[ "For", "efficiency", "and", "historical", "reasons", "LO_REGS", ",", "HI_REGS", "and", "CC_REGS", "are", "not", "used", "in", "arm", "mode", "." ]
[ "arm", "8", "8" ]
arm4
arm_regno_class
arm
CPU
GCC
9
158
1
[]
[ "<s>", "int", "X86TTIImpl", "::", "getIntrinsicInstrCost", "(", "Intrinsic", "::", "ID", "IID", ",", "Type", "*", "RetTy", ",", "ArrayRef", "<", "Value", "*", ">", "Args", ",", "FastMathFlags", "FMF", ",", "unsigned", "VF", ")", "{", "return", "BaseT", "::", "getIntrinsicInstrCost", "(", "IID", ",", "RetTy", ",", "Args", ",", "FMF", ",", "VF", ")", ";", "}", "</s>" ]
[ "Get", "intrinsic", "cost", "based", "on", "arguments", "." ]
[ "X86", "X86", "Intrinsic::ID" ]
X86TargetTransformInfo (2)
getIntrinsicInstrCost
X86
CPU
LLVM
10
45
1
[]
[ "<s>", "virtual", "const", "char", "*", "getPassName", "(", ")", "const", "{", "return", "\"PIC16 Memsel Optimizer\"", ";", "}", "</s>" ]
[ "getPassName", "-", "Return", "a", "nice", "clean", "name", "for", "a", "pass", "." ]
[ "PIC16", "\"PIC16 Memsel Optimizer\"" ]
PIC16MemSelOpt
getPassName
PIC16
MPU
LLVM
11
13
1
[]
[ "<s>", "SDValue", "VETargetLowering", "::", "LowerReturn", "(", "SDValue", "Chain", ",", "CallingConv", "::", "ID", "CallConv", ",", "bool", "IsVarArg", ",", "const", "SmallVectorImpl", "<", "ISD", "::", "OutputArg", ">", "&", "Outs", ",", "const", "SmallVectorImpl", "<", "SDValue", ">", "&", "OutVals", ",", "const", "SDLoc", "&", "DL", ",", "SelectionDAG", "&", "DAG", ")", "const", "{", "SmallVector", "<", "CCValAssign", ",", "16", ">", "RVLocs", ";", "CCState", "CCInfo", "(", "CallConv", ",", "IsVarArg", ",", "DAG", ".", "getMachineFunction", "(", ")", ",", "RVLocs", ",", "*", "DAG", ".", "getContext", "(", ")", ")", ";", "CCInfo", ".", "AnalyzeReturn", "(", "Outs", ",", "RetCC_VE", ")", ";", "SDValue", "Flag", ";", "SmallVector", "<", "SDValue", ",", "4", ">", "RetOps", "(", "1", ",", "Chain", ")", ";", "for", "(", "unsigned", "i", "=", "0", ";", "i", "!=", "RVLocs", ".", "size", "(", ")", ";", "++", "i", ")", "{", "CCValAssign", "&", "VA", "=", "RVLocs", "[", "i", "]", ";", "assert", "(", "VA", ".", "isRegLoc", "(", ")", "&&", "\"Can only return in registers!\"", ")", ";", "SDValue", "OutVal", "=", "OutVals", "[", "i", "]", ";", "switch", "(", "VA", ".", "getLocInfo", "(", ")", ")", "{", "case", "CCValAssign", "::", "Full", ":", "break", ";", "case", "CCValAssign", "::", "SExt", ":", "OutVal", "=", "DAG", ".", "getNode", "(", "ISD", "::", "SIGN_EXTEND", ",", "DL", ",", "VA", ".", "getLocVT", "(", ")", ",", "OutVal", ")", ";", "break", ";", "case", "CCValAssign", "::", "ZExt", ":", "OutVal", "=", "DAG", ".", "getNode", "(", "ISD", "::", "ZERO_EXTEND", ",", "DL", ",", "VA", ".", "getLocVT", "(", ")", ",", "OutVal", ")", ";", "break", ";", "case", "CCValAssign", "::", "AExt", ":", "OutVal", "=", "DAG", ".", "getNode", "(", "ISD", "::", "ANY_EXTEND", ",", "DL", ",", "VA", ".", "getLocVT", "(", ")", ",", "OutVal", ")", ";", "break", ";", "default", ":", "llvm_unreachable", "(", "\"Unknown loc info!\"", ")", ";", "}", "assert", "(", "!", "VA", ".", "needsCustom", "(", ")", "&&", "\"Unexpected custom lowering\"", ")", ";", "Chain", "=", "DAG", ".", "getCopyToReg", "(", "Chain", ",", "DL", ",", "VA", ".", "getLocReg", "(", ")", ",", "OutVal", ",", "Flag", ")", ";", "Flag", "=", "Chain", ".", "getValue", "(", "1", ")", ";", "RetOps", ".", "push_back", "(", "DAG", ".", "getRegister", "(", "VA", ".", "getLocReg", "(", ")", ",", "VA", ".", "getLocVT", "(", ")", ")", ")", ";", "}", "RetOps", "[", "0", "]", "=", "Chain", ";", "if", "(", "Flag", ".", "getNode", "(", ")", ")", "RetOps", ".", "push_back", "(", "Flag", ")", ";", "return", "DAG", ".", "getNode", "(", "VEISD", "::", "RET_FLAG", ",", "DL", ",", "MVT", "::", "Other", ",", "RetOps", ")", ";", "}", "</s>" ]
[ "This", "hook", "must", "be", "implemented", "to", "lower", "outgoing", "return", "values", ",", "described", "by", "the", "Outs", "array", ",", "into", "the", "specified", "DAG", "." ]
[ "VE", "VE", "ISD::OutputArg", "16", "VE", "4", "1", "0", "\"Can only return in registers!\"", "ISD::SIGN_EXTEND", "ISD::ZERO_EXTEND", "ISD::ANY_EXTEND", "\"Unknown loc info!\"", "\"Unexpected custom lowering\"", "1", "0", "VEISD::RET_FLAG", "MVT::Other" ]
VEISelLowering
LowerReturn
VE
CPU
LLVM
12
362
1
[]
[ "<s>", "const", "RegisterBankInfo", "::", "InstructionMapping", "&", "MipsRegisterBankInfo", "::", "getInstrMapping", "(", "const", "MachineInstr", "&", "MI", ")", "const", "{", "unsigned", "Opc", "=", "MI", ".", "getOpcode", "(", ")", ";", "const", "MachineFunction", "&", "MF", "=", "*", "MI", ".", "getParent", "(", ")", "->", "getParent", "(", ")", ";", "const", "MachineRegisterInfo", "&", "MRI", "=", "MF", ".", "getRegInfo", "(", ")", ";", "const", "RegisterBankInfo", "::", "InstructionMapping", "&", "Mapping", "=", "getInstrMappingImpl", "(", "MI", ")", ";", "if", "(", "Mapping", ".", "isValid", "(", ")", ")", "return", "Mapping", ";", "using", "namespace", "TargetOpcode", ";", "unsigned", "NumOperands", "=", "MI", ".", "getNumOperands", "(", ")", ";", "const", "ValueMapping", "*", "OperandsMapping", "=", "&", "Mips", "::", "ValueMappings", "[", "Mips", "::", "GPRIdx", "]", ";", "switch", "(", "Opc", ")", "{", "case", "G_TRUNC", ":", "case", "G_ADD", ":", "case", "G_SUB", ":", "case", "G_MUL", ":", "case", "G_UMULH", ":", "case", "G_LOAD", ":", "case", "G_STORE", ":", "case", "G_ZEXTLOAD", ":", "case", "G_SEXTLOAD", ":", "case", "G_GEP", ":", "case", "G_AND", ":", "case", "G_OR", ":", "case", "G_XOR", ":", "case", "G_SHL", ":", "case", "G_ASHR", ":", "case", "G_LSHR", ":", "case", "G_SDIV", ":", "case", "G_UDIV", ":", "case", "G_SREM", ":", "case", "G_UREM", ":", "OperandsMapping", "=", "&", "Mips", "::", "ValueMappings", "[", "Mips", "::", "GPRIdx", "]", ";", "break", ";", "case", "G_FCONSTANT", ":", "{", "LLT", "Ty", "=", "MRI", ".", "getType", "(", "MI", ".", "getOperand", "(", "0", ")", ".", "getReg", "(", ")", ")", ";", "unsigned", "Size", "=", "Ty", ".", "getSizeInBits", "(", ")", ";", "const", "RegisterBankInfo", "::", "ValueMapping", "*", "FPRValueMapping", "=", "Size", "==", "32", "?", "&", "Mips", "::", "ValueMappings", "[", "Mips", "::", "SPRIdx", "]", ":", "&", "Mips", "::", "ValueMappings", "[", "Mips", "::", "DPRIdx", "]", ";", "OperandsMapping", "=", "getOperandsMapping", "(", "{", "FPRValueMapping", ",", "nullptr", "}", ")", ";", "break", ";", "}", "case", "G_CONSTANT", ":", "case", "G_FRAME_INDEX", ":", "case", "G_GLOBAL_VALUE", ":", "case", "G_BRCOND", ":", "OperandsMapping", "=", "getOperandsMapping", "(", "{", "&", "Mips", "::", "ValueMappings", "[", "Mips", "::", "GPRIdx", "]", ",", "nullptr", "}", ")", ";", "break", ";", "case", "G_ICMP", ":", "OperandsMapping", "=", "getOperandsMapping", "(", "{", "&", "Mips", "::", "ValueMappings", "[", "Mips", "::", "GPRIdx", "]", ",", "nullptr", ",", "&", "Mips", "::", "ValueMappings", "[", "Mips", "::", "GPRIdx", "]", ",", "&", "Mips", "::", "ValueMappings", "[", "Mips", "::", "GPRIdx", "]", "}", ")", ";", "break", ";", "case", "G_SELECT", ":", "OperandsMapping", "=", "getOperandsMapping", "(", "{", "&", "Mips", "::", "ValueMappings", "[", "Mips", "::", "GPRIdx", "]", ",", "&", "Mips", "::", "ValueMappings", "[", "Mips", "::", "GPRIdx", "]", ",", "&", "Mips", "::", "ValueMappings", "[", "Mips", "::", "GPRIdx", "]", ",", "&", "Mips", "::", "ValueMappings", "[", "Mips", "::", "GPRIdx", "]", "}", ")", ";", "break", ";", "default", ":", "return", "getInvalidInstructionMapping", "(", ")", ";", "}", "return", "getInstructionMapping", "(", "DefaultMappingID", ",", "1", ",", "OperandsMapping", ",", "NumOperands", ")", ";", "}", "</s>" ]
[ "Get", "the", "mapping", "of", "the", "different", "operands", "of", "MI", "on", "the", "register", "bank", "." ]
[ "Mips", "Mips", "Mips::ValueMappings", "Mips::GPRIdx", "Mips::ValueMappings", "Mips::GPRIdx", "0", "32", "Mips::ValueMappings", "Mips::SPRIdx", "Mips::ValueMappings", "Mips::DPRIdx", "Mips::ValueMappings", "Mips::GPRIdx", "Mips::ValueMappings", "Mips::GPRIdx", "Mips::ValueMappings", "Mips::GPRIdx", "Mips::ValueMappings", "Mips::GPRIdx", "Mips::ValueMappings", "Mips::GPRIdx", "Mips::ValueMappings", "Mips::GPRIdx", "Mips::ValueMappings", "Mips::GPRIdx", "Mips::ValueMappings", "Mips::GPRIdx", "1" ]
MipsRegisterBankInfo33
getInstrMapping
Mips
CPU
LLVM
13
409
1
[]
[ "<s>", "uint64_t", "getNullPointerValue", "(", "unsigned", "AddrSpace", ")", "const", "{", "return", "(", "AddrSpace", "==", "AMDGPUAS", "::", "LOCAL_ADDRESS", "||", "AddrSpace", "==", "AMDGPUAS", "::", "REGION_ADDRESS", ")", "?", "-", "1", ":", "0", ";", "}", "</s>" ]
[ "Get", "the", "integer", "value", "of", "a", "null", "pointer", "in", "the", "given", "address", "space", "." ]
[ "AMDGPU", "AMDGPU", "AMDGPU", "1", "0" ]
AMDGPUTargetMachine (2)1
getNullPointerValue
AMDGPU
GPU
LLVM
14
29
1
[]
[ "<s>", "bool", "X86FrameLowering", "::", "hasFP", "(", "const", "MachineFunction", "&", "MF", ")", "const", "{", "const", "MachineFrameInfo", "&", "MFI", "=", "MF", ".", "getFrameInfo", "(", ")", ";", "return", "(", "MF", ".", "getTarget", "(", ")", ".", "Options", ".", "DisableFramePointerElim", "(", "MF", ")", "||", "TRI", "->", "hasStackRealignment", "(", "MF", ")", "||", "MFI", ".", "hasVarSizedObjects", "(", ")", "||", "MFI", ".", "isFrameAddressTaken", "(", ")", "||", "MFI", ".", "hasOpaqueSPAdjustment", "(", ")", "||", "MF", ".", "getInfo", "<", "X86MachineFunctionInfo", ">", "(", ")", "->", "getForceFramePointer", "(", ")", "||", "MF", ".", "getInfo", "<", "X86MachineFunctionInfo", ">", "(", ")", "->", "hasPreallocatedCall", "(", ")", "||", "MF", ".", "callsUnwindInit", "(", ")", "||", "MF", ".", "hasEHFunclets", "(", ")", "||", "MF", ".", "callsEHReturn", "(", ")", "||", "MFI", ".", "hasStackMap", "(", ")", "||", "MFI", ".", "hasPatchPoint", "(", ")", "||", "MFI", ".", "hasCopyImplyingStackAdjustment", "(", ")", ")", ";", "}", "</s>" ]
[ "hasFP", "-", "Return", "true", "if", "the", "specified", "function", "should", "have", "a", "dedicated", "frame", "pointer", "register", "." ]
[ "X86", "X86", "X86", "X86" ]
X86FrameLowering1
hasFP
X86
CPU
LLVM
15
127
1
[]
[ "<s>", "XCoreSubtarget", "::", "XCoreSubtarget", "(", "const", "Triple", "&", "TT", ",", "const", "std", "::", "string", "&", "CPU", ",", "const", "std", "::", "string", "&", "FS", ",", "const", "TargetMachine", "&", "TM", ")", ":", "XCoreGenSubtargetInfo", "(", "TT", ",", "CPU", ",", "CPU", ",", "FS", ")", ",", "FrameLowering", "(", "*", "this", ")", ",", "TLInfo", "(", "TM", ",", "*", "this", ")", "{", "}", "</s>" ]
[ "This", "constructor", "initializes", "the", "data", "members", "to", "match", "that", "of", "the", "specified", "triple", "." ]
[ "XCore", "XCore", "XCore", "XCore" ]
XCoreSubtarget3
XCoreSubtarget
XCore
MPU
LLVM
16
55
1
[]
[ "<s>", "bool", "rs6000_tls_referenced_p", "(", "rtx", "x", ")", "{", "if", "(", "!", "TARGET_HAVE_TLS", ")", "return", "false", ";", "return", "for_each_rtx", "(", "&", "x", ",", "&", "rs6000_tls_symbol_ref_1", ",", "0", ")", ";", "}", "</s>" ]
[ "Return", "1", "if", "X", "contains", "a", "thread-local", "symbol", "." ]
[ "rs6000", "0" ]
rs60003
rs6000_tls_referenced_p
rs6000
CPU
GCC
17
28
1
[]
[ "<s>", "const", "char", "*", "FISCTargetLowering", "::", "getTargetNodeName", "(", "unsigned", "Opcode", ")", "const", "{", "switch", "(", "Opcode", ")", "{", "default", ":", "return", "NULL", ";", "case", "FISCISD", "::", "RET_FLAG", ":", "return", "\"RetFlag\"", ";", "case", "FISCISD", "::", "LOAD_SYM", ":", "return", "\"LOAD_SYM\"", ";", "case", "FISCISD", "::", "MOVEi64", ":", "return", "\"MOVEi64\"", ";", "case", "FISCISD", "::", "CALL", ":", "return", "\"CALL\"", ";", "case", "FISCISD", "::", "SELECT_CC", ":", "return", "\"SELECT_CC\"", ";", "case", "FISCISD", "::", "CMP", ":", "return", "\"CMP\"", ";", "}", "}", "</s>" ]
[ "getTargetNodeName", "-", "This", "method", "returns", "the", "name", "of", "a", "target", "specific" ]
[ "FISC", "FISC", "FISCISD::RET_FLAG", "\"RetFlag\"", "FISCISD::LOAD_SYM", "\"LOAD_SYM\"", "FISCISD::MOVEi64", "\"MOVEi64\"", "FISCISD::CALL", "\"CALL\"", "FISCISD::SELECT_CC", "\"SELECT_CC\"", "FISCISD::CMP", "\"CMP\"" ]
FISCISelLowering
getTargetNodeName
FISC
CPU
LLVM
18
72
1
[]
[ "<s>", "bool", "PPCTargetLowering", "::", "SelectAddressPCRel", "(", "SDValue", "N", ",", "SDValue", "&", "Base", ")", "const", "{", "Base", "=", "N", ";", "if", "(", "N", ".", "getOpcode", "(", ")", "==", "PPCISD", "::", "MAT_PCREL_ADDR", ")", "return", "true", ";", "if", "(", "isValidPCRelNode", "<", "ConstantPoolSDNode", ">", "(", "N", ")", "||", "isValidPCRelNode", "<", "GlobalAddressSDNode", ">", "(", "N", ")", "||", "isValidPCRelNode", "<", "JumpTableSDNode", ">", "(", "N", ")", "||", "isValidPCRelNode", "<", "BlockAddressSDNode", ">", "(", "N", ")", ")", "return", "true", ";", "return", "false", ";", "}", "</s>" ]
[ "SelectAddressPCRel", "-", "Represent", "the", "specified", "address", "as", "pc", "relative", "to", "be", "represented", "as", "[", "pc+imm", "]", "." ]
[ "PowerPC", "PPC", "PPCISD::MAT_PCREL_ADDR" ]
PPCISelLowering100
SelectAddressPCRel
PowerPC
CPU
LLVM
19
74
1
[]
[ "<s>", "unsigned", "AlphaRegisterInfo", "::", "eliminateFrameIndex", "(", "MachineBasicBlock", "::", "iterator", "II", ",", "int", "SPAdj", ",", "FrameIndexValue", "*", "Value", ",", "RegScavenger", "*", "RS", ")", "const", "{", "assert", "(", "SPAdj", "==", "0", "&&", "\"Unexpected\"", ")", ";", "unsigned", "i", "=", "0", ";", "MachineInstr", "&", "MI", "=", "*", "II", ";", "MachineBasicBlock", "&", "MBB", "=", "*", "MI", ".", "getParent", "(", ")", ";", "MachineFunction", "&", "MF", "=", "*", "MBB", ".", "getParent", "(", ")", ";", "bool", "FP", "=", "hasFP", "(", "MF", ")", ";", "while", "(", "!", "MI", ".", "getOperand", "(", "i", ")", ".", "isFI", "(", ")", ")", "{", "++", "i", ";", "assert", "(", "i", "<", "MI", ".", "getNumOperands", "(", ")", "&&", "\"Instr doesn't have FrameIndex operand!\"", ")", ";", "}", "int", "FrameIndex", "=", "MI", ".", "getOperand", "(", "i", ")", ".", "getIndex", "(", ")", ";", "MI", ".", "getOperand", "(", "i", "+", "1", ")", ".", "ChangeToRegister", "(", "FP", "?", "Alpha", "::", "R15", ":", "Alpha", "::", "R30", ",", "false", ")", ";", "int", "Offset", "=", "MF", ".", "getFrameInfo", "(", ")", "->", "getObjectOffset", "(", "FrameIndex", ")", ";", "DEBUG", "(", "errs", "(", ")", "<<", "\"FI: \"", "<<", "FrameIndex", "<<", "\" Offset: \"", "<<", "Offset", "<<", "\"\\n\"", ")", ";", "Offset", "+=", "MF", ".", "getFrameInfo", "(", ")", "->", "getStackSize", "(", ")", ";", "DEBUG", "(", "errs", "(", ")", "<<", "\"Corrected Offset \"", "<<", "Offset", "<<", "\" for stack size: \"", "<<", "MF", ".", "getFrameInfo", "(", ")", "->", "getStackSize", "(", ")", "<<", "\"\\n\"", ")", ";", "if", "(", "Offset", ">", "IMM_HIGH", "||", "Offset", "<", "IMM_LOW", ")", "{", "DEBUG", "(", "errs", "(", ")", "<<", "\"Unconditionally using R28 for evil purposes Offset: \"", "<<", "Offset", "<<", "\"\\n\"", ")", ";", "MI", ".", "getOperand", "(", "i", "+", "1", ")", ".", "ChangeToRegister", "(", "Alpha", "::", "R28", ",", "false", ")", ";", "MI", ".", "getOperand", "(", "i", ")", ".", "ChangeToImmediate", "(", "getLower16", "(", "Offset", ")", ")", ";", "MachineInstr", "*", "nMI", "=", "BuildMI", "(", "MF", ",", "MI", ".", "getDebugLoc", "(", ")", ",", "TII", ".", "get", "(", "Alpha", "::", "LDAH", ")", ",", "Alpha", "::", "R28", ")", ".", "addImm", "(", "getUpper16", "(", "Offset", ")", ")", ".", "addReg", "(", "FP", "?", "Alpha", "::", "R15", ":", "Alpha", "::", "R30", ")", ";", "MBB", ".", "insert", "(", "II", ",", "nMI", ")", ";", "}", "else", "{", "MI", ".", "getOperand", "(", "i", ")", ".", "ChangeToImmediate", "(", "Offset", ")", ";", "}", "return", "0", ";", "}", "</s>" ]
[ "This", "method", "must", "be", "overriden", "to", "eliminate", "abstract", "frame", "indices", "from", "instructions", "which", "may", "use", "them", "." ]
[ "Alpha", "Alpha", "0", "\"Unexpected\"", "0", "\"Instr doesn't have FrameIndex operand!\"", "1", "Alpha::R15", "Alpha::R30", "\"FI: \"", "\" Offset: \"", "\"\\n\"", "\"Corrected Offset \"", "\" for stack size: \"", "\"\\n\"", "\"Unconditionally using R28 for evil purposes Offset: \"", "\"\\n\"", "1", "Alpha::R28", "Alpha::LDAH", "Alpha::R28", "Alpha::R15", "Alpha::R30", "0" ]
AlphaRegisterInfo
eliminateFrameIndex
Alpha
MPU
LLVM
20
347
1
[]
[ "<s>", "static", "void", "ia64_copy_rbs", "(", "struct", "_Unwind_Context", "*", "info", ",", "unsigned", "long", "dst", ",", "unsigned", "long", "src", ",", "long", "len", ",", "unsigned", "long", "dst_rnat", ")", "{", "long", "count", ";", "unsigned", "long", "src_rnat", ";", "unsigned", "long", "shift1", ",", "shift2", ";", "len", "<<=", "3", ";", "dst_rnat", "&=", "(", "1UL", "<<", "(", "(", "dst", ">>", "3", ")", "&", "0x3f", ")", ")", "-", "1", ";", "src_rnat", "=", "src", ">=", "info", "->", "regstk_top", "?", "info", "->", "rnat", ":", "*", "(", "unsigned", "long", "*", ")", "(", "src", "|", "0x1f8", ")", ";", "src_rnat", "&=", "~", "(", "(", "1UL", "<<", "(", "(", "src", ">>", "3", ")", "&", "0x3f", ")", ")", "-", "1", ")", ";", "src_rnat", "&=", "~", "(", "1UL", "<<", "63", ")", ";", "shift1", "=", "(", "(", "dst", "-", "src", ")", ">>", "3", ")", "&", "0x3f", ";", "if", "(", "(", "dst", "&", "0x1f8", ")", "<", "(", "src", "&", "0x1f8", ")", ")", "shift1", "--", ";", "shift2", "=", "0x3f", "-", "shift1", ";", "if", "(", "(", "dst", "&", "0x1f8", ")", ">=", "(", "src", "&", "0x1f8", ")", ")", "{", "count", "=", "~", "dst", "&", "0x1f8", ";", "goto", "first", ";", "}", "count", "=", "~", "src", "&", "0x1f8", ";", "goto", "second", ";", "while", "(", "len", ">", "0", ")", "{", "src_rnat", "=", "src", ">=", "info", "->", "regstk_top", "?", "info", "->", "rnat", ":", "*", "(", "unsigned", "long", "*", ")", "(", "src", "|", "0x1f8", ")", ";", "src_rnat", "&=", "~", "(", "1UL", "<<", "63", ")", ";", "count", "=", "shift2", "<<", "3", ";", "first", ":", "if", "(", "count", ">", "len", ")", "count", "=", "len", ";", "memcpy", "(", "(", "char", "*", ")", "dst", ",", "(", "char", "*", ")", "src", ",", "count", ")", ";", "dst", "+=", "count", ";", "src", "+=", "count", ";", "len", "-=", "count", ";", "dst_rnat", "|=", "(", "src_rnat", "<<", "shift1", ")", "&", "~", "(", "1UL", "<<", "63", ")", ";", "if", "(", "len", "<=", "0", ")", "break", ";", "*", "(", "long", "*", ")", "dst", "=", "dst_rnat", ";", "dst", "+=", "8", ";", "dst_rnat", "=", "0", ";", "count", "=", "shift1", "<<", "3", ";", "second", ":", "if", "(", "count", ">", "len", ")", "count", "=", "len", ";", "memcpy", "(", "(", "char", "*", ")", "dst", ",", "(", "char", "*", ")", "src", ",", "count", ")", ";", "dst", "+=", "count", ";", "src", "+=", "count", "+", "8", ";", "len", "-=", "count", "+", "8", ";", "dst_rnat", "|=", "(", "src_rnat", ">>", "shift2", ")", ";", "}", "if", "(", "(", "dst", "&", "0x1f8", ")", "==", "0x1f8", ")", "{", "*", "(", "long", "*", ")", "dst", "=", "dst_rnat", ";", "dst", "+=", "8", ";", "dst_rnat", "=", "0", ";", "}", "info", "->", "regstk_top", "=", "dst", "&", "~", "0x1ffUL", ";", "info", "->", "rnat", "=", "dst_rnat", ";", "}", "</s>" ]
[ "Copy", "register", "backing", "store", "from", "SRC", "to", "DST", ",", "LEN", "words", "(", "which", "include", "both", "saved", "registers", "and", "nat", "collections", ")", ".", "DST_RNAT", "is", "a", "partial", "nat", "collection", "for", "DST", ".", "SRC", "and", "DST", "do", "n't", "have", "to", "be", "equal", "modulo", "64", "slots", ",", "so", "it", "can", "not", "be", "done", "with", "a", "simple", "memcpy", "as", "the", "nat", "collections", "will", "be", "at", "different", "relative", "offsets", "and", "need", "to", "be", "combined", "together", "." ]
[ "ia64", "3", "1UL", "3", "0x3f", "1", "0x1f8", "1UL", "3", "0x3f", "1", "1UL", "63", "3", "0x3f", "0x1f8", "0x1f8", "0x3f", "0x1f8", "0x1f8", "0x1f8", "0x1f8", "0", "0x1f8", "1UL", "63", "3", "1UL", "63", "0", "8", "0", "3", "8", "8", "0x1f8", "0x1f8", "8", "0", "0x1ffUL" ]
unwind-ia641
ia64_copy_rbs
ia64
CPU
GCC
21
419
1
[]
[ "<s>", "unsigned", "SIInstrInfo", "::", "isStoreToStackSlot", "(", "const", "MachineInstr", "&", "MI", ",", "int", "&", "FrameIndex", ")", "const", "{", "if", "(", "!", "MI", ".", "mayStore", "(", ")", ")", "return", "AMDGPU", "::", "NoRegister", ";", "if", "(", "isMUBUF", "(", "MI", ")", "||", "isVGPRSpill", "(", "MI", ")", ")", "return", "isStackAccess", "(", "MI", ",", "FrameIndex", ")", ";", "if", "(", "isSGPRSpill", "(", "MI", ")", ")", "return", "isSGPRStackAccess", "(", "MI", ",", "FrameIndex", ")", ";", "return", "AMDGPU", "::", "NoRegister", ";", "}", "</s>" ]
[ "isStoreToStackSlot", "-", "If", "the", "specified", "machine", "instruction", "is", "a", "direct", "store", "to", "a", "stack", "slot", ",", "return", "the", "virtual", "or", "physical", "register", "number", "of", "the", "source", "reg", "along", "with", "the", "FrameIndex", "of", "the", "loaded", "stack", "slot", "." ]
[ "AMDGPU", "SI", "AMDGPU::NoRegister", "AMDGPU::NoRegister" ]
SIInstrInfo (2)
isStoreToStackSlot
AMDGPU
GPU
LLVM
22
71
1
[]
[ "<s>", "void", "rs6000_asm_output_dwarf_pcrel", "(", "FILE", "*", "file", ",", "int", "size", ",", "const", "char", "*", "label", ")", "{", "fputs", "(", "integer_asm_op", "(", "size", ",", "FALSE", ")", ",", "file", ")", ";", "assemble_name", "(", "file", ",", "label", ")", ";", "fputs", "(", "\"-$\"", ",", "file", ")", ";", "}", "</s>" ]
[ "Overide", "the", "default", "'SYMBOL-", ".", "'", "syntax", "with", "AIX", "compatible", "'SYMBOL-", "$", "'", "." ]
[ "rs6000", "\"-$\"" ]
rs6000
rs6000_asm_output_dwarf_pcrel
rs6000
CPU
GCC
23
43
1
[]
[ "<s>", "static", "struct", "machine_function", "*", "tilepro_init_machine_status", "(", "void", ")", "{", "return", "ggc_cleared_alloc", "<", "machine_function", ">", "(", ")", ";", "}", "</s>" ]
[ "Functions", "to", "save", "and", "restore", "machine-specific", "function", "data", "." ]
[ "tilepro" ]
tilepro
tilepro_init_machine_status
tilepro
VLIW
GCC
24
18
1
[]
[ "<s>", "bool", "vax_legitimate_address_p", "(", "machine_mode", "mode", ",", "rtx", "x", ",", "bool", "strict", ")", "{", "rtx", "xfoo0", ",", "xfoo1", ";", "if", "(", "nonindexed_address_p", "(", "x", ",", "strict", ")", ")", "return", "true", ";", "if", "(", "GET_CODE", "(", "x", ")", "!=", "PLUS", ")", "return", "false", ";", "xfoo0", "=", "XEXP", "(", "x", ",", "0", ")", ";", "xfoo1", "=", "XEXP", "(", "x", ",", "1", ")", ";", "if", "(", "index_term_p", "(", "xfoo0", ",", "mode", ",", "strict", ")", "&&", "nonindexed_address_p", "(", "xfoo1", ",", "strict", ")", ")", "return", "true", ";", "if", "(", "index_term_p", "(", "xfoo1", ",", "mode", ",", "strict", ")", "&&", "nonindexed_address_p", "(", "xfoo0", ",", "strict", ")", ")", "return", "true", ";", "if", "(", "indexable_address_p", "(", "xfoo0", ",", "xfoo1", ",", "mode", ",", "strict", ")", "||", "indexable_address_p", "(", "xfoo1", ",", "xfoo0", ",", "mode", ",", "strict", ")", ")", "return", "true", ";", "return", "false", ";", "}", "</s>" ]
[ "legitimate_address_p", "returns", "true", "if", "it", "recognizes", "an", "RTL", "expression", "``", "x", "''", "that", "is", "a", "valid", "memory", "address", "for", "an", "instruction", ".", "The", "MODE", "argument", "is", "the", "machine", "mode", "for", "the", "MEM", "expression", "that", "wants", "to", "use", "this", "address", "." ]
[ "vax", "0", "1" ]
vax
vax_legitimate_address_p
vax
CPU
GCC
25
133
1
[]
[ "<s>", "StringRef", "getPassName", "(", ")", "const", "override", "{", "return", "\"X86 avoid trailing call pass\"", ";", "}", "</s>" ]
[ "getPassName", "-", "Return", "a", "nice", "clean", "name", "for", "a", "pass", "." ]
[ "X86", "\"X86 avoid trailing call pass\"" ]
X86AvoidTrailingCall3
getPassName
X86
CPU
LLVM
26
11
1
[]
[ "<s>", "static", "inline", "ChildIteratorType", "child_begin", "(", "NodeRef", "N", ")", "{", "return", "N", "->", "getChildren", "(", ")", ".", "begin", "(", ")", ";", "}", "</s>" ]
[ "nodes_iterator/begin/end", "-", "Allow", "iteration", "over", "all", "nodes", "in", "the", "graph" ]
[ "Patmos" ]
PatmosStackCacheAnalysis1
child_begin
Patmos
VLIW
LLVM
27
21
1
[]
[ "<s>", "bool", "easy_altivec_constant", "(", "rtx", "op", ",", "enum", "machine_mode", "mode", ")", "{", "unsigned", "step", ",", "copies", ";", "if", "(", "mode", "==", "VOIDmode", ")", "mode", "=", "GET_MODE", "(", "op", ")", ";", "else", "if", "(", "mode", "!=", "GET_MODE", "(", "op", ")", ")", "return", "false", ";", "step", "=", "GET_MODE_NUNITS", "(", "mode", ")", "/", "4", ";", "copies", "=", "1", ";", "if", "(", "vspltis_constant", "(", "op", ",", "step", ",", "copies", ")", ")", "return", "true", ";", "if", "(", "step", "==", "1", ")", "copies", "<<=", "1", ";", "else", "step", ">>=", "1", ";", "if", "(", "vspltis_constant", "(", "op", ",", "step", ",", "copies", ")", ")", "return", "true", ";", "if", "(", "step", "==", "1", ")", "copies", "<<=", "1", ";", "else", "step", ">>=", "1", ";", "if", "(", "vspltis_constant", "(", "op", ",", "step", ",", "copies", ")", ")", "return", "true", ";", "return", "false", ";", "}", "</s>" ]
[ "Return", "true", "if", "OP", "is", "of", "the", "given", "MODE", "and", "can", "be", "synthesized", "with", "a", "vspltisb", ",", "vspltish", "or", "vspltisw", "." ]
[ "rs6000", "4", "1", "1", "1", "1", "1", "1", "1" ]
rs60003
easy_altivec_constant
rs6000
CPU
GCC
28
131
1
[]
[ "<s>", "bool", "AArch64PassConfig", "::", "addIRTranslator", "(", ")", "{", "addPass", "(", "new", "IRTranslator", "(", "getOptLevel", "(", ")", ")", ")", ";", "return", "false", ";", "}", "</s>" ]
[ "This", "method", "should", "install", "an", "IR", "translator", "pass", ",", "which", "converts", "from", "LLVM", "code", "to", "machine", "instructions", "with", "possibly", "generic", "opcodes", "." ]
[ "AArch64", "AArch64" ]
AArch64TargetMachine1
addIRTranslator
AArch64
CPU
LLVM
29
22
1
[]
[ "<s>", "void", "GCNPassConfig", "::", "addPreEmitPass", "(", ")", "{", "addPass", "(", "createSIInsertWaits", "(", "*", "TM", ")", ",", "false", ")", ";", "addPass", "(", "createSILowerControlFlowPass", "(", "*", "TM", ")", ",", "false", ")", ";", "}", "</s>" ]
[ "This", "pass", "may", "be", "implemented", "by", "targets", "that", "want", "to", "run", "passes", "immediately", "before", "machine", "code", "is", "emitted", "." ]
[ "AMDGPU", "SI", "SI" ]
AMDGPUTargetMachine (2)
addPreEmitPass
AMDGPU
GPU
LLVM
30
30
1
[]
[ "<s>", "unsigned", "AArch64InstrInfo", "::", "getLoadStoreImmIdx", "(", "unsigned", "Opc", ")", "{", "switch", "(", "Opc", ")", "{", "default", ":", "return", "2", ";", "case", "AArch64", "::", "LDPXi", ":", "case", "AArch64", "::", "LDPDi", ":", "case", "AArch64", "::", "STPXi", ":", "case", "AArch64", "::", "STPDi", ":", "case", "AArch64", "::", "LDNPXi", ":", "case", "AArch64", "::", "LDNPDi", ":", "case", "AArch64", "::", "STNPXi", ":", "case", "AArch64", "::", "STNPDi", ":", "case", "AArch64", "::", "LDPQi", ":", "case", "AArch64", "::", "STPQi", ":", "case", "AArch64", "::", "LDNPQi", ":", "case", "AArch64", "::", "STNPQi", ":", "case", "AArch64", "::", "LDPWi", ":", "case", "AArch64", "::", "LDPSi", ":", "case", "AArch64", "::", "STPWi", ":", "case", "AArch64", "::", "STPSi", ":", "case", "AArch64", "::", "LDNPWi", ":", "case", "AArch64", "::", "LDNPSi", ":", "case", "AArch64", "::", "STNPWi", ":", "case", "AArch64", "::", "STNPSi", ":", "case", "AArch64", "::", "LDG", ":", "case", "AArch64", "::", "STGPi", ":", "case", "AArch64", "::", "LD1B_IMM", ":", "case", "AArch64", "::", "LD1H_IMM", ":", "case", "AArch64", "::", "LD1W_IMM", ":", "case", "AArch64", "::", "LD1D_IMM", ":", "case", "AArch64", "::", "ST1B_IMM", ":", "case", "AArch64", "::", "ST1H_IMM", ":", "case", "AArch64", "::", "ST1W_IMM", ":", "case", "AArch64", "::", "ST1D_IMM", ":", "case", "AArch64", "::", "LD1B_H_IMM", ":", "case", "AArch64", "::", "LD1SB_H_IMM", ":", "case", "AArch64", "::", "LD1H_S_IMM", ":", "case", "AArch64", "::", "LD1SH_S_IMM", ":", "case", "AArch64", "::", "LD1W_D_IMM", ":", "case", "AArch64", "::", "LD1SW_D_IMM", ":", "case", "AArch64", "::", "ST1B_H_IMM", ":", "case", "AArch64", "::", "ST1H_S_IMM", ":", "case", "AArch64", "::", "ST1W_D_IMM", ":", "case", "AArch64", "::", "LD1B_S_IMM", ":", "case", "AArch64", "::", "LD1SB_S_IMM", ":", "case", "AArch64", "::", "LD1H_D_IMM", ":", "case", "AArch64", "::", "LD1SH_D_IMM", ":", "case", "AArch64", "::", "ST1B_S_IMM", ":", "case", "AArch64", "::", "ST1H_D_IMM", ":", "case", "AArch64", "::", "LD1B_D_IMM", ":", "case", "AArch64", "::", "LD1SB_D_IMM", ":", "case", "AArch64", "::", "ST1B_D_IMM", ":", "return", "3", ";", "case", "AArch64", "::", "ADDG", ":", "case", "AArch64", "::", "STGOffset", ":", "case", "AArch64", "::", "LDR_PXI", ":", "case", "AArch64", "::", "STR_PXI", ":", "return", "2", ";", "}", "}", "</s>" ]
[ "Returns", "the", "index", "for", "the", "immediate", "for", "a", "given", "instruction", "." ]
[ "AArch64", "AArch64", "2", "AArch64::LDPXi", "AArch64::LDPDi", "AArch64::STPXi", "AArch64::STPDi", "AArch64::LDNPXi", "AArch64::LDNPDi", "AArch64::STNPXi", "AArch64::STNPDi", "AArch64::LDPQi", "AArch64::STPQi", "AArch64::LDNPQi", "AArch64::STNPQi", "AArch64::LDPWi", "AArch64::LDPSi", "AArch64::STPWi", "AArch64::STPSi", "AArch64::LDNPWi", "AArch64::LDNPSi", "AArch64::STNPWi", "AArch64::STNPSi", "AArch64::LDG", "AArch64::STGPi", "AArch64::LD1B_IMM", "AArch64::LD1H_IMM", "AArch64::LD1W_IMM", "AArch64::LD1D_IMM", "AArch64::ST1B_IMM", "AArch64::ST1H_IMM", "AArch64::ST1W_IMM", "AArch64::ST1D_IMM", "AArch64::LD1B_H_IMM", "AArch64::LD1SB_H_IMM", "AArch64::LD1H_S_IMM", "AArch64::LD1SH_S_IMM", "AArch64::LD1W_D_IMM", "AArch64::LD1SW_D_IMM", "AArch64::ST1B_H_IMM", "AArch64::ST1H_S_IMM", "AArch64::ST1W_D_IMM", "AArch64::LD1B_S_IMM", "AArch64::LD1SB_S_IMM", "AArch64::LD1H_D_IMM", "AArch64::LD1SH_D_IMM", "AArch64::ST1B_S_IMM", "AArch64::ST1H_D_IMM", "AArch64::LD1B_D_IMM", "AArch64::LD1SB_D_IMM", "AArch64::ST1B_D_IMM", "3", "AArch64::ADDG", "AArch64::STGOffset", "AArch64::LDR_PXI", "AArch64::STR_PXI", "2" ]
AArch64InstrInfo107
getLoadStoreImmIdx
AArch64
CPU
LLVM
31
287
1
[]
[ "<s>", "bool", "XCoreRegisterInfo", "::", "needsFrameMoves", "(", "const", "MachineFunction", "&", "MF", ")", "{", "return", "MF", ".", "needsFrameMoves", "(", ")", ";", "}", "</s>" ]
[ "Return", "whether", "to", "emit", "frame", "moves", "." ]
[ "XCore", "XCore" ]
XCoreRegisterInfo (2)1
needsFrameMoves
XCore
MPU
LLVM
32
19
1
[]
[ "<s>", "MCSymbol", "*", "X86MCInstLower", "::", "GetSymbolFromOperand", "(", "const", "MachineOperand", "&", "MO", ")", "const", "{", "const", "DataLayout", "&", "DL", "=", "MF", ".", "getDataLayout", "(", ")", ";", "assert", "(", "(", "MO", ".", "isGlobal", "(", ")", "||", "MO", ".", "isSymbol", "(", ")", "||", "MO", ".", "isMBB", "(", ")", ")", "&&", "\"Isn't a symbol reference\"", ")", ";", "MCSymbol", "*", "Sym", "=", "nullptr", ";", "SmallString", "<", "128", ">", "Name", ";", "StringRef", "Suffix", ";", "switch", "(", "MO", ".", "getTargetFlags", "(", ")", ")", "{", "case", "X86II", "::", "MO_DLLIMPORT", ":", "Name", "+=", "\"__imp_\"", ";", "break", ";", "case", "X86II", "::", "MO_DARWIN_STUB", ":", "Suffix", "=", "\"$stub\"", ";", "break", ";", "case", "X86II", "::", "MO_DARWIN_NONLAZY", ":", "case", "X86II", "::", "MO_DARWIN_NONLAZY_PIC_BASE", ":", "Suffix", "=", "\"$non_lazy_ptr\"", ";", "break", ";", "}", "if", "(", "!", "Suffix", ".", "empty", "(", ")", ")", "Name", "+=", "DL", ".", "getPrivateGlobalPrefix", "(", ")", ";", "unsigned", "PrefixLen", "=", "Name", ".", "size", "(", ")", ";", "if", "(", "MO", ".", "isGlobal", "(", ")", ")", "{", "const", "GlobalValue", "*", "GV", "=", "MO", ".", "getGlobal", "(", ")", ";", "AsmPrinter", ".", "getNameWithPrefix", "(", "Name", ",", "GV", ")", ";", "}", "else", "if", "(", "MO", ".", "isSymbol", "(", ")", ")", "{", "Mangler", "::", "getNameWithPrefix", "(", "Name", ",", "MO", ".", "getSymbolName", "(", ")", ",", "DL", ")", ";", "}", "else", "if", "(", "MO", ".", "isMBB", "(", ")", ")", "{", "assert", "(", "Suffix", ".", "empty", "(", ")", ")", ";", "Sym", "=", "MO", ".", "getMBB", "(", ")", "->", "getSymbol", "(", ")", ";", "}", "unsigned", "OrigLen", "=", "Name", ".", "size", "(", ")", "-", "PrefixLen", ";", "Name", "+=", "Suffix", ";", "if", "(", "!", "Sym", ")", "Sym", "=", "Ctx", ".", "getOrCreateSymbol", "(", "Name", ")", ";", "StringRef", "OrigName", "=", "StringRef", "(", "Name", ")", ".", "substr", "(", "PrefixLen", ",", "OrigLen", ")", ";", "switch", "(", "MO", ".", "getTargetFlags", "(", ")", ")", "{", "default", ":", "break", ";", "case", "X86II", "::", "MO_DARWIN_NONLAZY", ":", "case", "X86II", "::", "MO_DARWIN_NONLAZY_PIC_BASE", ":", "{", "MachineModuleInfoImpl", "::", "StubValueTy", "&", "StubSym", "=", "getMachOMMI", "(", ")", ".", "getGVStubEntry", "(", "Sym", ")", ";", "if", "(", "!", "StubSym", ".", "getPointer", "(", ")", ")", "{", "assert", "(", "MO", ".", "isGlobal", "(", ")", "&&", "\"Extern symbol not handled yet\"", ")", ";", "StubSym", "=", "MachineModuleInfoImpl", "::", "StubValueTy", "(", "AsmPrinter", ".", "getSymbol", "(", "MO", ".", "getGlobal", "(", ")", ")", ",", "!", "MO", ".", "getGlobal", "(", ")", "->", "hasInternalLinkage", "(", ")", ")", ";", "}", "break", ";", "}", "case", "X86II", "::", "MO_DARWIN_STUB", ":", "{", "MachineModuleInfoImpl", "::", "StubValueTy", "&", "StubSym", "=", "getMachOMMI", "(", ")", ".", "getFnStubEntry", "(", "Sym", ")", ";", "if", "(", "StubSym", ".", "getPointer", "(", ")", ")", "return", "Sym", ";", "if", "(", "MO", ".", "isGlobal", "(", ")", ")", "{", "StubSym", "=", "MachineModuleInfoImpl", "::", "StubValueTy", "(", "AsmPrinter", ".", "getSymbol", "(", "MO", ".", "getGlobal", "(", ")", ")", ",", "!", "MO", ".", "getGlobal", "(", ")", "->", "hasInternalLinkage", "(", ")", ")", ";", "}", "else", "{", "StubSym", "=", "MachineModuleInfoImpl", "::", "StubValueTy", "(", "Ctx", ".", "getOrCreateSymbol", "(", "OrigName", ")", ",", "false", ")", ";", "}", "break", ";", "}", "}", "return", "Sym", ";", "}", "</s>" ]
[ "Lower", "an", "MO_GlobalAddress", "or", "MO_ExternalSymbol", "operand", "to", "an", "MCSymbol", "." ]
[ "X86", "X86", "\"Isn't a symbol reference\"", "128", "X86II::MO_DLLIMPORT", "\"__imp_\"", "X86II::MO_DARWIN_STUB", "\"$stub\"", "X86II::MO_DARWIN_NONLAZY", "X86II::MO_DARWIN_NONLAZY_PIC_BASE", "\"$non_lazy_ptr\"", "X86II::MO_DARWIN_NONLAZY", "X86II::MO_DARWIN_NONLAZY_PIC_BASE", "\"Extern symbol not handled yet\"", "X86II::MO_DARWIN_STUB" ]
X86MCInstLower113
GetSymbolFromOperand
X86
CPU
LLVM
33
461
1
[]
[ "<s>", "TargetPassConfig", "*", "MMIXTargetMachine", "::", "createPassConfig", "(", "PassManagerBase", "&", "PM", ")", "{", "return", "new", "MMIXPassConfig", "(", "*", "this", ",", "PM", ")", ";", "}", "</s>" ]
[ "Create", "a", "pass", "configuration", "object", "to", "be", "used", "by", "addPassToEmitX", "methods", "for", "generating", "a", "pipeline", "of", "CodeGen", "passes", "." ]
[ "MMIX", "MMIX", "MMIX" ]
MMIXTargetMachine
createPassConfig
MMIX
CPU
LLVM
34
22
1
[]
[ "<s>", "void", "X86FrameLowering", "::", "emitSPUpdate", "(", "MachineBasicBlock", "&", "MBB", ",", "MachineBasicBlock", "::", "iterator", "&", "MBBI", ",", "int64_t", "NumBytes", ",", "bool", "InEpilogue", ")", "const", "{", "bool", "isSub", "=", "NumBytes", "<", "0", ";", "uint64_t", "Offset", "=", "isSub", "?", "-", "NumBytes", ":", "NumBytes", ";", "uint64_t", "Chunk", "=", "(", "1LL", "<<", "31", ")", "-", "1", ";", "DebugLoc", "DL", "=", "MBB", ".", "findDebugLoc", "(", "MBBI", ")", ";", "if", "(", "Offset", "==", "0", ")", "{", "MachineInstrBuilder", "MI", "=", "BuildMI", "(", "MBB", ",", "MBBI", ",", "DL", ",", "TII", ".", "get", "(", "X86", "::", "SUB64ri8", ")", ",", "StackPtr", ")", ".", "addReg", "(", "StackPtr", ")", ".", "addImm", "(", "0", ")", ";", "if", "(", "!", "InEpilogue", ")", "MI", ".", "setMIFlag", "(", "MachineInstr", "::", "FrameSetup", ")", ";", "else", "MI", ".", "setMIFlag", "(", "MachineInstr", "::", "FrameDestroy", ")", ";", "}", "while", "(", "Offset", ")", "{", "if", "(", "Offset", ">", "Chunk", ")", "{", "unsigned", "Reg", "=", "0", ";", "if", "(", "isSub", "&&", "!", "isEAXLiveIn", "(", "MBB", ")", ")", "Reg", "=", "(", "unsigned", ")", "(", "Is64Bit", "?", "X86", "::", "RAX", ":", "X86", "::", "EAX", ")", ";", "else", "Reg", "=", "findDeadCallerSavedReg", "(", "MBB", ",", "MBBI", ",", "TRI", ",", "Is64Bit", ")", ";", "if", "(", "Reg", ")", "{", "unsigned", "Opc", "=", "Is64Bit", "?", "X86", "::", "MOV64ri", ":", "X86", "::", "MOV32ri", ";", "BuildMI", "(", "MBB", ",", "MBBI", ",", "DL", ",", "TII", ".", "get", "(", "Opc", ")", ",", "Reg", ")", ".", "addImm", "(", "Offset", ")", ";", "Opc", "=", "isSub", "?", "getSUBrrOpcode", "(", "Is64Bit", ")", ":", "getADDrrOpcode", "(", "Is64Bit", ")", ";", "MachineInstr", "*", "MI", "=", "BuildMI", "(", "MBB", ",", "MBBI", ",", "DL", ",", "TII", ".", "get", "(", "Opc", ")", ",", "StackPtr", ")", ".", "addReg", "(", "StackPtr", ")", ".", "addReg", "(", "Reg", ")", ";", "MI", "->", "getOperand", "(", "3", ")", ".", "setIsDead", "(", ")", ";", "Offset", "=", "0", ";", "continue", ";", "}", "}", "uint64_t", "ThisVal", "=", "std", "::", "min", "(", "Offset", ",", "Chunk", ")", ";", "if", "(", "ThisVal", "==", "(", "Is64Bit", "?", "8", ":", "4", ")", "&&", "false", ")", "{", "unsigned", "Reg", "=", "isSub", "?", "(", "unsigned", ")", "(", "Is64Bit", "?", "X86", "::", "RAX", ":", "X86", "::", "EAX", ")", ":", "findDeadCallerSavedReg", "(", "MBB", ",", "MBBI", ",", "TRI", ",", "Is64Bit", ")", ";", "if", "(", "Reg", ")", "{", "unsigned", "Opc", "=", "isSub", "?", "(", "Is64Bit", "?", "X86", "::", "PUSH64r", ":", "X86", "::", "PUSH32r", ")", ":", "(", "Is64Bit", "?", "X86", "::", "POP64r", ":", "X86", "::", "POP32r", ")", ";", "MachineInstr", "*", "MI", "=", "BuildMI", "(", "MBB", ",", "MBBI", ",", "DL", ",", "TII", ".", "get", "(", "Opc", ")", ")", ".", "addReg", "(", "Reg", ",", "getDefRegState", "(", "!", "isSub", ")", "|", "getUndefRegState", "(", "isSub", ")", ")", ";", "if", "(", "isSub", ")", "MI", "->", "setFlag", "(", "MachineInstr", "::", "FrameSetup", ")", ";", "else", "MI", "->", "setFlag", "(", "MachineInstr", "::", "FrameDestroy", ")", ";", "Offset", "-=", "ThisVal", ";", "continue", ";", "}", "}", "MachineInstrBuilder", "MI", "=", "BuildStackAdjustment", "(", "MBB", ",", "MBBI", ",", "DL", ",", "isSub", "?", "-", "ThisVal", ":", "ThisVal", ",", "InEpilogue", ")", ";", "if", "(", "isSub", ")", "MI", ".", "setMIFlag", "(", "MachineInstr", "::", "FrameSetup", ")", ";", "else", "MI", ".", "setMIFlag", "(", "MachineInstr", "::", "FrameDestroy", ")", ";", "Offset", "-=", "ThisVal", ";", "}", "}", "</s>" ]
[ "Emit", "a", "series", "of", "instructions", "to", "increment", "/", "decrement", "the", "stack", "pointer", "by", "a", "constant", "value", "." ]
[ "X86", "X86", "0", "1LL", "31", "1", "0", "X86::SUB64ri8", "0", "0", "X86::RAX", "X86::EAX", "X86::MOV64ri", "X86::MOV32ri", "3", "0", "8", "4", "X86::RAX", "X86::EAX", "X86::PUSH64r", "X86::PUSH32r", "X86::POP64r", "X86::POP32r" ]
X86FrameLowering8
emitSPUpdate
X86
CPU
LLVM
35
499
1
[]
[ "<s>", "void", "HexagonInstPrinter", "::", "printInst", "(", "const", "MCInst", "*", "MI", ",", "raw_ostream", "&", "OS", ",", "StringRef", "Annot", ",", "const", "MCSubtargetInfo", "&", "STI", ")", "{", "assert", "(", "HexagonMCInstrInfo", "::", "isBundle", "(", "*", "MI", ")", ")", ";", "assert", "(", "HexagonMCInstrInfo", "::", "bundleSize", "(", "*", "MI", ")", "<=", "HEXAGON_PACKET_SIZE", ")", ";", "assert", "(", "HexagonMCInstrInfo", "::", "bundleSize", "(", "*", "MI", ")", ">", "0", ")", ";", "HasExtender", "=", "false", ";", "for", "(", "auto", "const", "&", "I", ":", "HexagonMCInstrInfo", "::", "bundleInstructions", "(", "*", "MI", ")", ")", "{", "MCInst", "const", "&", "MCI", "=", "*", "I", ".", "getInst", "(", ")", ";", "if", "(", "HexagonMCInstrInfo", "::", "isDuplex", "(", "MII", ",", "MCI", ")", ")", "{", "printInstruction", "(", "MCI", ".", "getOperand", "(", "1", ")", ".", "getInst", "(", ")", ",", "OS", ")", ";", "OS", "<<", "'\\v'", ";", "HasExtender", "=", "false", ";", "printInstruction", "(", "MCI", ".", "getOperand", "(", "0", ")", ".", "getInst", "(", ")", ",", "OS", ")", ";", "}", "else", "printInstruction", "(", "&", "MCI", ",", "OS", ")", ";", "setExtender", "(", "MCI", ")", ";", "OS", "<<", "\"\\n\"", ";", "}", "bool", "IsLoop0", "=", "HexagonMCInstrInfo", "::", "isInnerLoop", "(", "*", "MI", ")", ";", "bool", "IsLoop1", "=", "HexagonMCInstrInfo", "::", "isOuterLoop", "(", "*", "MI", ")", ";", "if", "(", "IsLoop0", ")", "{", "OS", "<<", "(", "IsLoop1", "?", "\" :endloop01\"", ":", "\" :endloop0\"", ")", ";", "}", "else", "if", "(", "IsLoop1", ")", "{", "OS", "<<", "\" :endloop1\"", ";", "}", "}", "</s>" ]
[ "Print", "the", "specified", "MCInst", "to", "the", "specified", "raw_ostream", "." ]
[ "Hexagon", "Hexagon", "Hexagon", "Hexagon", "Hexagon", "0", "Hexagon", "Hexagon", "1", "0", "\"\\n\"", "Hexagon", "Hexagon", "\" :endloop01\"", "\" :endloop0\"", "\" :endloop1\"" ]
HexagonInstPrinter9
printInst
Hexagon
DSP
LLVM
36
214
1
[]
[ "<s>", "static", "bool", "ix86_secondary_memory_needed", "(", "machine_mode", "mode", ",", "reg_class_t", "class1", ",", "reg_class_t", "class2", ")", "{", "return", "inline_secondary_memory_needed", "(", "mode", ",", "class1", ",", "class2", ",", "true", ")", ";", "}", "</s>" ]
[ "If", "we", "are", "copying", "between", "general", "and", "FP", "registers", ",", "we", "need", "a", "memory", "location", ".", "The", "same", "is", "true", "for", "SSE", "and", "MMX", "registers", ".", "The", "macro", "ca", "n't", "work", "reliably", "when", "one", "of", "the", "CLASSES", "is", "class", "containing", "registers", "from", "multiple", "units", "(", "SSE", ",", "MMX", ",", "integer", ")", ".", "We", "avoid", "this", "by", "never", "combining", "those", "units", "in", "single", "alternative", "in", "the", "machine", "description", ".", "Ensure", "that", "this", "constraint", "holds", "to", "avoid", "unexpected", "surprises", ".", "When", "STRICT", "is", "false", ",", "we", "are", "being", "called", "from", "REGISTER_MOVE_COST", ",", "so", "do", "not", "enforce", "these", "sanity", "checks", "." ]
[ "i386" ]
i386
ix86_secondary_memory_needed
i386
CPU
GCC
37
27
1
[]
[ "<s>", "void", "R600SchedStrategy", "::", "schedNode", "(", "SUnit", "*", "SU", ",", "bool", "IsTopNode", ")", "{", "if", "(", "NextInstKind", "!=", "CurInstKind", ")", "{", "LLVM_DEBUG", "(", "dbgs", "(", ")", "<<", "\"Instruction Type Switch\\n\"", ")", ";", "if", "(", "NextInstKind", "!=", "IDAlu", ")", "OccupiedSlotsMask", "|=", "31", ";", "CurEmitted", "=", "0", ";", "CurInstKind", "=", "NextInstKind", ";", "}", "if", "(", "CurInstKind", "==", "IDAlu", ")", "{", "AluInstCount", "++", ";", "switch", "(", "getAluKind", "(", "SU", ")", ")", "{", "case", "AluT_XYZW", ":", "CurEmitted", "+=", "4", ";", "break", ";", "case", "AluDiscarded", ":", "break", ";", "default", ":", "{", "++", "CurEmitted", ";", "for", "(", "MachineInstr", "::", "mop_iterator", "It", "=", "SU", "->", "getInstr", "(", ")", "->", "operands_begin", "(", ")", ",", "E", "=", "SU", "->", "getInstr", "(", ")", "->", "operands_end", "(", ")", ";", "It", "!=", "E", ";", "++", "It", ")", "{", "MachineOperand", "&", "MO", "=", "*", "It", ";", "if", "(", "MO", ".", "isReg", "(", ")", "&&", "MO", ".", "getReg", "(", ")", "==", "R600", "::", "ALU_LITERAL_X", ")", "++", "CurEmitted", ";", "}", "}", "}", "}", "else", "{", "++", "CurEmitted", ";", "}", "LLVM_DEBUG", "(", "dbgs", "(", ")", "<<", "CurEmitted", "<<", "\" Instructions Emitted in this clause\\n\"", ")", ";", "if", "(", "CurInstKind", "!=", "IDFetch", ")", "{", "MoveUnits", "(", "Pending", "[", "IDFetch", "]", ",", "Available", "[", "IDFetch", "]", ")", ";", "}", "else", "FetchInstCount", "++", ";", "}", "</s>" ]
[ "ScheduleDAGMI", "has", "scheduled", "an", "instruction", "-", "tell", "HazardRec", "about", "it", "." ]
[ "AMDGPU", "R600", "\"Instruction Type Switch\\n\"", "31", "0", "4", "R600::ALU_LITERAL_X", "\" Instructions Emitted in this clause\\n\"" ]
R600MachineScheduler10
schedNode
AMDGPU
GPU
LLVM
38
198
1
[]
[ "<s>", "void", "addExpr", "(", "MCInst", "&", "Inst", ",", "const", "MCExpr", "*", "Expr", ")", "const", "{", "if", "(", "!", "Expr", ")", "Inst", ".", "addOperand", "(", "MCOperand", "::", "createImm", "(", "0", ")", ")", ";", "else", "if", "(", "const", "auto", "*", "CE", "=", "dyn_cast", "<", "MCConstantExpr", ">", "(", "Expr", ")", ")", "Inst", ".", "addOperand", "(", "MCOperand", "::", "createImm", "(", "CE", "->", "getValue", "(", ")", ")", ")", ";", "else", "Inst", ".", "addOperand", "(", "MCOperand", "::", "createExpr", "(", "Expr", ")", ")", ";", "}", "</s>" ]
[ "Add", "a", "new", "MCExpr", "operand", "." ]
[ "VE", "0" ]
VEAsmParser (2)
addExpr
VE
CPU
LLVM
39
77
1
[]
[ "<s>", "MachineInstrBuilder", "R600InstrInfo", "::", "buildIndirectRead", "(", "MachineBasicBlock", "*", "MBB", ",", "MachineBasicBlock", "::", "iterator", "I", ",", "unsigned", "ValueReg", ",", "unsigned", "Address", ",", "unsigned", "OffsetReg", ")", "const", "{", "unsigned", "AddrReg", "=", "AMDGPU", "::", "R600_AddrRegClass", ".", "getRegister", "(", "Address", ")", ";", "MachineInstr", "*", "MOVA", "=", "buildDefaultInstruction", "(", "*", "MBB", ",", "I", ",", "AMDGPU", "::", "MOVA_INT_eg", ",", "AMDGPU", "::", "AR_X", ",", "OffsetReg", ")", ";", "setImmOperand", "(", "MOVA", ",", "R600Operands", "::", "WRITE", ",", "0", ")", ";", "MachineInstrBuilder", "Mov", "=", "buildDefaultInstruction", "(", "*", "MBB", ",", "I", ",", "AMDGPU", "::", "MOV", ",", "ValueReg", ",", "AddrReg", ")", ".", "addReg", "(", "AMDGPU", "::", "AR_X", ",", "RegState", "::", "Implicit", "|", "RegState", "::", "Kill", ")", ";", "setImmOperand", "(", "Mov", ",", "R600Operands", "::", "SRC0_REL", ",", "1", ")", ";", "return", "Mov", ";", "}", "</s>" ]
[ "Build", "instruction", "(", "s", ")", "for", "an", "indirect", "register", "read", "." ]
[ "R600", "R600Operands::WRITE", "0", "R600Operands::SRC0_REL", "1" ]
R600InstrInfo65
buildIndirectRead
R600
GPU
LLVM
40
119
1
[]
[ "<s>", "void", "TeakFrameLowering", "::", "emitEpilogue", "(", "MachineFunction", "&", "MF", ",", "MachineBasicBlock", "&", "MBB", ")", "const", "{", "const", "TargetInstrInfo", "&", "TII", "=", "*", "MF", ".", "getSubtarget", "(", ")", ".", "getInstrInfo", "(", ")", ";", "MachineBasicBlock", "::", "iterator", "MBBI", "=", "MBB", ".", "getLastNonDebugInstr", "(", ")", ";", "DebugLoc", "dl", "=", "MBBI", "->", "getDebugLoc", "(", ")", ";", "uint64_t", "StackSize", "=", "computeStackSize", "(", "MF", ")", ";", "if", "(", "!", "StackSize", ")", "return", ";", "MachineFrameInfo", "&", "MFI", "=", "MF", ".", "getFrameInfo", "(", ")", ";", "const", "std", "::", "vector", "<", "CalleeSavedInfo", ">", "&", "CSI", "=", "MFI", ".", "getCalleeSavedInfo", "(", ")", ";", "StackSize", "-=", "CSI", ".", "size", "(", ")", "*", "2", ";", "if", "(", "!", "StackSize", ")", "return", ";", "BuildMI", "(", "MBB", ",", "MBBI", ",", "dl", ",", "TII", ".", "get", "(", "Teak", "::", "MOV_regnobp016_regnob16", ")", ",", "Teak", "::", "SP", ")", ".", "addReg", "(", "Teak", "::", "R7", ")", ".", "setMIFlag", "(", "MachineInstr", "::", "FrameSetup", ")", ";", "BuildMI", "(", "MBB", ",", "MBBI", ",", "dl", ",", "TII", ".", "get", "(", "Teak", "::", "NOP", ")", ")", ".", "setMIFlag", "(", "MachineInstr", "::", "FrameSetup", ")", ";", "BuildMI", "(", "MBB", ",", "MBBI", ",", "dl", ",", "TII", ".", "get", "(", "Teak", "::", "POP_regnob16", ")", ",", "Teak", "::", "R7", ")", ".", "setMIFlag", "(", "MachineInstr", "::", "FrameSetup", ")", ";", "}", "</s>" ]
[ "Insert", "epilog", "code", "into", "the", "function", "." ]
[ "Teak", "Teak", "2", "Teak::MOV_regnobp016_regnob16", "Teak::SP", "Teak::R7", "Teak::NOP", "Teak::POP_regnob16", "Teak::R7" ]
TeakFrameLowering
emitEpilogue
Teak
DSP
LLVM
41
200
1
[]
[ "<s>", "TargetPassConfig", "*", "PatmosTargetMachine", "::", "createPassConfig", "(", "PassManagerBase", "&", "PM", ")", "{", "return", "new", "PatmosPassConfig", "(", "this", ",", "PM", ")", ";", "}", "</s>" ]
[ "Create", "a", "pass", "configuration", "object", "to", "be", "used", "by", "addPassToEmitX", "methods", "for", "generating", "a", "pipeline", "of", "CodeGen", "passes", "." ]
[ "Patmos", "Patmos", "Patmos" ]
PatmosTargetMachine
createPassConfig
Patmos
VLIW
LLVM
42
21
1
[]
[ "<s>", "static", "MBlazeOperand", "*", "CreateReg", "(", "unsigned", "RegNum", ",", "SMLoc", "S", ",", "SMLoc", "E", ")", "{", "MBlazeOperand", "*", "Op", "=", "new", "MBlazeOperand", "(", "Register", ")", ";", "Op", "->", "Reg", ".", "RegNum", "=", "RegNum", ";", "Op", "->", "StartLoc", "=", "S", ";", "Op", "->", "EndLoc", "=", "E", ";", "return", "Op", ";", "}", "</s>" ]
[ "CreateReg", "-", "Allocate", "a", "single", "virtual", "register", "for", "the", "given", "type", "." ]
[ "MBlaze", "MBlaze", "MBlaze", "MBlaze" ]
MBlazeAsmParser1
CreateReg
MBlaze
MPU
LLVM
43
49
1
[]
[ "<s>", "bool", "umips_12bit_offset_address_p", "(", "rtx", "x", ",", "machine_mode", "mode", ")", "{", "struct", "mips_address_info", "addr", ";", "return", "(", "mips_classify_address", "(", "&", "addr", ",", "x", ",", "mode", ",", "false", ")", "&&", "addr", ".", "type", "==", "ADDRESS_REG", "&&", "CONST_INT_P", "(", "addr", ".", "offset", ")", "&&", "UMIPS_12BIT_OFFSET_P", "(", "INTVAL", "(", "addr", ".", "offset", ")", ")", ")", ";", "}", "</s>" ]
[ "Return", "true", "if", "X", "is", "a", "legitimate", "address", "with", "a", "12-bit", "offset", ".", "MODE", "is", "the", "mode", "of", "the", "value", "being", "accessed", "." ]
[ "mips" ]
mips
umips_12bit_offset_address_p
mips
CPU
GCC
44
53
1
[]
[ "<s>", "const", "char", "*", "mcore_output_jump_label_table", "(", "void", ")", "{", "int", "i", ";", "if", "(", "pool_size", ")", "{", "fprintf", "(", "asm_out_file", ",", "\"\\t.align 2\\n\"", ")", ";", "for", "(", "i", "=", "0", ";", "i", "<", "pool_size", ";", "i", "++", ")", "{", "pool_node", "*", "p", "=", "pool_vector", "+", "i", ";", "(", "*", "targetm", ".", "asm_out", ".", "internal_label", ")", "(", "asm_out_file", ",", "\"L\"", ",", "CODE_LABEL_NUMBER", "(", "p", "->", "label", ")", ")", ";", "output_asm_insn", "(", "\".long\t%0\"", ",", "&", "p", "->", "value", ")", ";", "}", "pool_size", "=", "0", ";", "}", "return", "\"\"", ";", "}", "</s>" ]
[ "Dump", "out", "any", "constants", "accumulated", "in", "the", "final", "pass", ".", "These", "will", "only", "be", "labels", "." ]
[ "mcore", "\"\\t.align 2\\n\"", "0", "\"L\"", "\".long\t%0\"", "0", "\"\"" ]
mcore
mcore_output_jump_label_table
mcore
MPU
GCC
45
86
1
[]
[ "<s>", "void", "GBZ80FrameLowering", "::", "determineCalleeSaves", "(", "MachineFunction", "&", "MF", ",", "BitVector", "&", "SavedRegs", ",", "RegScavenger", "*", "RS", ")", "const", "{", "TargetFrameLowering", "::", "determineCalleeSaves", "(", "MF", ",", "SavedRegs", ",", "RS", ")", ";", "}", "</s>" ]
[ "This", "method", "determines", "which", "of", "the", "registers", "reported", "by", "TargetRegisterInfo", ":", ":getCalleeSavedRegs", "(", ")", "should", "actually", "get", "saved", "." ]
[ "GBZ80", "GB" ]
GBZ80FrameLowering
determineCalleeSaves
GBZ80
MPU
LLVM
46
31
1
[]
[ "<s>", "void", "JVMPassConfig", "::", "addIRPasses", "(", ")", "{", "TargetPassConfig", "::", "addIRPasses", "(", ")", ";", "addPass", "(", "createJVMLowerMemoryIntrinsics", "(", ")", ")", ";", "addPass", "(", "createAggressiveDCEPass", "(", ")", ")", ";", "if", "(", "JvmAggOpt", ")", "addPass", "(", "createInstructionCombiningPass", "(", ")", ")", ";", "addPass", "(", "createJVMIRDecorator", "(", ")", ")", ";", "addPass", "(", "createAggressiveDCEPass", "(", ")", ")", ";", "if", "(", "JvmAggOpt", ")", "addPass", "(", "createInstructionCombiningPass", "(", ")", ")", ";", "if", "(", "JvmClient", ")", "addPass", "(", "createX2JavaPass", "(", ")", ")", ";", "}", "</s>" ]
[ "Add", "common", "target", "configurable", "passes", "that", "perform", "LLVM", "IR", "to", "IR", "transforms", "following", "machine", "independent", "optimization", "." ]
[ "JVM", "JVM", "JVM", "JVM" ]
JVMTargetMachine
addIRPasses
JVM
Virtual ISA
LLVM
47
75
1
[]
[ "<s>", "static", "void", "aarch64_parse_cpu", "(", "void", ")", "{", "char", "*", "ext", ";", "const", "struct", "processor", "*", "cpu", ";", "char", "*", "str", "=", "(", "char", "*", ")", "alloca", "(", "strlen", "(", "aarch64_cpu_string", ")", "+", "1", ")", ";", "size_t", "len", ";", "strcpy", "(", "str", ",", "aarch64_cpu_string", ")", ";", "ext", "=", "strchr", "(", "str", ",", "'+'", ")", ";", "if", "(", "ext", "!=", "NULL", ")", "len", "=", "ext", "-", "str", ";", "else", "len", "=", "strlen", "(", "str", ")", ";", "if", "(", "len", "==", "0", ")", "{", "error", "(", "\"missing cpu name in -mcpu=%qs\"", ",", "str", ")", ";", "return", ";", "}", "for", "(", "cpu", "=", "all_cores", ";", "cpu", "->", "name", "!=", "NULL", ";", "cpu", "++", ")", "{", "if", "(", "strlen", "(", "cpu", "->", "name", ")", "==", "len", "&&", "strncmp", "(", "cpu", "->", "name", ",", "str", ",", "len", ")", "==", "0", ")", "{", "selected_cpu", "=", "cpu", ";", "aarch64_isa_flags", "=", "selected_cpu", "->", "flags", ";", "if", "(", "ext", "!=", "NULL", ")", "{", "aarch64_parse_extension", "(", "ext", ")", ";", "}", "return", ";", "}", "}", "error", "(", "\"unknown value %qs for -mcpu\"", ",", "str", ")", ";", "return", ";", "}", "</s>" ]
[ "Parse", "the", "TO_PARSE", "string", "and", "put", "the", "result", "tuning", "in", "RES", "and", "the", "architecture", "flags", "in", "ISA_FLAGS", ".", "Return", "an", "aarch64_parse_opt_result", "describing", "the", "parse", "result", ".", "If", "there", "is", "an", "error", "parsing", ",", "RES", "and", "ISA_FLAGS", "are", "left", "unchanged", "." ]
[ "aarch64", "1", "0", "\"missing cpu name in -mcpu=%qs\"", "0", "\"unknown value %qs for -mcpu\"" ]
aarch642
aarch64_parse_cpu
aarch64
CPU
GCC
48
169
1
[]
[ "<s>", "static", "std", "::", "unique_ptr", "<", "SNESOperand", ">", "CreateReg", "(", "unsigned", "RegNum", ",", "SMLoc", "S", ",", "SMLoc", "E", ")", "{", "return", "make_unique", "<", "SNESOperand", ">", "(", "RegNum", ",", "S", ",", "E", ")", ";", "}", "</s>" ]
[ "CreateReg", "-", "Allocate", "a", "single", "virtual", "register", "for", "the", "given", "type", "." ]
[ "SNES", "SNES", "SNES" ]
SNESAsmParser
CreateReg
SNES
DSP
LLVM
49
33
1
[]
[ "<s>", "bool", "XCoreFrameLowering", "::", "spillCalleeSavedRegisters", "(", "MachineBasicBlock", "&", "MBB", ",", "MachineBasicBlock", "::", "iterator", "MI", ",", "const", "std", "::", "vector", "<", "CalleeSavedInfo", ">", "&", "CSI", ",", "const", "TargetRegisterInfo", "*", "TRI", ")", "const", "{", "if", "(", "CSI", ".", "empty", "(", ")", ")", "return", "true", ";", "MachineFunction", "*", "MF", "=", "MBB", ".", "getParent", "(", ")", ";", "const", "TargetInstrInfo", "&", "TII", "=", "*", "MF", "->", "getTarget", "(", ")", ".", "getInstrInfo", "(", ")", ";", "XCoreFunctionInfo", "*", "XFI", "=", "MF", "->", "getInfo", "<", "XCoreFunctionInfo", ">", "(", ")", ";", "bool", "emitFrameMoves", "=", "XCoreRegisterInfo", "::", "needsFrameMoves", "(", "*", "MF", ")", ";", "DebugLoc", "DL", ";", "if", "(", "MI", "!=", "MBB", ".", "end", "(", ")", ")", "DL", "=", "MI", "->", "getDebugLoc", "(", ")", ";", "for", "(", "std", "::", "vector", "<", "CalleeSavedInfo", ">", "::", "const_iterator", "it", "=", "CSI", ".", "begin", "(", ")", ";", "it", "!=", "CSI", ".", "end", "(", ")", ";", "++", "it", ")", "{", "unsigned", "Reg", "=", "it", "->", "getReg", "(", ")", ";", "assert", "(", "Reg", "!=", "XCore", "::", "LR", "&&", "!", "(", "Reg", "==", "XCore", "::", "R10", "&&", "hasFP", "(", "*", "MF", ")", ")", "&&", "\"LR & FP are always handled in emitPrologue\"", ")", ";", "MBB", ".", "addLiveIn", "(", "Reg", ")", ";", "const", "TargetRegisterClass", "*", "RC", "=", "TRI", "->", "getMinimalPhysRegClass", "(", "Reg", ")", ";", "TII", ".", "storeRegToStackSlot", "(", "MBB", ",", "MI", ",", "Reg", ",", "true", ",", "it", "->", "getFrameIdx", "(", ")", ",", "RC", ",", "TRI", ")", ";", "if", "(", "emitFrameMoves", ")", "{", "auto", "Store", "=", "MI", ";", "--", "Store", ";", "XFI", "->", "getSpillLabels", "(", ")", ".", "push_back", "(", "std", "::", "make_pair", "(", "Store", ",", "*", "it", ")", ")", ";", "}", "}", "return", "true", ";", "}", "</s>" ]
[ "spillCalleeSavedRegisters", "-", "Issues", "instruction", "(", "s", ")", "to", "spill", "all", "callee", "saved", "registers", "and", "returns", "true", "if", "it", "is", "n't", "possible", "/", "profitable", "to", "do", "so", "by", "issuing", "a", "series", "of", "store", "instructions", "via", "storeRegToStackSlot", "(", ")", "." ]
[ "XCore", "XCore", "XCore", "XCore", "XCore", "XCore::LR", "XCore::R10", "\"LR & FP are always handled in emitPrologue\"" ]
XCoreFrameLowering24
spillCalleeSavedRegisters
XCore
MPU
LLVM
50
258
1
[]
[ "<s>", "int", "rs6000_trampoline_size", "(", ")", "{", "int", "ret", "=", "0", ";", "switch", "(", "DEFAULT_ABI", ")", "{", "default", ":", "abort", "(", ")", ";", "case", "ABI_AIX", ":", "ret", "=", "(", "TARGET_32BIT", ")", "?", "12", ":", "24", ";", "break", ";", "case", "ABI_DARWIN", ":", "case", "ABI_V4", ":", "case", "ABI_AIX_NODESC", ":", "ret", "=", "(", "TARGET_32BIT", ")", "?", "40", ":", "48", ";", "break", ";", "}", "return", "ret", ";", "}", "</s>" ]
[ "Length", "in", "units", "of", "the", "trampoline", "for", "entering", "a", "nested", "function", "." ]
[ "rs6000", "0", "12", "24", "40", "48" ]
rs60002
rs6000_trampoline_size
rs6000
CPU
GCC
51
62
1
[]
[ "<s>", "static", "bool", "msp430_check_plus_not_high_mem", "(", "rtx", "op", ")", "{", "if", "(", "GET_CODE", "(", "op", ")", "!=", "PLUS", ")", "return", "false", ";", "rtx", "op0", "=", "XEXP", "(", "op", ",", "0", ")", ";", "rtx", "op1", "=", "XEXP", "(", "op", ",", "1", ")", ";", "if", "(", "SYMBOL_REF_P", "(", "op0", ")", "&&", "(", "SYMBOL_REF_FLAGS", "(", "op0", ")", "&", "SYMBOL_FLAG_LOW_MEM", ")", "&&", "msp430_check_index_not_high_mem", "(", "op1", ")", ")", "return", "true", ";", "return", "false", ";", "}", "</s>" ]
[ "If", "this", "returns", "true", ",", "we", "do", "n't", "need", "a", "430X", "insn", "." ]
[ "msp430", "0", "1" ]
msp430
msp430_check_plus_not_high_mem
msp430
MPU
GCC
52
68
1
[]
[ "<s>", "bool", "mayNeedRelaxation", "(", "const", "MCInst", "&", "Inst", ",", "const", "MCSubtargetInfo", "&", "STI", ")", "const", "override", "{", "return", "false", ";", "}", "</s>" ]
[ "Check", "whether", "the", "given", "instruction", "may", "need", "relaxation", "." ]
[ "PowerPC" ]
PPCAsmBackend (2)1
mayNeedRelaxation
PowerPC
CPU
LLVM
53
20
1
[]
[ "<s>", "void", "SparcFrameLowering", "::", "eliminateCallFramePseudoInstr", "(", "MachineFunction", "&", "MF", ",", "MachineBasicBlock", "&", "MBB", ",", "MachineBasicBlock", "::", "iterator", "I", ")", "const", "{", "if", "(", "!", "hasReservedCallFrame", "(", "MF", ")", ")", "{", "MachineInstr", "&", "MI", "=", "*", "I", ";", "DebugLoc", "DL", "=", "MI", ".", "getDebugLoc", "(", ")", ";", "int", "Size", "=", "MI", ".", "getOperand", "(", "0", ")", ".", "getImm", "(", ")", ";", "if", "(", "MI", ".", "getOpcode", "(", ")", "==", "SP", "::", "ADJCALLSTACKDOWN", ")", "Size", "=", "-", "Size", ";", "const", "SparcInstrInfo", "&", "TII", "=", "*", "static_cast", "<", "const", "SparcInstrInfo", "*", ">", "(", "MF", ".", "getTarget", "(", ")", ".", "getInstrInfo", "(", ")", ")", ";", "if", "(", "Size", ")", "BuildMI", "(", "MBB", ",", "I", ",", "DL", ",", "TII", ".", "get", "(", "SP", "::", "ADDri", ")", ",", "SP", "::", "O6", ")", ".", "addReg", "(", "SP", "::", "O6", ")", ".", "addImm", "(", "Size", ")", ";", "}", "MBB", ".", "erase", "(", "I", ")", ";", "}", "</s>" ]
[ "This", "method", "is", "called", "during", "prolog/epilog", "code", "insertion", "to", "eliminate", "call", "frame", "setup", "and", "destroy", "pseudo", "instructions", "(", "but", "only", "if", "the", "Target", "is", "using", "them", ")", "." ]
[ "Sparc", "Sparc", "0", "SP::ADJCALLSTACKDOWN", "Sparc", "Sparc", "SP::ADDri", "SP::O6", "SP::O6" ]
SparcFrameLowering3
eliminateCallFramePseudoInstr
Sparc
CPU
LLVM
54
147
1
[]
[ "<s>", "bool", "SystemZShortenInst", "::", "runOnMachineFunction", "(", "MachineFunction", "&", "F", ")", "{", "if", "(", "skipFunction", "(", "*", "F", ".", "getFunction", "(", ")", ")", ")", "return", "false", ";", "const", "SystemZSubtarget", "&", "ST", "=", "F", ".", "getSubtarget", "<", "SystemZSubtarget", ">", "(", ")", ";", "TII", "=", "ST", ".", "getInstrInfo", "(", ")", ";", "TRI", "=", "ST", ".", "getRegisterInfo", "(", ")", ";", "LiveRegs", ".", "init", "(", "TRI", ")", ";", "bool", "Changed", "=", "false", ";", "for", "(", "auto", "&", "MBB", ":", "F", ")", "Changed", "|=", "processBlock", "(", "MBB", ")", ";", "return", "Changed", ";", "}", "</s>" ]
[ "runOnMachineFunction", "-", "Emit", "the", "function", "body", "." ]
[ "SystemZ", "SystemZ", "SystemZ", "SystemZ" ]
SystemZShortenInst21
runOnMachineFunction
SystemZ
CPU
LLVM
55
86
1
[]
[ "<s>", "bool", "loongarch_split_move_p", "(", "rtx", "dest", ",", "rtx", "src", ")", "{", "unsigned", "int", "size", "=", "GET_MODE_SIZE", "(", "GET_MODE", "(", "dest", ")", ")", ";", "if", "(", "size", "==", "8", "&&", "FP_REG_RTX_P", "(", "src", ")", "&&", "FP_REG_RTX_P", "(", "dest", ")", ")", "return", "false", ";", "if", "(", "size", "==", "8", ")", "{", "if", "(", "FP_REG_RTX_P", "(", "dest", ")", "&&", "MEM_P", "(", "src", ")", ")", "return", "false", ";", "if", "(", "FP_REG_RTX_P", "(", "src", ")", "&&", "MEM_P", "(", "dest", ")", ")", "return", "false", ";", "}", "return", "size", ">", "UNITS_PER_WORD", ";", "}", "</s>" ]
[ "Return", "true", "if", "a", "move", "from", "SRC", "to", "DEST", "should", "be", "split", "into", "two", ".", "SPLIT_TYPE", "describes", "the", "split", "condition", "." ]
[ "loongarch", "8", "8" ]
loongarch
loongarch_split_move_p
loongarch
CPU
GCC
56
85
1
[]
[ "<s>", "XCoreTargetMachine", "::", "XCoreTargetMachine", "(", "const", "Target", "&", "T", ",", "const", "std", "::", "string", "&", "TT", ",", "const", "std", "::", "string", "&", "FS", ")", ":", "LLVMTargetMachine", "(", "T", ",", "TT", ")", ",", "Subtarget", "(", "TT", ",", "FS", ")", ",", "DataLayout", "(", "\"e-p:32:32:32-a0:0:32-f32:32:32-f64:32:32-i1:8:32-i8:8:32-\"", "\"i16:16:32-i32:32:32-i64:32:32-n32\"", ")", ",", "InstrInfo", "(", ")", ",", "FrameInfo", "(", "*", "this", ")", ",", "TLInfo", "(", "*", "this", ")", ",", "TSInfo", "(", "*", "this", ")", "{", "}", "</s>" ]
[ "Create", "an", "ILP32", "architecture", "model", "." ]
[ "XCore", "XCore", "XCore", "\"e-p:32:32:32-a0:0:32-f32:32:32-f64:32:32-i1:8:32-i8:8:32-\"", "\"i16:16:32-i32:32:32-i64:32:32-n32\"" ]
XCoreTargetMachine14
XCoreTargetMachine
XCore
MPU
LLVM
57
67
1
[]
[ "<s>", "unsigned", "HexagonInstrInfo", "::", "isLoadFromStackSlot", "(", "const", "MachineInstr", "*", "MI", ",", "int", "&", "FrameIndex", ")", "const", "{", "switch", "(", "MI", "->", "getOpcode", "(", ")", ")", "{", "default", ":", "break", ";", "case", "Hexagon", "::", "L2_loadri_io", ":", "case", "Hexagon", "::", "L2_loadrd_io", ":", "case", "Hexagon", "::", "L2_loadrh_io", ":", "case", "Hexagon", "::", "L2_loadrb_io", ":", "case", "Hexagon", "::", "L2_loadrub_io", ":", "if", "(", "MI", "->", "getOperand", "(", "2", ")", ".", "isFI", "(", ")", "&&", "MI", "->", "getOperand", "(", "1", ")", ".", "isImm", "(", ")", "&&", "(", "MI", "->", "getOperand", "(", "1", ")", ".", "getImm", "(", ")", "==", "0", ")", ")", "{", "FrameIndex", "=", "MI", "->", "getOperand", "(", "2", ")", ".", "getIndex", "(", ")", ";", "return", "MI", "->", "getOperand", "(", "0", ")", ".", "getReg", "(", ")", ";", "}", "break", ";", "}", "return", "0", ";", "}", "</s>" ]
[ "isLoadFromStackSlot", "-", "If", "the", "specified", "machine", "instruction", "is", "a", "direct", "load", "from", "a", "stack", "slot", ",", "return", "the", "virtual", "or", "physical", "register", "number", "of", "the", "destination", "along", "with", "the", "FrameIndex", "of", "the", "loaded", "stack", "slot", "." ]
[ "Hexagon", "Hexagon", "Hexagon::L2_loadri_io", "Hexagon::L2_loadrd_io", "Hexagon::L2_loadrh_io", "Hexagon::L2_loadrb_io", "Hexagon::L2_loadrub_io", "2", "1", "1", "0", "2", "0", "0" ]
HexagonInstrInfo
isLoadFromStackSlot
Hexagon
DSP
LLVM
58
127
1
[]
[ "<s>", "bool", "NVPTXInferAddressSpaces", "::", "runOnFunction", "(", "Function", "&", "F", ")", "{", "if", "(", "skipFunction", "(", "F", ")", ")", "return", "false", ";", "std", "::", "vector", "<", "Value", "*", ">", "Postorder", "=", "collectGenericAddressExpressions", "(", "F", ")", ";", "ValueToAddrSpaceMapTy", "InferredAddrSpace", ";", "inferAddressSpaces", "(", "Postorder", ",", "&", "InferredAddrSpace", ")", ";", "return", "rewriteWithNewAddressSpaces", "(", "Postorder", ",", "InferredAddrSpace", ",", "&", "F", ")", ";", "}", "</s>" ]
[ "runOnFunction", "-", "Virtual", "method", "overriden", "by", "subclasses", "to", "do", "the", "per-function", "processing", "of", "the", "pass", "." ]
[ "NVPTX", "NVPTX" ]
NVPTXInferAddressSpaces
runOnFunction
NVPTX
GPU
LLVM
59
57
1
[]
[ "<s>", "const", "MCExpr", "*", "SparcELFTargetObjectFile", "::", "getTTypeGlobalReference", "(", "const", "GlobalValue", "*", "GV", ",", "unsigned", "Encoding", ",", "Mangler", "&", "Mang", ",", "const", "TargetMachine", "&", "TM", ",", "MachineModuleInfo", "*", "MMI", ",", "MCStreamer", "&", "Streamer", ")", "const", "{", "if", "(", "Encoding", "&", "dwarf", "::", "DW_EH_PE_pcrel", ")", "{", "MachineModuleInfoELF", "&", "ELFMMI", "=", "MMI", "->", "getObjFileInfo", "<", "MachineModuleInfoELF", ">", "(", ")", ";", "MCSymbol", "*", "SSym", "=", "getSymbolWithGlobalValueBase", "(", "GV", ",", "\".DW.stub\"", ",", "Mang", ",", "TM", ")", ";", "MachineModuleInfoImpl", "::", "StubValueTy", "&", "StubSym", "=", "ELFMMI", ".", "getGVStubEntry", "(", "SSym", ")", ";", "if", "(", "!", "StubSym", ".", "getPointer", "(", ")", ")", "{", "MCSymbol", "*", "Sym", "=", "TM", ".", "getSymbol", "(", "GV", ",", "Mang", ")", ";", "StubSym", "=", "MachineModuleInfoImpl", "::", "StubValueTy", "(", "Sym", ",", "!", "GV", "->", "hasLocalLinkage", "(", ")", ")", ";", "}", "MCContext", "&", "Ctx", "=", "getContext", "(", ")", ";", "return", "SparcMCExpr", "::", "Create", "(", "SparcMCExpr", "::", "VK_Sparc_R_DISP32", ",", "MCSymbolRefExpr", "::", "Create", "(", "SSym", ",", "Ctx", ")", ",", "Ctx", ")", ";", "}", "return", "TargetLoweringObjectFileELF", "::", "getTTypeGlobalReference", "(", "GV", ",", "Encoding", ",", "Mang", ",", "TM", ",", "MMI", ",", "Streamer", ")", ";", "}", "</s>" ]
[ "The", "mach-o", "version", "of", "this", "method", "defaults", "to", "returning", "a", "stub", "reference", "." ]
[ "Sparc", "Sparc", "\".DW.stub\"", "Sparc", "Sparc", "SP" ]
SparcTargetObjectFile15
getTTypeGlobalReference
Sparc
CPU
LLVM
60
173
1
[]
[ "<s>", "int", "ARMAsmParser", "::", "tryParseRegister", "(", ")", "{", "MCAsmParser", "&", "Parser", "=", "getParser", "(", ")", ";", "const", "AsmToken", "&", "Tok", "=", "Parser", ".", "getTok", "(", ")", ";", "if", "(", "Tok", ".", "isNot", "(", "AsmToken", "::", "Identifier", ")", ")", "return", "-", "1", ";", "std", "::", "string", "lowerCase", "=", "Tok", ".", "getString", "(", ")", ".", "lower", "(", ")", ";", "unsigned", "RegNum", "=", "MatchRegisterName", "(", "lowerCase", ")", ";", "if", "(", "!", "RegNum", ")", "{", "RegNum", "=", "StringSwitch", "<", "unsigned", ">", "(", "lowerCase", ")", ".", "Case", "(", "\"r13\"", ",", "ARM", "::", "SP", ")", ".", "Case", "(", "\"r14\"", ",", "ARM", "::", "LR", ")", ".", "Case", "(", "\"r15\"", ",", "ARM", "::", "PC", ")", ".", "Case", "(", "\"ip\"", ",", "ARM", "::", "R12", ")", ".", "Case", "(", "\"a1\"", ",", "ARM", "::", "R0", ")", ".", "Case", "(", "\"a2\"", ",", "ARM", "::", "R1", ")", ".", "Case", "(", "\"a3\"", ",", "ARM", "::", "R2", ")", ".", "Case", "(", "\"a4\"", ",", "ARM", "::", "R3", ")", ".", "Case", "(", "\"v1\"", ",", "ARM", "::", "R4", ")", ".", "Case", "(", "\"v2\"", ",", "ARM", "::", "R5", ")", ".", "Case", "(", "\"v3\"", ",", "ARM", "::", "R6", ")", ".", "Case", "(", "\"v4\"", ",", "ARM", "::", "R7", ")", ".", "Case", "(", "\"v5\"", ",", "ARM", "::", "R8", ")", ".", "Case", "(", "\"v6\"", ",", "ARM", "::", "R9", ")", ".", "Case", "(", "\"v7\"", ",", "ARM", "::", "R10", ")", ".", "Case", "(", "\"v8\"", ",", "ARM", "::", "R11", ")", ".", "Case", "(", "\"sb\"", ",", "ARM", "::", "R9", ")", ".", "Case", "(", "\"sl\"", ",", "ARM", "::", "R10", ")", ".", "Case", "(", "\"fp\"", ",", "ARM", "::", "R11", ")", ".", "Default", "(", "0", ")", ";", "}", "if", "(", "!", "RegNum", ")", "{", "StringMap", "<", "unsigned", ">", "::", "const_iterator", "Entry", "=", "RegisterReqs", ".", "find", "(", "lowerCase", ")", ";", "if", "(", "Entry", "==", "RegisterReqs", ".", "end", "(", ")", ")", "return", "-", "1", ";", "Parser", ".", "Lex", "(", ")", ";", "return", "Entry", "->", "getValue", "(", ")", ";", "}", "if", "(", "hasD16", "(", ")", "&&", "RegNum", ">=", "ARM", "::", "D16", "&&", "RegNum", "<=", "ARM", "::", "D31", ")", "return", "-", "1", ";", "Parser", ".", "Lex", "(", ")", ";", "return", "RegNum", ";", "}", "</s>" ]
[ "tryParseRegister", "-", "parse", "one", "register", "if", "possible" ]
[ "ARM", "ARM", "1", "\"r13\"", "ARM::SP", "\"r14\"", "ARM::LR", "\"r15\"", "ARM::PC", "\"ip\"", "ARM::R12", "\"a1\"", "ARM::R0", "\"a2\"", "ARM::R1", "\"a3\"", "ARM::R2", "\"a4\"", "ARM::R3", "\"v1\"", "ARM::R4", "\"v2\"", "ARM::R5", "\"v3\"", "ARM::R6", "\"v4\"", "ARM::R7", "\"v5\"", "ARM::R8", "\"v6\"", "ARM::R9", "\"v7\"", "ARM::R10", "\"v8\"", "ARM::R11", "\"sb\"", "ARM::R9", "\"sl\"", "ARM::R10", "\"fp\"", "ARM::R11", "0", "1", "ARM::D16", "ARM::D31", "1" ]
ARMAsmParser (2)2
tryParseRegister
ARM
CPU
LLVM
61
338
1
[]
[ "<s>", "void", "NVPTXInstrInfo", "::", "copyPhysReg", "(", "MachineBasicBlock", "&", "MBB", ",", "MachineBasicBlock", "::", "iterator", "I", ",", "const", "DebugLoc", "&", "DL", ",", "MCRegister", "DestReg", ",", "MCRegister", "SrcReg", ",", "bool", "KillSrc", ")", "const", "{", "const", "MachineRegisterInfo", "&", "MRI", "=", "MBB", ".", "getParent", "(", ")", "->", "getRegInfo", "(", ")", ";", "const", "TargetRegisterClass", "*", "DestRC", "=", "MRI", ".", "getRegClass", "(", "DestReg", ")", ";", "const", "TargetRegisterClass", "*", "SrcRC", "=", "MRI", ".", "getRegClass", "(", "SrcReg", ")", ";", "if", "(", "RegInfo", ".", "getRegSizeInBits", "(", "*", "DestRC", ")", "!=", "RegInfo", ".", "getRegSizeInBits", "(", "*", "SrcRC", ")", ")", "report_fatal_error", "(", "\"Copy one register into another with a different width\"", ")", ";", "unsigned", "Op", ";", "if", "(", "DestRC", "==", "&", "NVPTX", "::", "Int1RegsRegClass", ")", "{", "Op", "=", "NVPTX", "::", "IMOV1rr", ";", "}", "else", "if", "(", "DestRC", "==", "&", "NVPTX", "::", "Int16RegsRegClass", ")", "{", "Op", "=", "NVPTX", "::", "IMOV16rr", ";", "}", "else", "if", "(", "DestRC", "==", "&", "NVPTX", "::", "Int32RegsRegClass", ")", "{", "Op", "=", "(", "SrcRC", "==", "&", "NVPTX", "::", "Int32RegsRegClass", "?", "NVPTX", "::", "IMOV32rr", ":", "NVPTX", "::", "BITCONVERT_32_F2I", ")", ";", "}", "else", "if", "(", "DestRC", "==", "&", "NVPTX", "::", "Int64RegsRegClass", ")", "{", "Op", "=", "(", "SrcRC", "==", "&", "NVPTX", "::", "Int64RegsRegClass", "?", "NVPTX", "::", "IMOV64rr", ":", "NVPTX", "::", "BITCONVERT_64_F2I", ")", ";", "}", "else", "if", "(", "DestRC", "==", "&", "NVPTX", "::", "Float16RegsRegClass", ")", "{", "Op", "=", "(", "SrcRC", "==", "&", "NVPTX", "::", "Float16RegsRegClass", "?", "NVPTX", "::", "FMOV16rr", ":", "NVPTX", "::", "BITCONVERT_16_I2F", ")", ";", "}", "else", "if", "(", "DestRC", "==", "&", "NVPTX", "::", "Float16x2RegsRegClass", ")", "{", "Op", "=", "NVPTX", "::", "IMOV32rr", ";", "}", "else", "if", "(", "DestRC", "==", "&", "NVPTX", "::", "Float32RegsRegClass", ")", "{", "Op", "=", "(", "SrcRC", "==", "&", "NVPTX", "::", "Float32RegsRegClass", "?", "NVPTX", "::", "FMOV32rr", ":", "NVPTX", "::", "BITCONVERT_32_I2F", ")", ";", "}", "else", "if", "(", "DestRC", "==", "&", "NVPTX", "::", "Float64RegsRegClass", ")", "{", "Op", "=", "(", "SrcRC", "==", "&", "NVPTX", "::", "Float64RegsRegClass", "?", "NVPTX", "::", "FMOV64rr", ":", "NVPTX", "::", "BITCONVERT_64_I2F", ")", ";", "}", "else", "{", "llvm_unreachable", "(", "\"Bad register copy\"", ")", ";", "}", "BuildMI", "(", "MBB", ",", "I", ",", "DL", ",", "get", "(", "Op", ")", ",", "DestReg", ")", ".", "addReg", "(", "SrcReg", ",", "getKillRegState", "(", "KillSrc", ")", ")", ";", "}", "</s>" ]
[ "}", "Branch", "Analysis", "&", "Modification" ]
[ "NVPTX", "NVPTX", "\"Copy one register into another with a different width\"", "NVPTX::Int1RegsRegClass", "NVPTX::IMOV1rr", "NVPTX::Int16RegsRegClass", "NVPTX::IMOV16rr", "NVPTX::Int32RegsRegClass", "NVPTX::Int32RegsRegClass", "NVPTX::IMOV32rr", "NVPTX::BITCONVERT_32_F2I", "NVPTX::Int64RegsRegClass", "NVPTX::Int64RegsRegClass", "NVPTX::IMOV64rr", "NVPTX::BITCONVERT_64_F2I", "NVPTX::Float16RegsRegClass", "NVPTX::Float16RegsRegClass", "NVPTX::FMOV16rr", "NVPTX::BITCONVERT_16_I2F", "NVPTX::Float16x2RegsRegClass", "NVPTX::IMOV32rr", "NVPTX::Float32RegsRegClass", "NVPTX::Float32RegsRegClass", "NVPTX::FMOV32rr", "NVPTX::BITCONVERT_32_I2F", "NVPTX::Float64RegsRegClass", "NVPTX::Float64RegsRegClass", "NVPTX::FMOV64rr", "NVPTX::BITCONVERT_64_I2F", "\"Bad register copy\"" ]
NVPTXInstrInfo17
copyPhysReg
NVPTX
GPU
LLVM
62
338
1
[]
[ "<s>", "static", "bool", "c6x_return_in_msb", "(", "const_tree", "valtype", ")", "{", "HOST_WIDE_INT", "size", "=", "int_size_in_bytes", "(", "valtype", ")", ";", "return", "TARGET_BIG_ENDIAN", "&&", "AGGREGATE_TYPE_P", "(", "valtype", ")", "&&", "size", "==", "3", ";", "}", "</s>" ]
[ "Values", "which", "must", "be", "returned", "in", "the", "most-significant", "end", "of", "the", "return", "register", "." ]
[ "c6x", "3" ]
c6x
c6x_return_in_msb
c6x
VLIW
GCC
63
29
1
[]
[ "<s>", "bool", "FPS", "::", "runOnMachineFunction", "(", "MachineFunction", "&", "MF", ")", "{", "bool", "FPIsUsed", "=", "false", ";", "assert", "(", "X86", "::", "FP6", "==", "X86", "::", "FP0", "+", "6", "&&", "\"Register enums aren't sorted right!\"", ")", ";", "for", "(", "unsigned", "i", "=", "0", ";", "i", "<=", "6", ";", "++", "i", ")", "if", "(", "MF", ".", "getRegInfo", "(", ")", ".", "isPhysRegUsed", "(", "X86", "::", "FP0", "+", "i", ")", ")", "{", "FPIsUsed", "=", "true", ";", "break", ";", "}", "if", "(", "!", "FPIsUsed", ")", "return", "false", ";", "TII", "=", "MF", ".", "getTarget", "(", ")", ".", "getInstrInfo", "(", ")", ";", "StackTop", "=", "0", ";", "SmallPtrSet", "<", "MachineBasicBlock", "*", ",", "8", ">", "Processed", ";", "MachineBasicBlock", "*", "Entry", "=", "MF", ".", "begin", "(", ")", ";", "bool", "Changed", "=", "false", ";", "for", "(", "df_ext_iterator", "<", "MachineBasicBlock", "*", ",", "SmallPtrSet", "<", "MachineBasicBlock", "*", ",", "8", ">", ">", "I", "=", "df_ext_begin", "(", "Entry", ",", "Processed", ")", ",", "E", "=", "df_ext_end", "(", "Entry", ",", "Processed", ")", ";", "I", "!=", "E", ";", "++", "I", ")", "Changed", "|=", "processBasicBlock", "(", "MF", ",", "*", "*", "I", ")", ";", "return", "Changed", ";", "}", "</s>" ]
[ "runOnMachineFunction", "-", "Emit", "the", "function", "body", "." ]
[ "X86", "X86::FP6", "X86::FP0", "6", "\"Register enums aren't sorted right!\"", "0", "6", "X86::FP0", "0", "8", "8" ]
X86FloatingPoint23
runOnMachineFunction
X86
CPU
LLVM
64
172
1
[]
[ "<s>", "const", "X86RegisterInfo", "*", "getRegisterInfo", "(", ")", "const", "override", "{", "return", "&", "getInstrInfo", "(", ")", "->", "getRegisterInfo", "(", ")", ";", "}", "</s>" ]
[ "getRegisterInfo", "-", "TargetInstrInfo", "is", "a", "superset", "of", "MRegister", "info", "." ]
[ "X86", "X86" ]
X86TargetMachine
getRegisterInfo
X86
CPU
LLVM
65
20
1
[]
[ "<s>", "static", "bool", "c6x_can_eliminate", "(", "const", "int", "from", "ATTRIBUTE_UNUSED", ",", "const", "int", "to", ")", "{", "if", "(", "to", "==", "STACK_POINTER_REGNUM", ")", "return", "!", "frame_pointer_needed", ";", "return", "true", ";", "}", "</s>" ]
[ "Given", "FROM", "and", "TO", "register", "numbers", ",", "say", "whether", "this", "elimination", "is", "allowed", ".", "Frame", "pointer", "elimination", "is", "automatically", "handled", "." ]
[ "c6x" ]
c6x
c6x_can_eliminate
c6x
VLIW
GCC
66
28
1
[]
[ "<s>", "void", "crx_expand_prologue", "(", "void", ")", "{", "crx_compute_frame", "(", ")", ";", "crx_compute_save_regs", "(", ")", ";", "if", "(", "size_for_adjusting_sp", "+", "sum_regs", "==", "0", ")", "return", ";", "if", "(", "last_reg_to_save", "!=", "-", "1", ")", "emit_insn", "(", "gen_push_for_prologue", "(", "GEN_INT", "(", "sum_regs", ")", ")", ")", ";", "if", "(", "size_for_adjusting_sp", ">", "0", ")", "emit_insn", "(", "gen_addsi3", "(", "stack_pointer_rtx", ",", "stack_pointer_rtx", ",", "GEN_INT", "(", "-", "size_for_adjusting_sp", ")", ")", ")", ";", "if", "(", "frame_pointer_needed", ")", "emit_move_insn", "(", "frame_pointer_rtx", ",", "stack_pointer_rtx", ")", ";", "}", "</s>" ]
[ "CompactRISC", "CRX", "Architecture", "stack", "layout", ":", "0", "+", "--", "--", "--", "--", "--", "--", "--", "--", "--", "--", "-", "|", ".", ".", "|", "+====================", "Sp", "(", "x", ")", "=Ap", "(", "x+1", ")", "A", "|", "Args", "for", "functions", "|", "|", "called", "by", "X", "and", "Dynamically", "|", "|", "Dynamic", "allocations", "allocated", "and", "|", "|", "(", "alloca", ",", "variable", "deallocated", "Stack", "|", "length", "arrays", ")", ".", "grows", "+", "--", "--", "--", "--", "--", "--", "--", "--", "--", "--", "Fp", "(", "x", ")", "down|", "|", "Local", "variables", "of", "X", "ward|", "+", "--", "--", "--", "--", "--", "--", "--", "--", "--", "--", "|", "|", "Regs", "saved", "for", "X-1", "|", "+====================", "Sp", "(", "x-1", ")", "=Ap", "(", "x", ")", "|", "Args", "for", "func", "X", "|", "pushed", "by", "X-1", "+", "--", "--", "--", "--", "--", "--", "--", "--", "--", "--", "Fp", "(", "x-1", ")", "|", "|", "V" ]
[ "crx", "0", "1", "0" ]
crx
crx_expand_prologue
crx
CPU
GCC
67
76
1
[]
[ "<s>", "void", "GCNScheduleDAGMILive", "::", "finalizeSchedule", "(", ")", "{", "if", "(", "!", "LIS", "||", "StartingOccupancy", "<=", "MinOccupancy", ")", "return", ";", "DEBUG", "(", "dbgs", "(", ")", "<<", "\"Retrying function scheduling with lowest recorded occupancy \"", "<<", "MinOccupancy", "<<", "\".\\n\"", ")", ";", "Stage", "++", ";", "GCNMaxOccupancySchedStrategy", "&", "S", "=", "(", "GCNMaxOccupancySchedStrategy", "&", ")", "*", "SchedImpl", ";", "S", ".", "setTargetOccupancy", "(", "MinOccupancy", ")", ";", "MachineBasicBlock", "*", "MBB", "=", "nullptr", ";", "for", "(", "auto", "Region", ":", "Regions", ")", "{", "RegionBegin", "=", "Region", ".", "first", ";", "RegionEnd", "=", "Region", ".", "second", ";", "if", "(", "RegionBegin", "->", "getParent", "(", ")", "!=", "MBB", ")", "{", "if", "(", "MBB", ")", "finishBlock", "(", ")", ";", "MBB", "=", "RegionBegin", "->", "getParent", "(", ")", ";", "startBlock", "(", "MBB", ")", ";", "}", "unsigned", "NumRegionInstrs", "=", "std", "::", "distance", "(", "begin", "(", ")", ",", "end", "(", ")", ")", ";", "enterRegion", "(", "MBB", ",", "begin", "(", ")", ",", "end", "(", ")", ",", "NumRegionInstrs", ")", ";", "if", "(", "begin", "(", ")", "==", "end", "(", ")", "||", "begin", "(", ")", "==", "std", "::", "prev", "(", "end", "(", ")", ")", ")", "{", "exitRegion", "(", ")", ";", "continue", ";", "}", "DEBUG", "(", "dbgs", "(", ")", "<<", "\"********** MI Scheduling **********\\n\"", ")", ";", "DEBUG", "(", "dbgs", "(", ")", "<<", "MF", ".", "getName", "(", ")", "<<", "\":BB#\"", "<<", "MBB", "->", "getNumber", "(", ")", "<<", "\" \"", "<<", "MBB", "->", "getName", "(", ")", "<<", "\"\\n From: \"", "<<", "*", "begin", "(", ")", "<<", "\" To: \"", ";", "if", "(", "RegionEnd", "!=", "MBB", "->", "end", "(", ")", ")", "dbgs", "(", ")", "<<", "*", "RegionEnd", ";", "else", "dbgs", "(", ")", "<<", "\"End\"", ";", "dbgs", "(", ")", "<<", "\" RegionInstrs: \"", "<<", "NumRegionInstrs", "<<", "'\\n'", ")", ";", "schedule", "(", ")", ";", "exitRegion", "(", ")", ";", "}", "finishBlock", "(", ")", ";", "LiveIns", ".", "shrink_and_clear", "(", ")", ";", "}", "</s>" ]
[ "After", "the", "schedule", "has", "been", "formed", ",", "call", "this", "function", "to", "combine", "the", "instructions", "from", "the", "different", "stages/cycles", "." ]
[ "AMDGPU", "\"Retrying function scheduling with lowest recorded occupancy \"", "\".\\n\"", "\"********** MI Scheduling **********\\n\"", "\":BB#\"", "\" \"", "\"\\n From: \"", "\" To: \"", "\"End\"", "\" RegionInstrs: \"" ]
GCNSchedStrategy21
finalizeSchedule
AMDGPU
GPU
LLVM
68
274
1
[]
[ "<s>", "static", "rtx_insn", "*", "maybe_dead_move", "(", "rtx", "dest", ",", "rtx", "src", ",", "bool", "ATTRIBUTE_UNUSED", "maybe_dead_p", ")", "{", "rtx_insn", "*", "insn", "=", "emit_move_insn", "(", "dest", ",", "src", ")", ";", "if", "(", "maybe_dead_p", ")", "REG_NOTES", "(", "insn", ")", "=", "gen_rtx_EXPR_LIST", "(", "REG_MAYBE_DEAD", ",", "const0_rtx", ",", "NULL", ")", ";", "return", "insn", ";", "}", "</s>" ]
[ "Move", "SRC", "to", "DEST", ".", "Mark", "the", "move", "as", "being", "potentially", "dead", "if", "MAYBE_DEAD_P", "." ]
[ "mep" ]
mep
maybe_dead_move
mep
CPU
GCC
69
49
1
[]
[ "<s>", "bool", "AArch64PreLegalizerCombiner", "::", "runOnMachineFunction", "(", "MachineFunction", "&", "MF", ")", "{", "if", "(", "MF", ".", "getProperties", "(", ")", ".", "hasProperty", "(", "MachineFunctionProperties", "::", "Property", "::", "FailedISel", ")", ")", "return", "false", ";", "auto", "*", "TPC", "=", "&", "getAnalysis", "<", "TargetPassConfig", ">", "(", ")", ";", "const", "Function", "&", "F", "=", "MF", ".", "getFunction", "(", ")", ";", "bool", "EnableOpt", "=", "MF", ".", "getTarget", "(", ")", ".", "getOptLevel", "(", ")", "!=", "CodeGenOpt", "::", "None", "&&", "!", "skipFunction", "(", "F", ")", ";", "GISelKnownBits", "*", "KB", "=", "&", "getAnalysis", "<", "GISelKnownBitsAnalysis", ">", "(", ")", ".", "get", "(", "MF", ")", ";", "MachineDominatorTree", "*", "MDT", "=", "IsOptNone", "?", "nullptr", ":", "&", "getAnalysis", "<", "MachineDominatorTree", ">", "(", ")", ";", "AArch64PreLegalizerCombinerInfo", "PCInfo", "(", "EnableOpt", ",", "F", ".", "hasOptSize", "(", ")", ",", "F", ".", "hasMinSize", "(", ")", ",", "KB", ",", "MDT", ")", ";", "Combiner", "C", "(", "PCInfo", ",", "TPC", ")", ";", "return", "C", ".", "combineMachineInstrs", "(", "MF", ",", "nullptr", ")", ";", "}", "</s>" ]
[ "runOnMachineFunction", "-", "Emit", "the", "function", "body", "." ]
[ "AArch64", "AArch64", "AArch64" ]
AArch64PreLegalizerCombiner
runOnMachineFunction
AArch64
CPU
LLVM
70
150
1
[]
[ "<s>", "bool", "z8k_mode_dependent_address", "(", "const_rtx", "addr", ",", "addr_space_t", "addr_space", "ATTRIBUTE_UNUSED", ")", "{", "return", "(", "GET_CODE", "(", "addr", ")", "==", "POST_INC", "||", "GET_CODE", "(", "addr", ")", "==", "PRE_DEC", ")", ";", "}", "</s>" ]
[ "emit_move_insn", "(", "gen_rtx_MEM", "(", "Pmode", ",", "plus_constant", "(", "Pmode", ",", "tramp", ",", "2", ")", ")", ",", "cxt", ")", ";", "emit_move_insn", "(", "gen_rtx_MEM", "(", "Pmode", ",", "plus_constant", "(", "Pmode", ",", "tramp", ",", "8", ")", ")", ",", "fnaddr", ")", ";", "}", "else", "{", "emit_move_insn", "(", "gen_rtx_MEM", "(", "HImode", ",", "plus_constant", "(", "Pmode", ",", "tramp", ",", "2", ")", ")", ",", "cxt", ")", ";", "emit_move_insn", "(", "gen_rtx_MEM", "(", "HImode", ",", "plus_constant", "(", "Pmode", ",", "tramp", ",", "6", ")", ")", ",", "fnaddr", ")", ";", "}", "}", "boolz8k_legitimate_constant_p", "(", "enum", "machine_mode", "mode", "ATTRIBUTE_UNUSED", ",", "rtx", "x", ")", "{", "return", "GET_CODE", "(", "x", ")", "!", "=", "CONST_DOUBLE", ";", "}", "boolz8k_can_eliminate", "(", "const", "int", "from", ",", "const", "int", "to", ")", "{", "return", "(", "!", "frame_pointer_needed", "||", "(", "(", "from", ")", "==", "ARG_POINTER_REGNUM", "&", "&", "(", "to", ")", "==", "FRAME_POINTER_REGNUM", ")", "||", "(", "(", "from", ")", "==", "RETURN_ADDRESS_POINTER_REGNUM", "&", "&", "(", "to", ")", "==", "FRAME_POINTER_REGNUM", ")", ")", ";", "}", "Return", "whether", "ADDR", "(", "a", "legitimate", "address", "expression", ")", "has", "an", "effect", "that", "depends", "on", "the", "machine", "mode", "it", "is", "used", "for", ".", "For", "the", "z8k", ",", "pushing", "and", "popping", "needs", "to", "know", "the", "mode" ]
[ "z8k" ]
z8k
z8k_mode_dependent_address
z8k
MPU
GCC
71
29
1
[]
[ "<s>", "void", "pdp10_expand_prologue", "(", ")", "{", "int", "clobbered", "[", "FIRST_PSEUDO_REGISTER", "]", ";", "int", "clobbered_size", ";", "int", "stack_adjust", ";", "int", "single_push", ";", "clobbered_size", "=", "clobbered_regs", "(", "clobbered", ")", ";", "single_push", "=", "clobbered_size", "==", "UNITS_PER_WORD", "&&", "(", "optimize_size", "||", "!", "TARGET_EXTENDED", ")", "&&", "current_function_outgoing_args_size", "==", "0", "&&", "current_function_pretend_args_size", "==", "0", "&&", "get_frame_size", "(", ")", "==", "0", ";", "stack_adjust", "=", "current_function_outgoing_args_size", "+", "get_frame_size", "(", ")", "+", "clobbered_size", "+", "current_function_pretend_args_size", ";", "if", "(", "!", "single_push", "&&", "stack_adjust", ">", "0", ")", "emit_frame_insn", "(", "pdp10_gen_stack_adjust", "(", "GEN_INT", "(", "stack_adjust", "/", "4", ")", ")", ")", ";", "expand_save_or_restore_return_address", "(", "SAVE", ",", "clobbered_size", ")", ";", "expand_save_or_restore_regs", "(", "SAVE", ",", "clobbered", ",", "clobbered_size", ",", "single_push", ")", ";", "expand_set_up_frame_pointer", "(", ")", ";", "}", "</s>" ]
[ "Emit", "function", "prologue", "instructions", "." ]
[ "pdp10", "0", "0", "0", "0", "4" ]
pdp10
pdp10_expand_prologue
pdp10
MPU
GCC
72
111
1
[]
[ "<s>", "ArrayRef", "<", "std", "::", "pair", "<", "unsigned", ",", "const", "char", "*", ">>", "PPCInstrInfo", "::", "getSerializableBitmaskMachineOperandTargetFlags", "(", ")", "const", "{", "using", "namespace", "PPCII", ";", "static", "const", "std", "::", "pair", "<", "unsigned", ",", "const", "char", "*", ">", "TargetFlags", "[", "]", "=", "{", "{", "MO_PLT", ",", "\"ppc-plt\"", "}", ",", "{", "MO_PIC_FLAG", ",", "\"ppc-pic\"", "}", ",", "{", "MO_PCREL_FLAG", ",", "\"ppc-pcrel\"", "}", ",", "{", "MO_GOT_FLAG", ",", "\"ppc-got\"", "}", "}", ";", "return", "makeArrayRef", "(", "TargetFlags", ")", ";", "}", "</s>" ]
[ "Return", "an", "array", "that", "contains", "the", "bitmask", "target", "flag", "values", "and", "their", "names", "." ]
[ "PowerPC", "PPC", "PPC", "\"ppc-plt\"", "\"ppc-pic\"", "\"ppc-pcrel\"", "\"ppc-got\"" ]
PPCInstrInfo128
getSerializableBitmaskMachineOperandTargetFlags
PowerPC
CPU
LLVM
73
72
1
[]
[ "<s>", "void", "s390_expand_vcond", "(", "rtx", "target", ",", "rtx", "then", ",", "rtx", "els", ",", "enum", "rtx_code", "cond", ",", "rtx", "cmp_op1", ",", "rtx", "cmp_op2", ")", "{", "rtx", "tmp", ";", "machine_mode", "result_mode", ";", "rtx", "result_target", ";", "machine_mode", "target_mode", "=", "GET_MODE", "(", "target", ")", ";", "machine_mode", "cmp_mode", "=", "GET_MODE", "(", "cmp_op1", ")", ";", "rtx", "op", "=", "(", "cond", "==", "LT", ")", "?", "els", ":", "then", ";", "if", "(", "(", "cond", "==", "LT", "||", "cond", "==", "GE", ")", "&&", "target_mode", "==", "cmp_mode", "&&", "cmp_op2", "==", "CONST0_RTX", "(", "cmp_mode", ")", "&&", "op", "==", "CONST0_RTX", "(", "target_mode", ")", "&&", "s390_vector_mode_supported_p", "(", "target_mode", ")", "&&", "GET_MODE_CLASS", "(", "target_mode", ")", "==", "MODE_VECTOR_INT", ")", "{", "rtx", "negop", "=", "(", "cond", "==", "LT", ")", "?", "then", ":", "els", ";", "int", "shift", "=", "GET_MODE_BITSIZE", "(", "GET_MODE_INNER", "(", "target_mode", ")", ")", "-", "1", ";", "if", "(", "negop", "==", "CONST1_RTX", "(", "target_mode", ")", ")", "{", "rtx", "res", "=", "expand_simple_binop", "(", "cmp_mode", ",", "LSHIFTRT", ",", "cmp_op1", ",", "GEN_INT", "(", "shift", ")", ",", "target", ",", "1", ",", "OPTAB_DIRECT", ")", ";", "if", "(", "res", "!=", "target", ")", "emit_move_insn", "(", "target", ",", "res", ")", ";", "return", ";", "}", "else", "if", "(", "all_ones_operand", "(", "negop", ",", "target_mode", ")", ")", "{", "rtx", "res", "=", "expand_simple_binop", "(", "cmp_mode", ",", "ASHIFTRT", ",", "cmp_op1", ",", "GEN_INT", "(", "shift", ")", ",", "target", ",", "0", ",", "OPTAB_DIRECT", ")", ";", "if", "(", "res", "!=", "target", ")", "emit_move_insn", "(", "target", ",", "res", ")", ";", "return", ";", "}", "}", "result_mode", "=", "mode_for_int_vector", "(", "cmp_mode", ")", ".", "require", "(", ")", ";", "result_target", "=", "gen_reg_rtx", "(", "result_mode", ")", ";", "if", "(", "!", "REG_P", "(", "cmp_op1", ")", ")", "cmp_op1", "=", "force_reg", "(", "GET_MODE", "(", "cmp_op1", ")", ",", "cmp_op1", ")", ";", "if", "(", "!", "REG_P", "(", "cmp_op2", ")", ")", "cmp_op2", "=", "force_reg", "(", "GET_MODE", "(", "cmp_op2", ")", ",", "cmp_op2", ")", ";", "s390_expand_vec_compare", "(", "result_target", ",", "cond", ",", "cmp_op1", ",", "cmp_op2", ")", ";", "if", "(", "all_ones_operand", "(", "then", ",", "GET_MODE", "(", "then", ")", ")", "&&", "const0_operand", "(", "els", ",", "GET_MODE", "(", "els", ")", ")", ")", "{", "emit_move_insn", "(", "target", ",", "gen_rtx_SUBREG", "(", "target_mode", ",", "result_target", ",", "0", ")", ")", ";", "return", ";", "}", "if", "(", "!", "REG_P", "(", "then", ")", ")", "then", "=", "force_reg", "(", "target_mode", ",", "then", ")", ";", "if", "(", "!", "REG_P", "(", "els", ")", ")", "els", "=", "force_reg", "(", "target_mode", ",", "els", ")", ";", "tmp", "=", "gen_rtx_fmt_ee", "(", "EQ", ",", "VOIDmode", ",", "result_target", ",", "CONST0_RTX", "(", "result_mode", ")", ")", ";", "tmp", "=", "gen_rtx_IF_THEN_ELSE", "(", "target_mode", ",", "tmp", ",", "els", ",", "then", ")", ";", "gcc_assert", "(", "target_mode", "==", "GET_MODE", "(", "then", ")", ")", ";", "emit_insn", "(", "gen_rtx_SET", "(", "target", ",", "tmp", ")", ")", ";", "}", "</s>" ]
[ "Generate", "a", "vector", "comparison", "expression", "loading", "either", "elements", "of", "THEN", "or", "ELS", "into", "TARGET", "depending", "on", "the", "comparison", "COND", "of", "CMP_OP1", "and", "CMP_OP2", "." ]
[ "s390", "1", "1", "0", "0" ]
s3907
s390_expand_vcond
s390
MPU
GCC
74
423
1
[]
[ "<s>", "virtual", "const", "SPUSubtarget", "*", "getSubtargetImpl", "(", ")", "const", "{", "return", "&", "Subtarget", ";", "}", "</s>" ]
[ "Virtual", "method", "implemented", "by", "subclasses", "that", "returns", "a", "reference", "to", "that", "target", "'s", "TargetSubtargetInfo-derived", "member", "variable", "." ]
[ "CellSPU", "SPU" ]
SPUTargetMachine1
getSubtargetImpl
CellSPU
MPU
LLVM
75
14
1
[]
[ "<s>", "const", "AArch64RegisterInfo", "*", "getRegisterInfo", "(", ")", "const", "override", "{", "return", "&", "getInstrInfo", "(", ")", "->", "getRegisterInfo", "(", ")", ";", "}", "</s>" ]
[ "getRegisterInfo", "-", "TargetInstrInfo", "is", "a", "superset", "of", "MRegister", "info", "." ]
[ "AArch64", "AArch64" ]
AArch64Subtarget (2)
getRegisterInfo
AArch64
CPU
LLVM
76
20
1
[]
[ "<s>", "int", "rs6000_memory_move_cost", "(", "enum", "machine_mode", "mode", ",", "enum", "reg_class", "class", ",", "int", "in", "ATTRIBUTE_UNUSED", ")", "{", "if", "(", "reg_classes_intersect_p", "(", "class", ",", "GENERAL_REGS", ")", ")", "return", "4", "*", "hard_regno_nregs", "[", "0", "]", "[", "mode", "]", ";", "else", "if", "(", "reg_classes_intersect_p", "(", "class", ",", "FLOAT_REGS", ")", ")", "return", "4", "*", "hard_regno_nregs", "[", "32", "]", "[", "mode", "]", ";", "else", "if", "(", "reg_classes_intersect_p", "(", "class", ",", "ALTIVEC_REGS", ")", ")", "return", "4", "*", "hard_regno_nregs", "[", "FIRST_ALTIVEC_REGNO", "]", "[", "mode", "]", ";", "else", "return", "4", "+", "rs6000_register_move_cost", "(", "mode", ",", "class", ",", "GENERAL_REGS", ")", ";", "}", "</s>" ]
[ "A", "C", "expressions", "returning", "the", "cost", "of", "moving", "data", "of", "MODE", "from", "a", "register", "to", "or", "from", "memory", "." ]
[ "rs6000", "4", "0", "4", "32", "4", "4" ]
rs60003
rs6000_memory_move_cost
rs6000
CPU
GCC
77
92
1
[]
[ "<s>", "bool", "JVMTargetLowering", "::", "CanLowerReturn", "(", "CallingConv", "::", "ID", ",", "MachineFunction", "&", ",", "bool", ",", "const", "SmallVectorImpl", "<", "ISD", "::", "OutputArg", ">", "&", "Outs", ",", "LLVMContext", "&", ")", "const", "{", "return", "Outs", ".", "size", "(", ")", "<=", "1", ";", "}", "</s>" ]
[ "This", "hook", "should", "be", "implemented", "to", "check", "whether", "the", "return", "values", "described", "by", "the", "Outs", "array", "can", "fit", "into", "the", "return", "registers", "." ]
[ "JVM", "JVM", "ISD::OutputArg", "1" ]
JVMISelLowering
CanLowerReturn
JVM
Virtual ISA
LLVM
78
39
1
[]
[ "<s>", "static", "bool", "dispatch_violation", "(", "void", ")", "{", "if", "(", "dispatch_window_list", "->", "next", ")", "return", "dispatch_window_list", "->", "next", "->", "violation", ";", "return", "dispatch_window_list", "->", "violation", ";", "}", "</s>" ]
[ "Return", "true", "if", "a", "dispatch", "violation", "encountered", "." ]
[ "i386" ]
i3864
dispatch_violation
i386
CPU
GCC
79
26
1
[]
[ "<s>", "static", "int", "eco32_num_arg_regs", "(", "enum", "machine_mode", "mode", ",", "const_tree", "type", ")", "{", "int", "size", ";", "if", "(", "targetm", ".", "calls", ".", "must_pass_in_stack", "(", "mode", ",", "type", ")", ")", "return", "0", ";", "if", "(", "type", "&&", "mode", "==", "BLKmode", ")", "size", "=", "int_size_in_bytes", "(", "type", ")", ";", "else", "size", "=", "GET_MODE_SIZE", "(", "mode", ")", ";", "return", "(", "size", "+", "UNITS_PER_WORD", "-", "1", ")", "/", "UNITS_PER_WORD", ";", "}", "</s>" ]
[ "Compute", "the", "number", "of", "word", "sized", "registers", "needed", "to", "hold", "a", "function", "argument", "of", "mode", "INT_MODE", "and", "tree", "type", "TYPE", "." ]
[ "eco32", "0", "1" ]
eco32
eco32_num_arg_regs
eco32
MPU
GCC
80
66
1
[]
[ "<s>", "static", "bool", "aarch64_rtx_arith_op_extract_p", "(", "rtx", "x", ",", "machine_mode", "mode", ")", "{", "if", "(", "GET_CODE", "(", "x", ")", "==", "SIGN_EXTRACT", "||", "GET_CODE", "(", "x", ")", "==", "ZERO_EXTRACT", ")", "{", "rtx", "op0", "=", "XEXP", "(", "x", ",", "0", ")", ";", "rtx", "op1", "=", "XEXP", "(", "x", ",", "1", ")", ";", "rtx", "op2", "=", "XEXP", "(", "x", ",", "2", ")", ";", "if", "(", "GET_CODE", "(", "op0", ")", "==", "MULT", "&&", "CONST_INT_P", "(", "op1", ")", "&&", "op2", "==", "const0_rtx", "&&", "CONST_INT_P", "(", "XEXP", "(", "op0", ",", "1", ")", ")", "&&", "aarch64_is_extend_from_extract", "(", "mode", ",", "XEXP", "(", "op0", ",", "1", ")", ",", "op1", ")", ")", "{", "return", "true", ";", "}", "}", "else", "if", "(", "GET_CODE", "(", "x", ")", "==", "SIGN_EXTEND", "||", "GET_CODE", "(", "x", ")", "==", "ZERO_EXTEND", ")", "return", "REG_P", "(", "XEXP", "(", "x", ",", "0", ")", ")", ";", "return", "false", ";", "}", "</s>" ]
[ "Return", "true", "if", "X", "is", "a", "zero", "or", "sign", "extract", "usable", "in", "an", "ADD", "or", "SUB", "(", "extended", "register", ")", "instruction", "." ]
[ "aarch64", "0", "1", "2", "1", "1", "0" ]
aarch643
aarch64_rtx_arith_op_extract_p
aarch64
CPU
GCC
81
138
1
[]
[ "<s>", "void", "ScheduleDAGPostRA", "::", "startBlock", "(", "MachineBasicBlock", "*", "BB", ")", "{", "ScheduleDAGInstrs", "::", "startBlock", "(", "BB", ")", ";", "if", "(", "AntiDepBreak", "!=", "NULL", ")", "AntiDepBreak", "->", "StartBlock", "(", "BB", ")", ";", "}", "</s>" ]
[ "Prepares", "to", "perform", "scheduling", "in", "the", "given", "block", "." ]
[ "Patmos" ]
PatmosPostRAScheduler
startBlock
Patmos
VLIW
LLVM
82
31
1
[]
[ "<s>", "bool", "fixupNeedsRelaxation", "(", "const", "MCFixup", "&", "Fixup", ",", "uint64_t", "Value", ",", "const", "MCRelaxableFragment", "*", "DF", ",", "const", "MCAsmLayout", "&", "Layout", ")", "const", "override", "{", "return", "false", ";", "}", "</s>" ]
[ "Simple", "predicate", "for", "targets", "where", "!", "Resolved", "implies", "requiring", "relaxation", "." ]
[ "R600" ]
AMDGPUAsmBackend1
fixupNeedsRelaxation
R600
GPU
LLVM
83
28
1
[]
[ "<s>", "InstructionCost", "PPCTTIImpl", "::", "getArithmeticInstrCost", "(", "unsigned", "Opcode", ",", "Type", "*", "Ty", ",", "TTI", "::", "TargetCostKind", "CostKind", ",", "TTI", "::", "OperandValueKind", "Op1Info", ",", "TTI", "::", "OperandValueKind", "Op2Info", ",", "TTI", "::", "OperandValueProperties", "Opd1PropInfo", ",", "TTI", "::", "OperandValueProperties", "Opd2PropInfo", ",", "ArrayRef", "<", "const", "Value", "*", ">", "Args", ",", "const", "Instruction", "*", "CxtI", ")", "{", "assert", "(", "TLI", "->", "InstructionOpcodeToISD", "(", "Opcode", ")", "&&", "\"Invalid opcode\"", ")", ";", "InstructionCost", "CostFactor", "=", "vectorCostAdjustmentFactor", "(", "Opcode", ",", "Ty", ",", "nullptr", ")", ";", "if", "(", "!", "CostFactor", ".", "isValid", "(", ")", ")", "return", "InstructionCost", "::", "getMax", "(", ")", ";", "if", "(", "CostKind", "!=", "TTI", "::", "TCK_RecipThroughput", ")", "return", "BaseT", "::", "getArithmeticInstrCost", "(", "Opcode", ",", "Ty", ",", "CostKind", ",", "Op1Info", ",", "Op2Info", ",", "Opd1PropInfo", ",", "Opd2PropInfo", ",", "Args", ",", "CxtI", ")", ";", "InstructionCost", "Cost", "=", "BaseT", "::", "getArithmeticInstrCost", "(", "Opcode", ",", "Ty", ",", "CostKind", ",", "Op1Info", ",", "Op2Info", ",", "Opd1PropInfo", ",", "Opd2PropInfo", ")", ";", "return", "Cost", "*", "CostFactor", ";", "}", "</s>" ]
[ "This", "is", "an", "approximation", "of", "reciprocal", "throughput", "of", "a", "math/logic", "op", "." ]
[ "PowerPC", "PPC", "\"Invalid opcode\"" ]
PPCTargetTransformInfo14
getArithmeticInstrCost
PowerPC
CPU
LLVM
84
151
1
[]
[ "<s>", "std", "::", "pair", "<", "unsigned", ",", "const", "TargetRegisterClass", "*", ">", "AlphaTargetLowering", "::", "getRegForInlineAsmConstraint", "(", "const", "std", "::", "string", "&", "Constraint", ",", "EVT", "VT", ")", "const", "{", "if", "(", "Constraint", ".", "size", "(", ")", "==", "1", ")", "{", "switch", "(", "Constraint", "[", "0", "]", ")", "{", "case", "'r'", ":", "return", "std", "::", "make_pair", "(", "0U", ",", "Alpha", "::", "GPRCRegisterClass", ")", ";", "case", "'f'", ":", "return", "VT", "==", "MVT", "::", "f64", "?", "std", "::", "make_pair", "(", "0U", ",", "Alpha", "::", "F8RCRegisterClass", ")", ":", "std", "::", "make_pair", "(", "0U", ",", "Alpha", "::", "F4RCRegisterClass", ")", ";", "}", "}", "return", "TargetLowering", "::", "getRegForInlineAsmConstraint", "(", "Constraint", ",", "VT", ")", ";", "}", "</s>" ]
[ "Given", "a", "physical", "register", "constraint", "(", "e.g", "." ]
[ "Alpha", "Alpha", "1", "0", "0U", "Alpha::GPRCRegisterClass", "MVT::f64", "0U", "Alpha::F8RCRegisterClass", "0U", "Alpha::F4RCRegisterClass" ]
AlphaISelLowering2
getRegForInlineAsmConstraint
Alpha
MPU
LLVM
85
105
1
[]
[ "<s>", "void", "print", "(", ")", "{", "if", "(", "numSymbols", "==", "0", ")", "{", "for", "(", "unsigned", "i", "=", "0", ";", "i", "<", "size", ";", "i", "++", ")", "{", "if", "(", "i", ")", "O", "<<", "\", \"", ";", "O", "<<", "(", "unsigned", "int", ")", "buffer", "[", "i", "]", ";", "}", "}", "else", "{", "unsigned", "int", "pos", "=", "0", ";", "unsigned", "int", "nSym", "=", "0", ";", "unsigned", "int", "nextSymbolPos", "=", "symbolPosInBuffer", "[", "nSym", "]", ";", "unsigned", "int", "nBytes", "=", "4", ";", "if", "(", "static_cast", "<", "const", "NVPTXTargetMachine", "&", ">", "(", "AP", ".", "TM", ")", ".", "is64Bit", "(", ")", ")", "nBytes", "=", "8", ";", "for", "(", "pos", "=", "0", ";", "pos", "<", "size", ";", "pos", "+=", "nBytes", ")", "{", "if", "(", "pos", ")", "O", "<<", "\", \"", ";", "if", "(", "pos", "==", "nextSymbolPos", ")", "{", "const", "Value", "*", "v", "=", "Symbols", "[", "nSym", "]", ";", "const", "Value", "*", "v0", "=", "SymbolsBeforeStripping", "[", "nSym", "]", ";", "if", "(", "const", "GlobalValue", "*", "GVar", "=", "dyn_cast", "<", "GlobalValue", ">", "(", "v", ")", ")", "{", "MCSymbol", "*", "Name", "=", "AP", ".", "getSymbol", "(", "GVar", ")", ";", "PointerType", "*", "PTy", "=", "dyn_cast", "<", "PointerType", ">", "(", "v0", "->", "getType", "(", ")", ")", ";", "bool", "IsNonGenericPointer", "=", "false", ";", "if", "(", "PTy", "&&", "PTy", "->", "getAddressSpace", "(", ")", "!=", "0", ")", "{", "IsNonGenericPointer", "=", "true", ";", "}", "if", "(", "EmitGeneric", "&&", "!", "isa", "<", "Function", ">", "(", "v", ")", "&&", "!", "IsNonGenericPointer", ")", "{", "O", "<<", "\"generic(\"", ";", "Name", "->", "print", "(", "O", ",", "AP", ".", "MAI", ")", ";", "O", "<<", "\")\"", ";", "}", "else", "{", "Name", "->", "print", "(", "O", ",", "AP", ".", "MAI", ")", ";", "}", "}", "else", "if", "(", "const", "ConstantExpr", "*", "CExpr", "=", "dyn_cast", "<", "ConstantExpr", ">", "(", "v0", ")", ")", "{", "const", "MCExpr", "*", "Expr", "=", "AP", ".", "lowerConstantForGV", "(", "cast", "<", "Constant", ">", "(", "CExpr", ")", ",", "false", ")", ";", "AP", ".", "printMCExpr", "(", "*", "Expr", ",", "O", ")", ";", "}", "else", "llvm_unreachable", "(", "\"symbol type unknown\"", ")", ";", "nSym", "++", ";", "if", "(", "nSym", ">=", "numSymbols", ")", "nextSymbolPos", "=", "size", "+", "1", ";", "else", "nextSymbolPos", "=", "symbolPosInBuffer", "[", "nSym", "]", ";", "}", "else", "if", "(", "nBytes", "==", "4", ")", "O", "<<", "*", "(", "unsigned", "int", "*", ")", "(", "&", "buffer", "[", "pos", "]", ")", ";", "else", "O", "<<", "*", "(", "unsigned", "long", "long", "*", ")", "(", "&", "buffer", "[", "pos", "]", ")", ";", "}", "}", "}", "</s>" ]
[ "print", "-", "Print", "a", "debug", "representation", "of", "the", "operand", "to", "the", "given", "stream", "." ]
[ "NVPTX", "0", "0", "\", \"", "0", "0", "4", "NVPTX", "8", "0", "\", \"", "0", "\"generic(\"", "\")\"", "\"symbol type unknown\"", "1", "4" ]
NVPTXAsmPrinter
print
NVPTX
GPU
LLVM
86
389
1
[]
[ "<s>", "void", "bfin_expand_call", "(", "rtx", "retval", ",", "rtx", "fnaddr", ",", "rtx", "callarg1", ",", "rtx", "cookie", ",", "int", "sibcall", ")", "{", "rtx", "use", "=", "NULL", ",", "call", ";", "rtx", "callee", "=", "XEXP", "(", "fnaddr", ",", "0", ")", ";", "rtx", "pat", "=", "gen_rtx_PARALLEL", "(", "VOIDmode", ",", "rtvec_alloc", "(", "sibcall", "?", "3", ":", "2", ")", ")", ";", "if", "(", "cookie", "==", "NULL_RTX", ")", "cookie", "=", "const0_rtx", ";", "if", "(", "flag_pic", "&&", "GET_CODE", "(", "callee", ")", "==", "SYMBOL_REF", "&&", "!", "SYMBOL_REF_LOCAL_P", "(", "callee", ")", ")", "use_reg", "(", "&", "use", ",", "pic_offset_table_rtx", ")", ";", "if", "(", "(", "!", "register_no_elim_operand", "(", "callee", ",", "Pmode", ")", "&&", "GET_CODE", "(", "callee", ")", "!=", "SYMBOL_REF", ")", "||", "(", "GET_CODE", "(", "callee", ")", "==", "SYMBOL_REF", "&&", "(", "flag_pic", "||", "bfin_longcall_p", "(", "callee", ",", "INTVAL", "(", "cookie", ")", ")", ")", ")", ")", "{", "callee", "=", "copy_to_mode_reg", "(", "Pmode", ",", "callee", ")", ";", "fnaddr", "=", "gen_rtx_MEM", "(", "Pmode", ",", "callee", ")", ";", "}", "call", "=", "gen_rtx_CALL", "(", "VOIDmode", ",", "fnaddr", ",", "callarg1", ")", ";", "if", "(", "retval", ")", "call", "=", "gen_rtx_SET", "(", "VOIDmode", ",", "retval", ",", "call", ")", ";", "XVECEXP", "(", "pat", ",", "0", ",", "0", ")", "=", "call", ";", "XVECEXP", "(", "pat", ",", "0", ",", "1", ")", "=", "gen_rtx_USE", "(", "VOIDmode", ",", "cookie", ")", ";", "if", "(", "sibcall", ")", "XVECEXP", "(", "pat", ",", "0", ",", "2", ")", "=", "gen_rtx_RETURN", "(", "VOIDmode", ")", ";", "call", "=", "emit_call_insn", "(", "pat", ")", ";", "if", "(", "use", ")", "CALL_INSN_FUNCTION_USAGE", "(", "call", ")", "=", "use", ";", "}", "</s>" ]
[ "Expand", "a", "call", "instruction", ".", "FNADDR", "is", "the", "call", "target", ",", "RETVAL", "the", "return", "value", ".", "COOKIE", "is", "a", "CONST_INT", "holding", "the", "call_cookie", "prepared", "init_cumulative_args", ".", "SIBCALL", "is", "nonzero", "if", "this", "is", "a", "sibling", "call", "." ]
[ "bfin", "0", "3", "2", "0", "0", "0", "1", "0", "2" ]
bfin2
bfin_expand_call
bfin
DSP
GCC
87
240
1
[]
[ "<s>", "static", "void", "riscv_expand_mult_with_const_int", "(", "machine_mode", "mode", ",", "rtx", "dest", ",", "rtx", "multiplicand", ",", "int", "multiplier", ")", "{", "if", "(", "multiplier", "==", "0", ")", "{", "riscv_emit_move", "(", "dest", ",", "GEN_INT", "(", "0", ")", ")", ";", "return", ";", "}", "bool", "neg_p", "=", "multiplier", "<", "0", ";", "int", "multiplier_abs", "=", "abs", "(", "multiplier", ")", ";", "if", "(", "multiplier_abs", "==", "1", ")", "{", "if", "(", "neg_p", ")", "riscv_expand_op", "(", "NEG", ",", "mode", ",", "dest", ",", "multiplicand", ",", "NULL_RTX", ")", ";", "else", "riscv_emit_move", "(", "dest", ",", "multiplicand", ")", ";", "}", "else", "{", "if", "(", "pow2p_hwi", "(", "multiplier_abs", ")", ")", "{", "riscv_expand_op", "(", "ASHIFT", ",", "mode", ",", "dest", ",", "multiplicand", ",", "gen_int_mode", "(", "exact_log2", "(", "multiplier_abs", ")", ",", "QImode", ")", ")", ";", "if", "(", "neg_p", ")", "riscv_expand_op", "(", "NEG", ",", "mode", ",", "dest", ",", "dest", ",", "NULL_RTX", ")", ";", "}", "else", "if", "(", "pow2p_hwi", "(", "multiplier_abs", "+", "1", ")", ")", "{", "riscv_expand_op", "(", "ASHIFT", ",", "mode", ",", "dest", ",", "multiplicand", ",", "gen_int_mode", "(", "exact_log2", "(", "multiplier_abs", "+", "1", ")", ",", "QImode", ")", ")", ";", "if", "(", "neg_p", ")", "riscv_expand_op", "(", "MINUS", ",", "mode", ",", "dest", ",", "multiplicand", ",", "dest", ")", ";", "else", "riscv_expand_op", "(", "MINUS", ",", "mode", ",", "dest", ",", "dest", ",", "multiplicand", ")", ";", "}", "else", "if", "(", "pow2p_hwi", "(", "multiplier", "-", "1", ")", ")", "{", "riscv_expand_op", "(", "ASHIFT", ",", "mode", ",", "dest", ",", "multiplicand", ",", "gen_int_mode", "(", "exact_log2", "(", "multiplier_abs", "-", "1", ")", ",", "QImode", ")", ")", ";", "riscv_expand_op", "(", "PLUS", ",", "mode", ",", "dest", ",", "dest", ",", "multiplicand", ")", ";", "if", "(", "neg_p", ")", "riscv_expand_op", "(", "NEG", ",", "mode", ",", "dest", ",", "dest", ",", "NULL_RTX", ")", ";", "}", "else", "{", "gcc_assert", "(", "TARGET_MUL", "&&", "\"M-extension must be enabled to calculate the poly_int \"", "\"size/offset.\"", ")", ";", "riscv_emit_move", "(", "dest", ",", "gen_int_mode", "(", "multiplier", ",", "mode", ")", ")", ";", "riscv_expand_op", "(", "MULT", ",", "mode", ",", "dest", ",", "dest", ",", "multiplicand", ")", ";", "}", "}", "}", "</s>" ]
[ "Expand", "mult", "operation", "with", "constant", "integer", ",", "multiplicand", "also", "used", "as", "a", "*", "temporary", "register", "." ]
[ "riscv", "0", "0", "0", "1", "1", "1", "1", "1", "\"M-extension must be enabled to calculate the poly_int \"", "\"size/offset.\"" ]
riscv1
riscv_expand_mult_with_const_int
riscv
CPU
GCC
88
303
1
[]
[ "<s>", "StringRef", "getPassName", "(", ")", "const", "override", "{", "return", "\"SI Fix VGPR copies\"", ";", "}", "</s>" ]
[ "getPassName", "-", "Return", "a", "nice", "clean", "name", "for", "a", "pass", "." ]
[ "AMDGPU", "\"SI Fix VGPR copies\"" ]
SIFixVGPRCopies
getPassName
AMDGPU
GPU
LLVM
89
11
1
[]
[ "<s>", "SDValue", "P2TargetLowering", "::", "LowerOperation", "(", "SDValue", "Op", ",", "SelectionDAG", "&", "DAG", ")", "const", "{", "switch", "(", "Op", ".", "getOpcode", "(", ")", ")", "{", "case", "ISD", "::", "GlobalAddress", ":", "return", "lowerGlobalAddress", "(", "Op", ",", "DAG", ")", ";", "case", "ISD", "::", "VASTART", ":", "return", "lowerVASTART", "(", "Op", ",", "DAG", ")", ";", "case", "ISD", "::", "VAARG", ":", "return", "lowerVAARG", "(", "Op", ",", "DAG", ")", ";", "case", "ISD", "::", "JumpTable", ":", "return", "lowerJumpTable", "(", "Op", ",", "DAG", ")", ";", "}", "return", "SDValue", "(", ")", ";", "}", "</s>" ]
[ "LowerOperation", "-", "Provide", "custom", "lowering", "hooks", "for", "some", "operations", "." ]
[ "P2", "P2", "ISD::GlobalAddress", "ISD::VASTART", "ISD::VAARG", "ISD::JumpTable" ]
P2ISelLowering
LowerOperation
P2
MPU
LLVM
90
82
1
[]
[ "<s>", "void", "NVPTXPassConfig", "::", "addMachineSSAOptimization", "(", ")", "{", "if", "(", "addPass", "(", "&", "EarlyTailDuplicateID", ")", ")", "printAndVerify", "(", "\"After Pre-RegAlloc TailDuplicate\"", ")", ";", "addPass", "(", "&", "OptimizePHIsID", ")", ";", "addPass", "(", "&", "StackColoringID", ")", ";", "addPass", "(", "&", "LocalStackSlotAllocationID", ")", ";", "addPass", "(", "&", "DeadMachineInstructionElimID", ")", ";", "printAndVerify", "(", "\"After codegen DCE pass\"", ")", ";", "if", "(", "addILPOpts", "(", ")", ")", "printAndVerify", "(", "\"After ILP optimizations\"", ")", ";", "addPass", "(", "&", "MachineLICMID", ")", ";", "addPass", "(", "&", "MachineCSEID", ")", ";", "addPass", "(", "&", "MachineSinkingID", ")", ";", "printAndVerify", "(", "\"After Machine LICM, CSE and Sinking passes\"", ")", ";", "addPass", "(", "&", "PeepholeOptimizerID", ")", ";", "printAndVerify", "(", "\"After codegen peephole optimization pass\"", ")", ";", "}", "</s>" ]
[ "Methods", "with", "trivial", "inline", "returns", "are", "convenient", "points", "in", "the", "common", "codegen", "pass", "pipeline", "where", "targets", "may", "insert", "passes", "." ]
[ "NVPTX", "NVPTX", "\"After Pre-RegAlloc TailDuplicate\"", "\"After codegen DCE pass\"", "\"After ILP optimizations\"", "\"After Machine LICM, CSE and Sinking passes\"", "\"After codegen peephole optimization pass\"" ]
NVPTXTargetMachine (2)
addMachineSSAOptimization
NVPTX
GPU
LLVM
91
95
1
[]
[ "<s>", "const", "char", "*", "output_a_rotate", "(", "enum", "rtx_code", "code", ",", "rtx", "*", "operands", ")", "{", "rtx", "dst", "=", "operands", "[", "0", "]", ";", "rtx", "rotate_amount", "=", "operands", "[", "2", "]", ";", "enum", "shift_mode", "rotate_mode", ";", "enum", "shift_type", "rotate_type", ";", "const", "char", "*", "insn_buf", ";", "int", "bits", ";", "int", "amount", ";", "enum", "machine_mode", "mode", "=", "GET_MODE", "(", "dst", ")", ";", "gcc_assert", "(", "GET_CODE", "(", "rotate_amount", ")", "==", "CONST_INT", ")", ";", "switch", "(", "mode", ")", "{", "case", "QImode", ":", "rotate_mode", "=", "QIshift", ";", "break", ";", "case", "HImode", ":", "rotate_mode", "=", "HIshift", ";", "break", ";", "case", "SImode", ":", "rotate_mode", "=", "SIshift", ";", "break", ";", "default", ":", "gcc_unreachable", "(", ")", ";", "}", "switch", "(", "code", ")", "{", "case", "ROTATERT", ":", "rotate_type", "=", "SHIFT_ASHIFT", ";", "break", ";", "case", "ROTATE", ":", "rotate_type", "=", "SHIFT_LSHIFTRT", ";", "break", ";", "default", ":", "gcc_unreachable", "(", ")", ";", "}", "amount", "=", "INTVAL", "(", "rotate_amount", ")", ";", "if", "(", "amount", "<", "0", ")", "amount", "=", "0", ";", "if", "(", "(", "unsigned", "int", ")", "amount", ">", "GET_MODE_BITSIZE", "(", "mode", ")", ")", "amount", "=", "GET_MODE_BITSIZE", "(", "mode", ")", ";", "if", "(", "(", "unsigned", "int", ")", "amount", ">", "GET_MODE_BITSIZE", "(", "mode", ")", "/", "(", "unsigned", ")", "2", ")", "{", "amount", "=", "GET_MODE_BITSIZE", "(", "mode", ")", "-", "amount", ";", "rotate_type", "=", "(", "rotate_type", "==", "SHIFT_ASHIFT", ")", "?", "SHIFT_LSHIFTRT", ":", "SHIFT_ASHIFT", ";", "}", "if", "(", "(", "mode", "==", "HImode", "&&", "TARGET_H8300", "&&", "amount", ">=", "5", ")", "||", "(", "mode", "==", "HImode", "&&", "TARGET_H8300H", "&&", "amount", ">=", "6", ")", "||", "(", "mode", "==", "HImode", "&&", "TARGET_H8300S", "&&", "amount", "==", "8", ")", "||", "(", "mode", "==", "SImode", "&&", "TARGET_H8300H", "&&", "amount", ">=", "10", ")", "||", "(", "mode", "==", "SImode", "&&", "TARGET_H8300S", "&&", "amount", ">=", "13", ")", ")", "{", "switch", "(", "mode", ")", "{", "case", "HImode", ":", "insn_buf", "=", "\"xor.b\\t%s0,%t0\\n\\txor.b\\t%t0,%s0\\n\\txor.b\\t%s0,%t0\"", ";", "output_asm_insn", "(", "insn_buf", ",", "operands", ")", ";", "break", ";", "case", "SImode", ":", "insn_buf", "=", "\"xor.w\\t%e0,%f0\\n\\txor.w\\t%f0,%e0\\n\\txor.w\\t%e0,%f0\"", ";", "output_asm_insn", "(", "insn_buf", ",", "operands", ")", ";", "break", ";", "default", ":", "gcc_unreachable", "(", ")", ";", "}", "amount", "=", "GET_MODE_BITSIZE", "(", "mode", ")", "/", "2", "-", "amount", ";", "rotate_type", "=", "(", "rotate_type", "==", "SHIFT_ASHIFT", ")", "?", "SHIFT_LSHIFTRT", ":", "SHIFT_ASHIFT", ";", "}", "for", "(", "bits", "=", "TARGET_H8300S", "?", "2", ":", "1", ";", "bits", ">", "0", ";", "bits", "/=", "2", ")", "{", "if", "(", "bits", "==", "2", ")", "insn_buf", "=", "rotate_two", "[", "rotate_type", "]", "[", "rotate_mode", "]", ";", "else", "insn_buf", "=", "rotate_one", "[", "cpu_type", "]", "[", "rotate_type", "]", "[", "rotate_mode", "]", ";", "for", "(", ";", "amount", ">=", "bits", ";", "amount", "-=", "bits", ")", "output_asm_insn", "(", "insn_buf", ",", "operands", ")", ";", "}", "return", "\"\"", ";", "}", "</s>" ]
[ "Output", "a", "rotate", "insn", "." ]
[ "h8300", "0", "2", "0", "0", "2", "5", "6", "8", "10", "13", "\"xor.b\\t%s0,%t0\\n\\txor.b\\t%t0,%s0\\n\\txor.b\\t%s0,%t0\"", "\"xor.w\\t%e0,%f0\\n\\txor.w\\t%f0,%e0\\n\\txor.w\\t%e0,%f0\"", "2", "2", "1", "0", "2", "2", "\"\"" ]
h83003
output_a_rotate
h8300
MPU
GCC
92
418
1
[]
[ "<s>", "bool", "ARMFrameLowering", "::", "enableShrinkWrapping", "(", "const", "MachineFunction", "&", "MF", ")", "const", "{", "if", "(", "STI", ".", "hasV8_1MMainlineOps", "(", ")", "&&", "MF", ".", "getInfo", "<", "ARMFunctionInfo", ">", "(", ")", "->", "isCmseNSEntryFunction", "(", ")", ")", "return", "false", ";", "return", "true", ";", "}", "</s>" ]
[ "Returns", "true", "if", "the", "target", "will", "correctly", "handle", "shrink", "wrapping", "." ]
[ "ARM", "ARM", "ARM" ]
ARMFrameLowering103
enableShrinkWrapping
ARM
CPU
LLVM
93
40
1
[]
[ "<s>", "bool", "PPCTTIImpl", "::", "canSaveCmp", "(", "Loop", "*", "L", ",", "BranchInst", "*", "*", "BI", ",", "ScalarEvolution", "*", "SE", ",", "LoopInfo", "*", "LI", ",", "DominatorTree", "*", "DT", ",", "AssumptionCache", "*", "AC", ",", "TargetLibraryInfo", "*", "LibInfo", ")", "{", "for", "(", "Loop", "::", "iterator", "I", "=", "L", "->", "begin", "(", ")", ",", "E", "=", "L", "->", "end", "(", ")", ";", "I", "!=", "E", ";", "++", "I", ")", "if", "(", "canSaveCmp", "(", "*", "I", ",", "BI", ",", "SE", ",", "LI", ",", "DT", ",", "AC", ",", "LibInfo", ")", ")", "return", "false", ";", "HardwareLoopInfo", "HWLoopInfo", "(", "L", ")", ";", "if", "(", "!", "HWLoopInfo", ".", "canAnalyze", "(", "*", "LI", ")", ")", "return", "false", ";", "if", "(", "!", "isHardwareLoopProfitable", "(", "L", ",", "*", "SE", ",", "*", "AC", ",", "LibInfo", ",", "HWLoopInfo", ")", ")", "return", "false", ";", "if", "(", "!", "HWLoopInfo", ".", "isHardwareLoopCandidate", "(", "*", "SE", ",", "*", "LI", ",", "*", "DT", ")", ")", "return", "false", ";", "*", "BI", "=", "HWLoopInfo", ".", "ExitBranch", ";", "return", "true", ";", "}", "</s>" ]
[ "Return", "true", "if", "the", "target", "can", "save", "a", "compare", "for", "loop", "count", ",", "for", "example", "hardware", "loop", "saves", "a", "compare", "." ]
[ "PowerPC", "PPC" ]
PPCTargetTransformInfo1
canSaveCmp
PowerPC
CPU
LLVM
94
158
1
[]
[ "<s>", "static", "void", "ix86_emit_mode_set", "(", "int", "entity", ",", "int", "mode", ",", "int", "prev_mode", "ATTRIBUTE_UNUSED", ",", "HARD_REG_SET", "regs_live", ")", "{", "switch", "(", "entity", ")", "{", "case", "X86_DIRFLAG", ":", "if", "(", "mode", "==", "X86_DIRFLAG_RESET", ")", "emit_insn", "(", "gen_cld", "(", ")", ")", ";", "break", ";", "case", "AVX_U128", ":", "if", "(", "mode", "==", "AVX_U128_CLEAN", ")", "ix86_avx_emit_vzeroupper", "(", "regs_live", ")", ";", "break", ";", "case", "I387_TRUNC", ":", "case", "I387_FLOOR", ":", "case", "I387_CEIL", ":", "case", "I387_MASK_PM", ":", "if", "(", "mode", "!=", "I387_CW_ANY", "&&", "mode", "!=", "I387_CW_UNINITIALIZED", ")", "emit_i387_cw_initialization", "(", "mode", ")", ";", "break", ";", "default", ":", "gcc_unreachable", "(", ")", ";", "}", "}", "</s>" ]
[ "Generate", "one", "or", "more", "insns", "to", "set", "ENTITY", "to", "MODE", ".", "HARD_REG_LIVE", "is", "the", "set", "of", "hard", "registers", "live", "at", "the", "point", "where", "the", "insn", "(", "s", ")", "are", "to", "be", "inserted", "." ]
[ "i386" ]
i3866
ix86_emit_mode_set
i386
CPU
GCC
95
94
1
[]
[ "<s>", "bool", "VEPassConfig", "::", "addInstSelector", "(", ")", "{", "addPass", "(", "createVEISelDag", "(", "getVETargetMachine", "(", ")", ")", ")", ";", "return", "false", ";", "}", "</s>" ]
[ "addInstSelector", "-", "This", "method", "should", "install", "an", "instruction", "selector", "pass", ",", "which", "converts", "from", "LLVM", "code", "to", "machine", "instructions", "." ]
[ "VE", "VE", "VE", "VE" ]
VETargetMachine
addInstSelector
VE
CPU
LLVM
96
21
1
[]
[ "<s>", "static", "bool", "is_costly_group", "(", "rtx", "*", "group_insns", ",", "rtx", "next_insn", ")", "{", "int", "i", ";", "int", "issue_rate", "=", "rs6000_issue_rate", "(", ")", ";", "for", "(", "i", "=", "0", ";", "i", "<", "issue_rate", ";", "i", "++", ")", "{", "sd_iterator_def", "sd_it", ";", "dep_t", "dep", ";", "rtx", "insn", "=", "group_insns", "[", "i", "]", ";", "if", "(", "!", "insn", ")", "continue", ";", "FOR_EACH_DEP", "(", "insn", ",", "SD_LIST_RES_FORW", ",", "sd_it", ",", "dep", ")", "{", "rtx", "next", "=", "DEP_CON", "(", "dep", ")", ";", "if", "(", "next", "==", "next_insn", "&&", "rs6000_is_costly_dependence", "(", "dep", ",", "dep_cost", "(", "dep", ")", ",", "0", ")", ")", "return", "true", ";", "}", "}", "return", "false", ";", "}", "</s>" ]
[ "Return", "true", "if", "it", "is", "recommended", "to", "keep", "NEXT_INSN", "``", "far", "''", "(", "in", "a", "separate", "dispatch", "group", ")", "from", "the", "insns", "in", "GROUP_INSNS", ".", "Return", "false", "otherwise", "." ]
[ "rs6000", "0", "0" ]
rs6000
is_costly_group
rs6000
CPU
GCC
97
103
1
[]
[ "<s>", "const", "char", "*", "avr_double_lib", "(", "int", "argc", ",", "const", "char", "*", "*", "argv", ")", "{", "int", "dbl", "=", "64", ";", "int", "dbl", "=", "32", ";", "int", "ldb", "=", "64", ";", "int", "ldb", "=", "32", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "argc", ";", "i", "++", ")", "{", "if", "(", "strcmp", "(", "argv", "[", "i", "]", ",", "\"mdouble=32\"", ")", "==", "0", ")", "{", "dbl", "=", "32", ";", "ldb", "=", "dbl", ";", "}", "else", "if", "(", "strcmp", "(", "argv", "[", "i", "]", ",", "\"mdouble=64\"", ")", "==", "0", ")", "{", "ldb", "=", "dbl", "=", "64", ";", "}", "else", "if", "(", "strcmp", "(", "argv", "[", "i", "]", ",", "\"mlong-double=32\"", ")", "==", "0", ")", "{", "ldb", "=", "dbl", "=", "32", ";", "}", "else", "if", "(", "strcmp", "(", "argv", "[", "i", "]", ",", "\"mlong-double=64\"", ")", "==", "0", ")", "{", "ldb", "=", "64", ";", "dbl", "=", "ldb", ";", "}", "}", "return", "concat", "(", "\" %<mdouble=* -mdouble=\"", ",", "dbl", "==", "32", "?", "\"32\"", ":", "\"64\"", ",", "\" %<mlong-double=* -mlong-double=\"", ",", "ldb", "==", "32", "?", "\"32\"", ":", "\"64\"", ",", "NULL", ")", ";", "}", "</s>" ]
[ "Re-build", "the", "-mdouble=", "and", "-mlong-double=", "options", ".", "This", "is", "needed", "because", "these", "options", "are", "not", "independent", "of", "each", "other", "." ]
[ "avr", "64", "32", "64", "32", "0", "\"mdouble=32\"", "0", "32", "\"mdouble=64\"", "0", "64", "\"mlong-double=32\"", "0", "32", "\"mlong-double=64\"", "0", "64", "\" %<mdouble=* -mdouble=\"", "32", "\"32\"", "\"64\"", "\" %<mlong-double=* -mlong-double=\"", "32", "\"32\"", "\"64\"" ]
driver-avr
avr_double_lib
avr
MPU
GCC
98
173
1
[]
[ "<s>", "BitVector", "MipsRegisterInfo", "::", "getReservedRegs", "(", "const", "MachineFunction", "&", "MF", ")", "const", "{", "static", "const", "unsigned", "ReservedCPURegs", "[", "]", "=", "{", "Mips", "::", "ZERO", ",", "Mips", "::", "AT", ",", "Mips", "::", "K0", ",", "Mips", "::", "K1", ",", "Mips", "::", "GP", ",", "Mips", "::", "SP", ",", "Mips", "::", "FP", ",", "Mips", "::", "RA", ",", "0", "}", ";", "static", "const", "unsigned", "ReservedCPU64Regs", "[", "]", "=", "{", "Mips", "::", "ZERO_64", ",", "Mips", "::", "AT_64", ",", "Mips", "::", "K0_64", ",", "Mips", "::", "K1_64", ",", "Mips", "::", "GP_64", ",", "Mips", "::", "SP_64", ",", "Mips", "::", "FP_64", ",", "Mips", "::", "RA_64", ",", "0", "}", ";", "BitVector", "Reserved", "(", "getNumRegs", "(", ")", ")", ";", "typedef", "TargetRegisterClass", "::", "iterator", "RegIter", ";", "for", "(", "const", "unsigned", "*", "Reg", "=", "ReservedCPURegs", ";", "*", "Reg", ";", "++", "Reg", ")", "Reserved", ".", "set", "(", "*", "Reg", ")", ";", "if", "(", "Subtarget", ".", "hasMips64", "(", ")", ")", "{", "for", "(", "const", "unsigned", "*", "Reg", "=", "ReservedCPU64Regs", ";", "*", "Reg", ";", "++", "Reg", ")", "Reserved", ".", "set", "(", "*", "Reg", ")", ";", "for", "(", "RegIter", "Reg", "=", "Mips", "::", "AFGR64RegisterClass", "->", "begin", "(", ")", ";", "Reg", "!=", "Mips", "::", "AFGR64RegisterClass", "->", "end", "(", ")", ";", "++", "Reg", ")", "Reserved", ".", "set", "(", "*", "Reg", ")", ";", "}", "else", "{", "for", "(", "RegIter", "Reg", "=", "Mips", "::", "CPU64RegsRegisterClass", "->", "begin", "(", ")", ";", "Reg", "!=", "Mips", "::", "CPU64RegsRegisterClass", "->", "end", "(", ")", ";", "++", "Reg", ")", "Reserved", ".", "set", "(", "*", "Reg", ")", ";", "for", "(", "RegIter", "Reg", "=", "Mips", "::", "FGR64RegisterClass", "->", "begin", "(", ")", ";", "Reg", "!=", "Mips", "::", "FGR64RegisterClass", "->", "end", "(", ")", ";", "++", "Reg", ")", "Reserved", ".", "set", "(", "*", "Reg", ")", ";", "}", "return", "Reserved", ";", "}", "</s>" ]
[ "getReservedRegs", "-", "Returns", "a", "bitset", "indexed", "by", "physical", "register", "number", "indicating", "if", "a", "register", "is", "a", "special", "register", "that", "has", "particular", "uses", "and", "should", "be", "considered", "unavailable", "at", "all", "times", ",", "e.g", "." ]
[ "Mips", "Mips", "Mips::ZERO", "Mips::AT", "Mips::K0", "Mips::K1", "Mips::GP", "Mips::SP", "Mips::FP", "Mips::RA", "0", "Mips::ZERO_64", "Mips::AT_64", "Mips::K0_64", "Mips::K1_64", "Mips::GP_64", "Mips::SP_64", "Mips::FP_64", "Mips::RA_64", "0", "Mips", "Mips::AFGR64RegisterClass", "Mips::AFGR64RegisterClass", "Mips::CPU64RegsRegisterClass", "Mips::CPU64RegsRegisterClass", "Mips::FGR64RegisterClass", "Mips::FGR64RegisterClass" ]
MipsRegisterInfo60
getReservedRegs
Mips
CPU
LLVM
99
277
1
[]

ComBack: A Versatile Dataset for Enhancing Compiler Backend Development Efficiency

ComBack is a large-scale multi-platform compiler backend code dataset. It is sourced from GCC and LLVM backends corresponding to 178 target platforms.

Dataset Information

  • Source Data

    • GCC
    Category Target Platform Function KLoC
    CPU 30 35,147 647.2
    MPU 33 6,010 183.9
    GPU 2 457 11.2
    VLIW 5 959 25.4
    DSP 3 399 9.6
    Virtual 4 327 6.5
    SUM 77 43,299 883.7
    • LLVM
    Category Target Platform Function KLoC
    CPU 43 84,914 3,450.4
    MPU 30 11,311 173.0
    GPU 5 22,591 768.3
    VLIW 4 2,048 24.3
    DSP 7 9,646 263.2
    Virtual 12 8,430 168.3
    SUM 101 138,940 4,847.5
  • Tasks

    • Statement-Level Completion: complete current statement.
    //Inputs:
    ...
    adjustReg(MBB,LastFrameDestroy, DL, SPReg, FPReg, -StackSize+RVFI->getVarArgsSaveSize() 
    //Ground Truth:
    MachineInstr::FrameDestroy);
    
    • Next-Statement Suggestion: predict the next statement.
    //Inputs:
    ...
    maxCallFrameSize = (maxCallFrameSize + AlignMask) & ~AlignMask;
    //Ground Truth:
    MFI -> setMaxCallFrameSize(maxCallFrameSize);
    
    • Code Generation: generate a function with function description in natrual language.
    //Inputs:
    getPointerRegClass: Returns a TargetRegisterClass used for pointer values.
    Target-Specific Value: Sparc, SP::I64RegsRegClass, SP::IntRegsRegClass.
    //Ground Truth:
    TargetRegisterClass *SparcRegisterInfo::getPointerRegClass(MachineFunction &MF ,unsigned Kind) {
       return Subtarget.is64Bit() ? &SP::I64RegsRegClass : &SP::IntRegsRegClass;
    }
    

Organization

  • Code_Generation/* and Code_Completion/*: split data of 178 backends into train/valid/test set in the ratio of 80%:10%:10%

    Task Train Valid Test
    Statement-Level Comp. 128,899(11.36M Token) 16,112(1.43M Token) 16,113(1.43M Token)
    Next-Statement Sugg. 173,052(15.69M Token) 21,631(1.99M Token) 21,632(1.98M Token)
    Code Generation. 36,236(5.10M Token) 4,530(0.64M Token) 4,530(0.64M Token)
  • New_Target_Generation/Existing_Types/* and New_Target_Completion/Existing_Types/*: Take data of RISC-V,ARC,NVPTX both in GCC and LLVM as test set, split train/valid set in the ratio of 85%:15% of other CPU, MPU and GPU targets excluding RI5CY(RI5CY is custmoized based on RISCV)

    Task Train Valid Test
    Statement-Level Comp. 114,016(10.20M Token) 20,121(1.81M Token) 6,645(0.58M Token)
    Next-Statement Sugg. 152,114(14.10M Token) 26,844(2.49M Token) 9,313(0.83M Token)
    Code Generation. 30,633(4.44M Token) 5,406(0.79M Token) 2,819(0.37M Token)
  • New_Target_Generation/New_Types/* and New_Target_Completion/New_Types/*: Take data of ARC,NVPTX both in GCC and LLVM as test set, split train/valid set in the ratio of 85%:15% of other CPU targets excluding RI5CY(RI5CY is custmoized based on RISCV)

    Task Train Valid Test
    Statement-Level Comp. 87,018(7.78M Token) 15,357(1.37M Token) 2,764(0.26M Token)
    Next-Statement Sugg. 113,684(10.65M Token) 20,063(1.87M Token) 4,029(0.38M Token)
    Code Generation. 21,184(3.14M Token) 3,739(0.55M Token) 1,372(0.18M Token)
  • Iterative_Expansion_Generation/* and Iterative_Expansion_Completion/*: Take data of RI5CY in LLVM as test set, split train/valid set in the ratio of 85%:15% of other CPU targets excluding RISC-V(a) and including RISC-V(b)

    (a)
    Task Train Valid Test
    Statement-Level Comp. 87,018(7.78M Token) 15,357(1.37M Token) 721(0.04M Token)
    Next-Statement Sugg. 113,684(10.65M Token) 20,063(1.87M Token) 1,035(0.06M Token)
    Code Generation. 21,184(3.14M Token) 3,739(0.55M Token) 219(0.02M Token)
    (b)
    Task Train Valid Test
    Statement-Level Comp. 90,316(8.06M Token) 15,940(1.42M Token) 721(0.04M Token)
    Next-Statement Sugg. 118,175(11.04M Token) 20,856(1.94M Token) 1,035(0.06M Token)
    Code Generation. 22,413(3.30M Token) 3,957(0.58M Token) 219(0.02M Token)
Downloads last month
0
Edit dataset card