Lines Matching refs:tabs
490 ArrayRef<SMLoc> loc, StringRef tabs, in emitAttributeSerialization() argument
493 os << tabs in emitAttributeSerialization()
497 os << tabs in emitAttributeSerialization()
503 os << tabs << " for (auto attrElem : attr.cast<ArrayAttr>()) {\n"; in emitAttributeSerialization()
504 os << tabs in emitAttributeSerialization()
508 os << tabs << " }\n"; in emitAttributeSerialization()
510 os << tabs in emitAttributeSerialization()
515 os << tabs in emitAttributeSerialization()
526 os << tabs << "}\n"; in emitAttributeSerialization()
534 StringRef tabs, StringRef opVar, in emitArgumentSerialization() argument
564 os << tabs in emitArgumentSerialization()
566 os << tabs << " auto id = getValueID(operand);\n"; in emitArgumentSerialization()
567 os << tabs << " assert(id && \"use before def!\");\n"; in emitArgumentSerialization()
568 os << tabs << formatv(" {0}.push_back(id);\n", operands); in emitArgumentSerialization()
569 os << tabs << "}\n"; in emitArgumentSerialization()
574 tabs, opVar, operands, attr.name, os); in emitArgumentSerialization()
575 os << tabs in emitArgumentSerialization()
585 os << tabs << "{\n"; in emitArgumentSerialization()
587 os << tabs in emitArgumentSerialization()
590 os << tabs << " auto argID = getValueID(arg);\n"; in emitArgumentSerialization()
591 os << tabs << " if (!argID) {\n"; in emitArgumentSerialization()
592 os << tabs in emitArgumentSerialization()
596 os << tabs << " }\n"; in emitArgumentSerialization()
597 os << tabs << formatv(" {0}.push_back(argID);\n", operands); in emitArgumentSerialization()
602 auto newtabs = tabs.str() + " "; in emitArgumentSerialization()
609 os << tabs << "}\n"; in emitArgumentSerialization()
617 StringRef tabs, StringRef opVar, in emitResultSerialization() argument
622 os << tabs << formatv("uint32_t {0} = 0;\n", resultTypeID); in emitResultSerialization()
623 os << tabs in emitResultSerialization()
627 os << tabs << " return failure();\n"; in emitResultSerialization()
628 os << tabs << "}\n"; in emitResultSerialization()
629 os << tabs << formatv("{0}.push_back({1});\n", operands, resultTypeID); in emitResultSerialization()
631 os << tabs << formatv("{0} = getNextID();\n", resultID); in emitResultSerialization()
632 os << tabs in emitResultSerialization()
634 os << tabs << formatv("{0}.push_back({1});\n", operands, resultID); in emitResultSerialization()
643 static void emitDecorationSerialization(const Operator &op, StringRef tabs, in emitDecorationSerialization() argument
648 os << tabs << formatv("for (auto attr : {0}.getAttrs()) {{\n", opVar); in emitDecorationSerialization()
649 os << tabs in emitDecorationSerialization()
652 os << tabs << " continue;\n"; in emitDecorationSerialization()
653 os << tabs << " }\n"; in emitDecorationSerialization()
654 os << tabs in emitDecorationSerialization()
658 os << tabs << " return failure();\n"; in emitDecorationSerialization()
659 os << tabs << " }\n"; in emitDecorationSerialization()
660 os << tabs << "}\n"; in emitDecorationSerialization()
723 static void emitSerializationDispatch(const Operator &op, StringRef tabs, in emitSerializationDispatch() argument
725 os << tabs in emitSerializationDispatch()
727 os << tabs in emitSerializationDispatch()
730 os << tabs << "}\n"; in emitSerializationDispatch()
746 ArrayRef<SMLoc> loc, StringRef tabs, in emitAttributeDeserialization() argument
752 os << tabs in emitAttributeDeserialization()
757 os << tabs << "SmallVector<Attribute, 4> attrListElems;\n"; in emitAttributeDeserialization()
758 os << tabs << formatv("while ({0} < {1}.size()) {{\n", wordIndex, words); in emitAttributeDeserialization()
759 os << tabs in emitAttributeDeserialization()
765 os << tabs << "}\n"; in emitAttributeDeserialization()
766 os << tabs in emitAttributeDeserialization()
771 os << tabs in emitAttributeDeserialization()
776 os << tabs in emitAttributeDeserialization()
794 StringRef tabs, StringRef words, in emitResultDeserialization() argument
800 os << tabs << "{\n"; in emitResultDeserialization()
801 os << tabs << formatv(" if ({0} >= {1}.size()) {{\n", wordIndex, words); in emitResultDeserialization()
802 os << tabs in emitResultDeserialization()
807 os << tabs << " }\n"; in emitResultDeserialization()
808 os << tabs << formatv(" auto ty = getType({0}[{1}]);\n", words, wordIndex); in emitResultDeserialization()
809 os << tabs << " if (!ty) {\n"; in emitResultDeserialization()
810 os << tabs in emitResultDeserialization()
815 os << tabs << " }\n"; in emitResultDeserialization()
816 os << tabs << formatv(" {0}.push_back(ty);\n", resultTypes); in emitResultDeserialization()
817 os << tabs << formatv(" {0}++;\n", wordIndex); in emitResultDeserialization()
818 os << tabs << formatv(" if ({0} >= {1}.size()) {{\n", wordIndex, words); in emitResultDeserialization()
819 os << tabs in emitResultDeserialization()
824 os << tabs << " }\n"; in emitResultDeserialization()
825 os << tabs << "}\n"; in emitResultDeserialization()
826 os << tabs << formatv("{0} = {1}[{2}++];\n", valueID, words, wordIndex); in emitResultDeserialization()
838 StringRef tabs, StringRef words, in emitOperandDeserialization() argument
852 os << tabs in emitOperandDeserialization()
855 os << tabs << formatv("if ({0} < {1}.size())", wordIndex, words); in emitOperandDeserialization()
858 os << tabs in emitOperandDeserialization()
860 os << tabs << " if (!arg) {\n"; in emitOperandDeserialization()
861 os << tabs in emitOperandDeserialization()
866 os << tabs << " }\n"; in emitOperandDeserialization()
867 os << tabs << formatv(" {0}.push_back(arg);\n", operands); in emitOperandDeserialization()
869 os << tabs << formatv(" {0}++;\n", wordIndex); in emitOperandDeserialization()
872 os << tabs << "}\n"; in emitOperandDeserialization()
874 os << tabs << formatv("if ({0} < {1}.size()) {{\n", wordIndex, words); in emitOperandDeserialization()
876 auto newtabs = tabs.str() + " "; in emitOperandDeserialization()
884 os << tabs << formatv("if ({0} != {1}.size()) {{\n", wordIndex, words); in emitOperandDeserialization()
885 os << tabs in emitOperandDeserialization()
891 os << tabs << "}\n\n"; in emitOperandDeserialization()
897 static void emitDecorationDeserialization(const Operator &op, StringRef tabs, in emitDecorationDeserialization() argument
903 os << tabs << formatv("if (decorations.count({0})) {{\n", valueID); in emitDecorationDeserialization()
904 os << tabs in emitDecorationDeserialization()
906 os << tabs in emitDecorationDeserialization()
908 os << tabs << "}\n"; in emitDecorationDeserialization()
978 StringRef tabs, StringRef words, in emitDeserializationDispatch() argument
980 os << tabs in emitDeserializationDispatch()
983 os << tabs in emitDeserializationDispatch()