Lines Matching defs:Def
222 // Clone the def and add it to the current multiclass
225 // Add all of the values in the superclass into the current def.
265 Record *Def = *j;
267 if (SetValue(Def, SubMultiClass.RefLoc, SMCTArgs[i],
273 Def->resolveReferencesTo(Def->getValue(SMCTArgs[i]));
276 Def->removeValue(SMCTArgs[i]);
295 return K == tgtok::Class || K == tgtok::Def ||
630 /// IDValue ::= ID [def local value]
631 /// IDValue ::= ID [def template arg]
634 /// IDValue ::= ID [def name]
1457 /// including within a def or in the template args for a def (which which case
1460 /// also happen within a def that is within a multiclass, which will set both
1512 /// template args for a def, which may or may not be in a multiclass. If null,
1547 /// ParseBodyItem - Parse a single item at within the body of a def or class.
1595 /// ParseBody - Read the body of a class or def. Return true on error, false on
1623 /// ParseObjectBody - Parse the body of a def or class. This consists of an
1624 /// optional ClassList followed by a Body. CurRec is the current def or class
1663 /// ParseDef - Parse and return a top level or multiclass def, return the record
1666 /// DefInst ::= DEF ObjectName ObjectBody
1670 assert(Lex.getCode() == tgtok::Def && "Unknown tok");
1671 Lex.Lex(); // Eat the 'def' token.
1677 // Top-level def definition.
1681 Error(DefLoc, "def '" + CurRec->getName() + "' already defined");
1686 // Otherwise, a def inside a multiclass, add it to the multiclass.
1689 Error(DefLoc, "def '" + CurRec->getName() +
1699 if (CurMultiClass == 0) // Def's in multiclasses aren't really defs.
1701 // for the def that might have been created when resolving
1709 // Copy the template arguments for the multiclass into the def.
1903 return TokError("multiclass must contain at least one def");
1908 return TokError("expected 'let', 'def' or 'defm' in multiclass body");
1910 case tgtok::Def:
1930 // instantiated def a unique name. Otherwise, if "#NAME#" exists in the
1993 // If the mdef is inside a 'let' expression, add to each def.
2002 return Error(DefmPrefixLoc, "def '" + CurRec->getName() +
2017 // Copy the template arguments for the multiclass into the new def.
2066 // instantiate each def contained in the multiclass with the SubClassRef
2078 // Loop over all the def's in the multiclass, instantiating each one.
2086 return Error(SubClassLoc, "could not instantiate def");
2089 return Error(SubClassLoc, "could not instantiate def");
2112 // regular 'def' and inherit all record values.
2144 // name for the def that might have been created when resolving
2165 return TokError("Expected class, def, defm, multiclass or let definition");
2167 case tgtok::Def: return ParseDef(MC);