Lines Matching refs:py
25 namespace py = pybind11;
154 py::object classmethod(Func f, Args... args) { in classmethod()
155 py::object cf = py::cpp_function(f, args...); in classmethod()
156 return py::reinterpret_borrow<py::object>((PyClassMethod_New(cf.ptr()))); in classmethod()
159 static py::object
161 py::object dialectDescriptor) { in createCustomDialectWrapper()
165 return py::cast(PyDialect(std::move(dialectDescriptor))); in createCustomDialectWrapper()
178 static void set(py::object &o, bool enable) { mlirEnableGlobalDebug(enable); } in set()
180 static bool get(const py::object &) { return mlirIsGlobalDebugEnabled(); } in get()
182 static void bind(py::module &m) { in bind()
184 py::class_<PyGlobalDebugFlag>(m, "_GlobalDebug", py::module_local()) in bind()
206 throw py::stop_iteration(); in dunderNext()
212 static void bind(py::module &m) { in bind()
213 py::class_<PyRegionIterator>(m, "RegionIterator", py::module_local()) in bind()
244 static void bind(py::module &m) { in bind()
245 py::class_<PyRegionList>(m, "RegionSequence", py::module_local()) in bind()
264 throw py::stop_iteration(); in dunderNext()
272 static void bind(py::module &m) { in bind()
273 py::class_<PyBlockIterator>(m, "BlockIterator", py::module_local()) in bind()
324 PyBlock appendBlock(const py::args &pyArgTypes) { in appendBlock()
343 static void bind(py::module &m) { in bind()
344 py::class_<PyBlockList>(m, "BlockList", py::module_local()) in bind()
363 py::object dunderNext() { in dunderNext()
366 throw py::stop_iteration(); in dunderNext()
375 static void bind(py::module &m) { in bind()
376 py::class_<PyOperationIterator>(m, "OperationIterator", py::module_local()) in bind()
412 py::object dunderGetItem(intptr_t index) { in dunderGetItem()
431 static void bind(py::module &m) { in bind()
432 py::class_<PyOperationList>(m, "OperationList", py::module_local()) in bind()
450 py::gil_scoped_acquire acquire; in PyMlirContext()
459 py::gil_scoped_acquire acquire; in ~PyMlirContext()
464 py::object PyMlirContext::getCapsule() { in getCapsule()
465 return py::reinterpret_steal<py::object>(mlirPythonContextToCapsule(get())); in getCapsule()
468 py::object PyMlirContext::createFromCapsule(py::object capsule) { in createFromCapsule()
471 throw py::error_already_set(); in createFromCapsule()
481 py::gil_scoped_acquire acquire; in forContext()
487 py::object pyRef = py::cast(unownedContextWrapper); in forContext()
493 py::object pyRef = py::cast(it->second); in forContext()
526 py::object PyMlirContext::attachDiagnosticHandler(py::object callback) { in attachDiagnosticHandler()
531 py::object pyHandlerObject = in attachDiagnosticHandler()
532 py::cast(pyHandler, py::return_value_policy::take_ownership); in attachDiagnosticHandler()
540 py::object pyDiagnosticObject = in attachDiagnosticHandler()
541 py::cast(pyDiagnostic, py::return_value_policy::take_ownership); in attachDiagnosticHandler()
548 py::gil_scoped_acquire gil; in attachDiagnosticHandler()
550 result = py::cast<bool>(pyHandler->callback(pyDiagnostic)); in attachDiagnosticHandler()
567 py::object pyHandlerObject = in attachDiagnosticHandler()
568 py::cast(pyHandler, py::return_value_policy::reference); in attachDiagnosticHandler()
605 void PyThreadContextEntry::push(FrameKind frameKind, py::object context, in push()
606 py::object insertionPoint, in push()
607 py::object location) { in push()
630 return py::cast<PyMlirContext *>(context); in getContext()
636 return py::cast<PyInsertionPoint *>(insertionPoint); in getInsertionPoint()
642 return py::cast<PyLocation *>(location); in getLocation()
660 py::object PyThreadContextEntry::pushContext(PyMlirContext &context) { in pushContext()
661 py::object contextObj = py::cast(context); in pushContext()
663 /*insertionPoint=*/py::object(), in pushContext()
664 /*location=*/py::object()); in pushContext()
678 py::object
680 py::object contextObj = in pushInsertionPoint()
682 py::object insertionPointObj = py::cast(insertionPoint); in pushInsertionPoint()
686 /*location=*/py::object()); in pushInsertionPoint()
703 py::object PyThreadContextEntry::pushLocation(PyLocation &location) { in pushLocation()
704 py::object contextObj = location.getContext().getObject(); in pushLocation()
705 py::object locationObj = py::cast(location); in pushLocation()
707 /*insertionPoint=*/py::object(), in pushLocation()
730 PyDiagnostic *note = py::cast<PyDiagnostic *>(noteObject); in invalidate()
737 py::object callback) in PyDiagnosticHandler()
772 py::str PyDiagnostic::getMessage() { in getMessage()
774 py::object fileObject = py::module::import("io").attr("StringIO")(); in getMessage()
780 py::tuple PyDiagnostic::getNotes() { in getNotes()
785 materializedNotes = py::tuple(numNotes); in getNotes()
808 py::object PyDialectRegistry::getCapsule() { in getCapsule()
809 return py::reinterpret_steal<py::object>( in getCapsule()
813 PyDialectRegistry PyDialectRegistry::createFromCapsule(py::object capsule) { in createFromCapsule()
817 throw py::error_already_set(); in createFromCapsule()
825 py::object PyLocation::getCapsule() { in getCapsule()
826 return py::reinterpret_steal<py::object>(mlirPythonLocationToCapsule(*this)); in getCapsule()
829 PyLocation PyLocation::createFromCapsule(py::object capsule) { in createFromCapsule()
832 throw py::error_already_set(); in createFromCapsule()
837 py::object PyLocation::contextEnter() { in contextEnter()
867 py::gil_scoped_acquire acquire; in ~PyModule()
879 py::gil_scoped_acquire acquire; in forModule()
888 py::object pyRef = in forModule()
889 py::cast(unownedModule, py::return_value_policy::take_ownership); in forModule()
897 py::object pyRef = py::reinterpret_borrow<py::object>(it->second.first); in forModule()
901 py::object PyModule::createFromCapsule(py::object capsule) { in createFromCapsule()
904 throw py::error_already_set(); in createFromCapsule()
908 py::object PyModule::getCapsule() { in getCapsule()
909 return py::reinterpret_steal<py::object>(mlirPythonModuleToCapsule(get())); in getCapsule()
934 py::object parentKeepAlive) { in createInstance()
942 py::object pyRef = in createInstance()
943 py::cast(unownedOperation, py::return_value_policy::take_ownership); in createInstance()
954 py::object parentKeepAlive) { in forOperation()
964 py::object pyRef = py::reinterpret_borrow<py::object>(it->second.first); in forOperation()
970 py::object parentKeepAlive) { in createDetached()
988 void PyOperationBase::print(py::object fileObject, bool binary, in print()
996 fileObject = py::module::import("sys").attr("stdout"); in print()
1002 fileObject.attr("write")(py::bytes(message)); in print()
1004 fileObject.attr("write")(py::str(message)); in print()
1025 py::object PyOperationBase::getAsm(bool binary, in getAsm()
1030 py::object fileObject; in getAsm()
1032 fileObject = py::module::import("io").attr("BytesIO")(); in getAsm()
1034 fileObject = py::module::import("io").attr("StringIO")(); in getAsm()
1084 py::object PyOperation::getCapsule() { in getCapsule()
1086 return py::reinterpret_steal<py::object>(mlirPythonOperationToCapsule(get())); in getCapsule()
1089 py::object PyOperation::createFromCapsule(py::object capsule) { in createFromCapsule()
1092 throw py::error_already_set(); in createFromCapsule()
1099 const py::object &maybeIp) { in maybeInsertOperation()
1101 if (!maybeIp.is(py::cast(false))) { in maybeInsertOperation()
1106 ip = py::cast<PyInsertionPoint *>(maybeIp); in maybeInsertOperation()
1113 py::object PyOperation::create( in create()
1116 llvm::Optional<py::dict> attributes, in create()
1118 DefaultingPyLocation location, const py::object &maybeIp) { in create()
1155 } catch (py::cast_error &err) { in create()
1159 throw py::cast_error(msg); in create()
1165 } catch (py::reference_cast_error &) { in create()
1170 throw py::cast_error(msg); in create()
1171 } catch (py::cast_error &err) { in create()
1175 throw py::cast_error(msg); in create()
1235 py::object PyOperation::clone(const py::object &maybeIp) { in clone()
1244 py::object PyOperation::createOpView() { in createOpView()
1252 return py::cast(PyOpView(getRef().getObject())); in createOpView()
1271 py::object PyOpView::buildGeneric( in buildGeneric()
1272 const py::object &cls, py::list resultTypeList, py::list operandList, in buildGeneric()
1273 llvm::Optional<py::dict> attributes, in buildGeneric()
1276 const py::object &maybeIp) { in buildGeneric()
1279 std::string name = py::cast<std::string>(cls.attr("OPERATION_NAME")); in buildGeneric()
1285 py::object operandSegmentSpecObj = cls.attr("_ODS_OPERAND_SEGMENTS"); in buildGeneric()
1286 py::object resultSegmentSpecObj = cls.attr("_ODS_RESULT_SEGMENTS"); in buildGeneric()
1292 auto opRegionSpec = py::cast<std::tuple<int, bool>>(cls.attr("_ODS_REGIONS")); in buildGeneric()
1299 throw py::value_error( in buildGeneric()
1306 throw py::value_error( in buildGeneric()
1320 resultTypes.push_back(py::cast<PyType *>(it.value())); in buildGeneric()
1322 throw py::cast_error(); in buildGeneric()
1323 } catch (py::cast_error &err) { in buildGeneric()
1324 throw py::value_error((llvm::Twine("Result ") + in buildGeneric()
1332 auto resultSegmentSpec = py::cast<std::vector<int>>(resultSegmentSpecObj); in buildGeneric()
1334 throw py::value_error((llvm::Twine("Operation \"") + name + in buildGeneric()
1348 auto *resultType = py::cast<PyType *>(std::get<0>(it.value())); in buildGeneric()
1356 throw py::cast_error("was None and result is not optional"); in buildGeneric()
1358 } catch (py::cast_error &err) { in buildGeneric()
1359 throw py::value_error((llvm::Twine("Result ") + in buildGeneric()
1373 auto segment = py::cast<py::sequence>(std::get<0>(it.value())); in buildGeneric()
1374 for (py::object segmentItem : segment) { in buildGeneric()
1375 resultTypes.push_back(py::cast<PyType *>(segmentItem)); in buildGeneric()
1377 throw py::cast_error("contained a None item"); in buildGeneric()
1386 throw py::value_error((llvm::Twine("Result ") + in buildGeneric()
1393 throw py::value_error("Unexpected segment spec"); in buildGeneric()
1405 operands.push_back(py::cast<PyValue *>(it.value())); in buildGeneric()
1407 throw py::cast_error(); in buildGeneric()
1408 } catch (py::cast_error &err) { in buildGeneric()
1409 throw py::value_error((llvm::Twine("Operand ") + in buildGeneric()
1417 auto operandSegmentSpec = py::cast<std::vector<int>>(operandSegmentSpecObj); in buildGeneric()
1419 throw py::value_error((llvm::Twine("Operation \"") + name + in buildGeneric()
1433 auto *operandValue = py::cast<PyValue *>(std::get<0>(it.value())); in buildGeneric()
1441 throw py::cast_error("was None and operand is not optional"); in buildGeneric()
1443 } catch (py::cast_error &err) { in buildGeneric()
1444 throw py::value_error((llvm::Twine("Operand ") + in buildGeneric()
1458 auto segment = py::cast<py::sequence>(std::get<0>(it.value())); in buildGeneric()
1459 for (py::object segmentItem : segment) { in buildGeneric()
1460 operands.push_back(py::cast<PyValue *>(segmentItem)); in buildGeneric()
1462 throw py::cast_error("contained a None item"); in buildGeneric()
1471 throw py::value_error((llvm::Twine("Operand ") + in buildGeneric()
1478 throw py::value_error("Unexpected segment spec"); in buildGeneric()
1487 attributes = py::dict(*attributes); in buildGeneric()
1489 attributes = py::dict(); in buildGeneric()
1493 throw py::value_error("Manually setting a 'result_segment_sizes' or " in buildGeneric()
1528 PyOpView::PyOpView(const py::object &operationObject) in PyOpView()
1531 : operation(py::cast<PyOperationBase &>(operationObject).getOperation()), in PyOpView()
1534 py::object PyOpView::createRawSubclass(const py::object &userClass) { in createRawSubclass()
1556 py::object parentMetaclass = in createRawSubclass()
1557 py::reinterpret_borrow<py::object>((PyObject *)&PyType_Type); in createRawSubclass()
1558 py::dict attributes; in createRawSubclass()
1562 auto opViewType = py::detail::get_type_handle(typeid(PyOpView), true); in createRawSubclass()
1564 py::str origName = userClass.attr("__name__"); in createRawSubclass()
1565 py::str newName = py::str("_") + origName; in createRawSubclass()
1566 return parentMetaclass(newName, py::make_tuple(userClass), attributes); in createRawSubclass()
1595 throw py::index_error("Cannot insert operation at the end of a block " in insert()
1627 py::object PyInsertionPoint::contextEnter() { in contextEnter()
1645 py::object PyAttribute::getCapsule() { in getCapsule()
1646 return py::reinterpret_steal<py::object>(mlirPythonAttributeToCapsule(*this)); in getCapsule()
1649 PyAttribute PyAttribute::createFromCapsule(py::object capsule) { in createFromCapsule()
1652 throw py::error_already_set(); in createFromCapsule()
1677 py::object PyType::getCapsule() { in getCapsule()
1678 return py::reinterpret_steal<py::object>(mlirPythonTypeToCapsule(*this)); in getCapsule()
1681 PyType PyType::createFromCapsule(py::object capsule) { in createFromCapsule()
1684 throw py::error_already_set(); in createFromCapsule()
1694 return py::reinterpret_steal<py::object>(mlirPythonValueToCapsule(get())); in getCapsule()
1700 throw py::error_already_set(); in createFromCapsule()
1707 throw py::error_already_set(); in createFromCapsule()
1722 throw py::cast_error("Operation is not a Symbol Table."); in PySymbolTable()
1726 py::object PySymbolTable::dunderGetItem(const std::string &name) { in dunderGetItem()
1731 throw py::key_error("Symbol '" + name + "' not in the symbol table."); in dunderGetItem()
1749 py::object operation = dunderGetItem(name); in dunderDel()
1750 erase(py::cast<PyOperationBase &>(operation)); in dunderDel()
1759 throw py::value_error("Expected operation to have a symbol name."); in insert()
1773 throw py::value_error("Expected operation to have a symbol name."); in getSymbolName()
1786 throw py::value_error("Expected operation to have a symbol name."); in setSymbolName()
1799 throw py::value_error("Expected operation to have a symbol visibility."); in getVisibility()
1807 throw py::value_error( in setVisibility()
1815 throw py::value_error("Expected operation to have a symbol visibility."); in setVisibility()
1830 throw py::value_error("Symbol rename failed"); in replaceAllSymbolUses()
1835 py::object callback) { in walkSymbolTables()
1840 py::object callback; in walkSymbolTables()
1843 py::object exceptionType; in walkSymbolTables()
1857 } catch (py::error_already_set &e) { in walkSymbolTables()
1882 using ClassTy = py::class_<DerivedTy, PyValue>;
1895 auto origRepr = py::repr(py::cast(orig)).cast<std::string>(); in castFrom()
1904 static void bind(py::module &m) { in bind()
1905 auto cls = ClassTy(m, DerivedTy::pyClassName, py::module_local()); in bind()
1906 cls.def(py::init<PyValue &>(), py::keep_alive<0, 1>(), py::arg("value")); in bind()
1912 py::arg("other_value")); in bind()
1940 py::arg("type")); in bindDerived()
2177 static void bind(py::module &m) { in bind()
2178 py::class_<PyOpAttributeMap>(m, "OpAttributeMap", py::module_local()) in bind()
2197 void mlir::python::populateIRCore(py::module &m) { in populateIRCore()
2201 py::enum_<MlirDiagnosticSeverity>(m, "DiagnosticSeverity", py::module_local()) in populateIRCore()
2210 py::class_<PyDiagnostic>(m, "Diagnostic", py::module_local()) in populateIRCore()
2215 .def("__str__", [](PyDiagnostic &self) -> py::str { in populateIRCore()
2221 py::class_<PyDiagnosticHandler>(m, "DiagnosticHandler", py::module_local()) in populateIRCore()
2234 py::class_<PyMlirContext>(m, "_BaseContext", py::module_local()) in populateIRCore()
2235 .def(py::init<>(&PyMlirContext::createNewContextForInit)) in populateIRCore()
2252 [](py::object & /*class*/) { in populateIRCore()
2277 py::arg("dialect_name"), in populateIRCore()
2288 py::arg("callback"), in populateIRCore()
2295 py::arg("enable")) in populateIRCore()
2302 py::arg("operation_name")) in populateIRCore()
2308 py::arg("registry")) in populateIRCore()
2316 py::class_<PyDialectDescriptor>(m, "DialectDescriptor", py::module_local()) in populateIRCore()
2321 return py::str(ns.data, ns.length); in populateIRCore()
2334 py::class_<PyDialects>(m, "Dialects", py::module_local()) in populateIRCore()
2339 py::object descriptor = in populateIRCore()
2340 py::cast(PyDialectDescriptor{self.getContext(), dialect}); in populateIRCore()
2346 py::object descriptor = in populateIRCore()
2347 py::cast(PyDialectDescriptor{self.getContext(), dialect}); in populateIRCore()
2354 py::class_<PyDialect>(m, "Dialect", py::module_local()) in populateIRCore()
2355 .def(py::init<py::object>(), py::arg("descriptor")) in populateIRCore()
2358 .def("__repr__", [](py::object self) { in populateIRCore()
2360 return py::str("<Dialect ") + in populateIRCore()
2361 self.attr("descriptor").attr("namespace") + py::str(" (class ") + in populateIRCore()
2362 clazz.attr("__module__") + py::str(".") + in populateIRCore()
2363 clazz.attr("__name__") + py::str(")>"); in populateIRCore()
2369 py::class_<PyDialectRegistry>(m, "DialectRegistry", py::module_local()) in populateIRCore()
2373 .def(py::init<>()); in populateIRCore()
2378 py::class_<PyLocation>(m, "Location", py::module_local()) in populateIRCore()
2387 .def("__eq__", [](PyLocation &self, py::object other) { return false; }) in populateIRCore()
2390 [](py::object & /*class*/) { in populateIRCore()
2403 py::arg("context") = py::none(), in populateIRCore()
2410 throw py::value_error("No caller frames provided"); in populateIRCore()
2418 py::arg("callee"), py::arg("frames"), py::arg("context") = py::none(), in populateIRCore()
2429 py::arg("filename"), py::arg("line"), py::arg("col"), in populateIRCore()
2430 py::arg("context") = py::none(), kContextGetFileLocationDocstring) in populateIRCore()
2445 py::arg("locations"), py::arg("metadata") = py::none(), in populateIRCore()
2446 py::arg("context") = py::none(), kContextGetFusedLocationDocstring) in populateIRCore()
2458 py::arg("name"), py::arg("childLoc") = py::none(), in populateIRCore()
2459 py::arg("context") = py::none(), kContextGetNameLocationDocString) in populateIRCore()
2469 py::arg("message"), "Emits an error at this location") in populateIRCore()
2480 py::class_<PyModule>(m, "Module", py::module_local()) in populateIRCore()
2497 py::arg("asm"), py::arg("context") = py::none(), in populateIRCore()
2505 py::arg("loc") = py::none(), "Creates an empty module") in populateIRCore()
2537 [](py::object self) { in populateIRCore()
2546 py::class_<PyOperationBase>(m, "_OperationBase", py::module_local()) in populateIRCore()
2556 [](PyOperationBase &self, py::object other) { return false; }) in populateIRCore()
2625 py::arg("file") = py::none(), py::arg("binary") = false, in populateIRCore()
2626 py::arg("large_elements_limit") = py::none(), in populateIRCore()
2627 py::arg("enable_debug_info") = false, in populateIRCore()
2628 py::arg("pretty_debug_info") = false, in populateIRCore()
2629 py::arg("print_generic_op_form") = false, in populateIRCore()
2630 py::arg("use_local_scope") = false, in populateIRCore()
2631 py::arg("assume_verified") = false, kOperationPrintDocstring) in populateIRCore()
2634 py::arg("binary") = false, in populateIRCore()
2635 py::arg("large_elements_limit") = py::none(), in populateIRCore()
2636 py::arg("enable_debug_info") = false, in populateIRCore()
2637 py::arg("pretty_debug_info") = false, in populateIRCore()
2638 py::arg("print_generic_op_form") = false, in populateIRCore()
2639 py::arg("use_local_scope") = false, in populateIRCore()
2640 py::arg("assume_verified") = false, kOperationGetAsmDocstring) in populateIRCore()
2648 .def("move_after", &PyOperationBase::moveAfter, py::arg("other"), in populateIRCore()
2651 .def("move_before", &PyOperationBase::moveBefore, py::arg("other"), in populateIRCore()
2660 throw py::value_error("Detached operation has no parent."); in populateIRCore()
2667 py::class_<PyOperation, PyOperationBase>(m, "Operation", py::module_local()) in populateIRCore()
2668 .def_static("create", &PyOperation::create, py::arg("name"), in populateIRCore()
2669 py::arg("results") = py::none(), in populateIRCore()
2670 py::arg("operands") = py::none(), in populateIRCore()
2671 py::arg("attributes") = py::none(), in populateIRCore()
2672 py::arg("successors") = py::none(), py::arg("regions") = 0, in populateIRCore()
2673 py::arg("loc") = py::none(), py::arg("ip") = py::none(), in populateIRCore()
2676 [](PyOperation &self) -> py::object { in populateIRCore()
2680 return py::none(); in populateIRCore()
2683 .def("clone", &PyOperation::clone, py::arg("ip") = py::none()) in populateIRCore()
2693 return py::str(name.data, name.length); in populateIRCore()
2705 py::class_<PyOpView, PyOperationBase>(m, "OpView", py::module_local()) in populateIRCore()
2706 .def(py::init<py::object>(), py::arg("operation")) in populateIRCore()
2715 return py::str(self.getOperationObject()); in populateIRCore()
2717 opViewClass.attr("_ODS_REGIONS") = py::make_tuple(0, true); in populateIRCore()
2718 opViewClass.attr("_ODS_OPERAND_SEGMENTS") = py::none(); in populateIRCore()
2719 opViewClass.attr("_ODS_RESULT_SEGMENTS") = py::none(); in populateIRCore()
2721 &PyOpView::buildGeneric, py::arg("cls"), py::arg("results") = py::none(), in populateIRCore()
2722 py::arg("operands") = py::none(), py::arg("attributes") = py::none(), in populateIRCore()
2723 py::arg("successors") = py::none(), py::arg("regions") = py::none(), in populateIRCore()
2724 py::arg("loc") = py::none(), py::arg("ip") = py::none(), in populateIRCore()
2730 py::class_<PyRegion>(m, "Region", py::module_local()) in populateIRCore()
2755 .def("__eq__", [](PyRegion &self, py::object &other) { return false; }); in populateIRCore()
2760 py::class_<PyBlock>(m, "Block", py::module_local()) in populateIRCore()
2788 [](PyRegion &parent, py::list pyArgTypes) { in populateIRCore()
2806 py::arg("parent"), py::arg("arg_types") = py::list(), in populateIRCore()
2820 [](PyBlock &self, py::args pyArgTypes) { in populateIRCore()
2843 [](PyBlock &self, py::args pyArgTypes) { in populateIRCore()
2878 .def("__eq__", [](PyBlock &self, py::object &other) { return false; }) in populateIRCore()
2900 py::arg("operation"), in populateIRCore()
2908 py::class_<PyInsertionPoint>(m, "InsertionPoint", py::module_local()) in populateIRCore()
2909 .def(py::init<PyBlock &>(), py::arg("block"), in populateIRCore()
2915 [](py::object & /*class*/) { in populateIRCore()
2923 .def(py::init<PyOperationBase &>(), py::arg("beforeOperation"), in populateIRCore()
2926 py::arg("block"), "Inserts at the beginning of the block.") in populateIRCore()
2928 py::arg("block"), "Inserts before the block terminator.") in populateIRCore()
2929 .def("insert", &PyInsertionPoint::insert, py::arg("operation"), in populateIRCore()
2938 py::class_<PyAttribute>(m, "Attribute", py::module_local()) in populateIRCore()
2941 .def(py::init<PyAttribute &>(), py::arg("cast_from_type"), in populateIRCore()
2960 py::arg("asm"), py::arg("context") = py::none(), in populateIRCore()
2976 py::keep_alive<0, 1>(), "Binds a name to the attribute") in populateIRCore()
2979 .def("__eq__", [](PyAttribute &self, py::object &other) { return false; }) in populateIRCore()
3013 py::class_<PyNamedAttribute>(m, "NamedAttribute", py::module_local()) in populateIRCore()
3019 py::str(mlirIdentifierStr(self.namedAttr.name).data, in populateIRCore()
3031 return py::str(mlirIdentifierStr(self.namedAttr.name).data, in populateIRCore()
3044 py::keep_alive<0, 1>(), in populateIRCore()
3050 py::class_<PyType>(m, "Type", py::module_local()) in populateIRCore()
3053 .def(py::init<PyType &>(), py::arg("cast_from_type"), in populateIRCore()
3071 py::arg("asm"), py::arg("context") = py::none(), in populateIRCore()
3077 .def("__eq__", [](PyType &self, py::object &other) { return false; }) in populateIRCore()
3108 py::class_<PyValue>(m, "Value", py::module_local()) in populateIRCore()
3131 .def("__eq__", [](PyValue &self, py::object other) { return false; }) in populateIRCore()
3157 py::class_<PySymbolTable>(m, "SymbolTable", py::module_local()) in populateIRCore()
3158 .def(py::init<PyOperationBase &>()) in populateIRCore()
3160 .def("insert", &PySymbolTable::insert, py::arg("operation")) in populateIRCore()
3161 .def("erase", &PySymbolTable::erase, py::arg("operation")) in populateIRCore()
3170 py::arg("symbol"), py::arg("name")) in populateIRCore()
3172 py::arg("symbol")) in populateIRCore()
3174 py::arg("symbol")) in populateIRCore()
3176 py::arg("symbol"), py::arg("visibility")) in populateIRCore()
3178 &PySymbolTable::replaceAllSymbolUses, py::arg("old_symbol"), in populateIRCore()
3179 py::arg("new_symbol"), py::arg("from_op")) in populateIRCore()
3181 py::arg("from_op"), py::arg("all_sym_uses_visible"), in populateIRCore()
3182 py::arg("callback")); in populateIRCore()