8 from ..dialects._ods_common
import _cext
as _ods_cext
9 from ..ir
import ArrayAttr, Attribute, FlatSymbolRefAttr, OpView, StringAttr
10 from ._sv_ops_gen
import *
11 from ._sv_ops_gen
import _Dialect
14 @_ods_cext.register_operation(_Dialect, replace=True)
17 def __init__(self, cond: Attribute, *, loc=
None, ip=
None):
20 attributes = {
"cond": cond}
23 self.build_generic(attributes=attributes,
30 self.regions[0].blocks.append()
31 self.regions[1].blocks.append()
34 @_ods_cext.register_operation(_Dialect, replace=True)
45 attributes = {
"name": StringAttr.get(name)}
46 if sym_name
is not None:
47 attributes[
"inner_sym"] = hw.InnerSymAttr.get(StringAttr.get(sym_name))
48 if svAttributes
is not None:
49 attributes[
"svAttributes"] = ArrayAttr.get(svAttributes)
52 self.build_generic(attributes=attributes,
61 def create(data_type, name=None, sym_name=None):
62 if not isinstance(data_type, hw.InOutType):
63 data_type = hw.InOutType.get(data_type)
64 return sv.WireOp(data_type, name, sym_name=sym_name)
67 @_ods_cext.register_operation(_Dialect, replace=True)
78 attributes = {
"name": StringAttr.get(name)}
79 if sym_name
is not None:
80 attributes[
"inner_sym"] = hw.InnerSymAttr.get(StringAttr.get(sym_name))
81 if svAttributes
is not None:
82 attributes[
"svAttributes"] = ArrayAttr.get(svAttributes)
85 self.build_generic(attributes=attributes,
94 @_ods_cext.register_operation(_Dialect, replace=True)
102 @_ods_cext.register_operation(_Dialect, replace=True)
107 value = support.get_value(value)
108 type = support.get_self_or_inner(value.type).element_type
def __init__(self, Attribute cond, *loc=None, ip=None)
def __init__(self, data_type, name, *sym_name=None, svAttributes=None, loc=None, ip=None)
def create(data_type, name=None, sym_name=None)
def __init__(self, data_type, name, *sym_name=None, svAttributes=None, loc=None, ip=None)