Home
last modified time | relevance | path

Searched refs:StringAttr (Results 1 – 25 of 216) sorted by relevance

123456789

/external/tensorflow/tensorflow/core/ir/
Dtf_op_names.inc197 StringAttr add_;
198 StringAttr add_n_;
199 StringAttr add_v2_;
200 StringAttr all_;
201 StringAttr angle_;
202 StringAttr any_;
203 StringAttr approximate_equal_;
204 StringAttr arg_;
205 StringAttr arg_max_;
206 StringAttr arg_min_;
[all …]
Dtf_op_names.cc25 StringAttr op_name = op->getName().getIdentifier(); in IsAdd()
28 if (op_name == add_) return !op->getAttrOfType<StringAttr>("T"); in IsAdd()
33 StringAttr op_name = op->getName().getIdentifier(); in IsAddN()
38 StringAttr op_name = op->getName().getIdentifier(); in IsAll()
43 StringAttr op_name = op->getName().getIdentifier(); in IsAngle()
48 StringAttr op_name = op->getName().getIdentifier(); in IsAny()
53 StringAttr op_name = op->getName().getIdentifier(); in IsAnyDiv()
59 StringAttr op_name = op->getName().getIdentifier(); in IsAnyBatchMatMul()
64 StringAttr op_name = op->getName().getIdentifier(); in IsAnyMatMul()
70 StringAttr op_name = op->getName().getIdentifier(); in IsAnyMax()
[all …]
Dtf_op_wrapper.cc28 StringAttr TFOp::nameAttr() { in nameAttr()
29 return op_->getAttrOfType<StringAttr>(getDialect()->getNameAttrIdentifier()); in nameAttr()
35 setName(StringAttr::get(op_->getContext(), name.str())); in setName()
38 void TFOp::setName(StringAttr name) { in setName()
42 StringAttr TFOp::requestedDeviceAttr() { in requestedDeviceAttr()
43 return op_->getAttrOfType<StringAttr>( in requestedDeviceAttr()
50 setRequestedDevice(StringAttr::get(op_->getContext(), device.str())); in setRequestedDevice()
53 void TFOp::setRequestedDevice(StringAttr device) { in setRequestedDevice()
57 StringAttr TFOp::assignedDeviceAttr() { in assignedDeviceAttr()
58 return op_->getAttrOfType<StringAttr>( in assignedDeviceAttr()
[all …]
Ddialect.td72 StringAttr getNameAttrIdentifier() const { return name_key_; }
75 StringAttr getDeviceAttrIdentifier() const { return device_key_; }
80 StringAttr getAssignedDeviceAttrIdentifier() const {
87 StringAttr getFullTypeAttrIdentifier() const { return fulltype_key_; }
92 StringAttr getTfgNameAttrIdentifier() const { return tfg_name_key_; }
95 StringAttr getTfgDescriptionAttrIdentifier() const {
102 StringAttr getTfgIsRefAttrIdentifier() const { return tfg_is_ref_key_; }
105 StringAttr getTfgHandleDataAttrIdentifier() const {
112 StringAttr getTfgFullTypeAttrIdentifier() const {
119 StringAttr getLiftedGraphFuncNameAttrIdentifier() const {
[all …]
Dtf_op_wrapper.h95 StringAttr nameAttr();
99 void setName(StringAttr name);
103 StringAttr requestedDeviceAttr();
107 void setRequestedDevice(StringAttr requested_device);
110 StringAttr assignedDeviceAttr();
114 void setAssignedDevice(StringAttr assigned_device);
117 StringAttr tpuReplicate();
119 void setTpuReplicate(StringAttr tpu_replicate);
123 StringAttr deviceAttr() { in deviceAttr()
124 StringAttr device = assignedDeviceAttr(); in deviceAttr()
[all …]
/external/tensorflow/tensorflow/core/ir/importexport/
Dfunctiondef_export.cc66 StringAttr arg_name = arg_attrs.getAs<StringAttr>("tfg.name"); in GetValueName()
87 producer->getAttrOfType<StringAttr>(TFGraphDialect::getNameAttrKey()); in GetValueName()
107 StringAttr arg_name = arg_attrs.getAs<StringAttr>("tfg.name"); in ExportArgDef()
110 StringAttr description = arg_attrs.getAs<StringAttr>("tfg.description"); in ExportArgDef()
118 if (StringAttr type_attr = arg_attrs.getAs<StringAttr>("tfg.type_attr")) in ExportArgDef()
120 if (StringAttr number_attr = arg_attrs.getAs<StringAttr>("tfg.number_attr")) in ExportArgDef()
122 if (StringAttr type_list_attr = in ExportArgDef()
123 arg_attrs.getAs<StringAttr>("tfg.type_list_attr")) in ExportArgDef()
168 if (auto description = func_op->getAttrOfType<StringAttr>("description")) in ConvertGenericFunctionToFunctionDef()
177 if (StringAttr type = dict_attr.getAs<StringAttr>("function_type")) in ConvertGenericFunctionToFunctionDef()
[all …]
/external/tensorflow/tensorflow/compiler/mlir/tensorflow/transforms/
Dtensor_device_copy_conversion.cc52 const StringAttr &op_device) { in runOnOperation()
74 if (StringAttr attr = func_op.getArgAttrOfType<StringAttr>( in runOnOperation()
78 } else if (StringAttr attr = arg.getDefiningOp()->getAttrOfType<StringAttr>( in runOnOperation()
87 StringAttr op_device = op->getAttrOfType<StringAttr>(kDeviceAttr); in runOnOperation()
96 StringAttr op_device = op->getAttrOfType<StringAttr>(kDeviceAttr); in runOnOperation()
Dconstant_op_device_assignment.cc46 if (StringAttr device_attr = op->getAttrOfType<StringAttr>(kDeviceAttr)) { in runOnOperation()
56 StringAttr device_attr = user_op->getAttrOfType<StringAttr>(kDeviceAttr); in runOnOperation()
Dcluster_tf_ops_pass.cc68 if (StringAttr attr = op->getAttrOfType<StringAttr>(kDeviceAttr)) { in GetHost()
127 if (StringAttr attr = func_op.getArgAttrOfType<StringAttr>( in GetFunctionMetadatas()
149 if (StringAttr attr = in GetFunctionMetadatas()
150 defining_op->getAttrOfType<StringAttr>(kDeviceAttr)) { in GetFunctionMetadatas()
214 StringAttr::get(context, metadata.input_devices[i])); in CreateFunctions()
219 StringAttr::get(context, metadata.result_devices[i])); in CreateFunctions()
222 func_op->setAttr(kHostAttr, StringAttr::get(context, host)); in CreateFunctions()
Dtpu_device_propagation.cc65 auto lhs_device_attr = lhs->getAttrOfType<StringAttr>(kDeviceAttr); in IsSupportedExecutorOp()
66 auto rhs_device_attr = rhs->getAttrOfType<StringAttr>(kDeviceAttr); in IsSupportedExecutorOp()
147 func.getArgAttrOfType<StringAttr>(arg.getArgNumber(), kFuncDeviceAttr); in PropagateDevicesFromArguments()
178 auto device_attr = op_to_update->getAttrOfType<StringAttr>(kDeviceAttr); in PropagateDevicesInGraph()
196 mlir::StringAttr::get(op_to_update->getContext(), new_device); in PropagateDevicesInGraph()
221 auto device_attr = func.getResultAttrOfType<StringAttr>( in PropagateDevicesToResults()
225 StringAttr::get(func.getContext(), it->getSecond())); in PropagateDevicesToResults()
Dreadonly_references_to_resources.cc68 StringAttr shared_name_attr = op->getAttrOfType<StringAttr>(kSharedNameAttr); in GetNodeNameFromClassAttrOrSharedNameAttr()
92 StringRef node_name = class_attr.cast<StringAttr>().getValue(); in GetNodeNameFromClassAttrOrSharedNameAttr()
153 StringAttr device_attr = in runOnOperation()
154 variable_v2_op->getAttrOfType<StringAttr>("device"); in runOnOperation()
Dmark_ops_for_outside_compilation.cc264 if (parent->getAttrOfType<StringAttr>(kXlaOutsideCompilationAttr)) in HasOutsideCompiledAncestor()
277 if (op->hasAttrOfType<StringAttr>(kXlaOutsideCompilationAttr)) in MarkVariantInputsOutputs()
290 !input_defining_op->hasAttrOfType<StringAttr>( in MarkVariantInputsOutputs()
294 StringAttr::get(input_defining_op->getContext(), "auto")); in MarkVariantInputsOutputs()
305 !user->getAttrOfType<StringAttr>(kXlaOutsideCompilationAttr)) { in MarkVariantInputsOutputs()
307 StringAttr::get(user->getContext(), "auto")); in MarkVariantInputsOutputs()
335 StringAttr::get( in MarkUncompilableOps()
357 if (iter_op->hasAttrOfType<StringAttr>(kXlaOutsideCompilationAttr)) { in ContainsUncompilableOps()
377 if (!op->getAttrOfType<StringAttr>(kXlaOutsideCompilationAttr)) return; in UnmarkChildren()
381 if (parent_op->getAttrOfType<StringAttr>(kXlaOutsideCompilationAttr)) { in UnmarkChildren()
/external/tensorflow/tensorflow/compiler/mlir/tfr/ir/
Dtfr_types.h42 public llvm::TrailingObjects<TFRTypeStorage, StringAttr> {
43 using KeyTy = ArrayRef<StringAttr>;
49 auto byteSize = TFRTypeStorage::totalSizeToAlloc<StringAttr>(key.size()); in construct()
55 result->getTrailingObjects<StringAttr>()); in construct()
62 return {getTrailingObjects<StringAttr>(), num_attrs}; in GetAttrs()
75 static Derived get(ArrayRef<StringAttr> attrs, MLIRContext* context) { in get()
79 static Derived getChecked(ArrayRef<StringAttr> attrs, Location loc) { in getChecked()
83 MLIRContext* context, ArrayRef<StringAttr> attrs) { in getChecked()
91 ArrayRef<StringAttr> attrs) { in verify()
95 ArrayRef<StringAttr> getAttrKeys() { return Base::getImpl()->GetAttrs(); } in getAttrKeys()
/external/tensorflow/tensorflow/core/transforms/const_dedupe_hoist/
Dpass.cc45 dtype_id = StringAttr::get(context, "dtype"); in initialize()
46 name_id = StringAttr::get(context, TFGraphDialect::getNameAttrKey()); in initialize()
47 t_id = StringAttr::get(context, "T"); in initialize()
48 tfg_const = StringAttr::get(context, "tfg.Const"); in initialize()
49 value_id = StringAttr::get(context, "value"); in initialize()
70 StringAttr dtype_id;
71 StringAttr name_id;
72 StringAttr tfg_const;
73 StringAttr t_id;
74 StringAttr value_id;
[all …]
/external/tensorflow/tensorflow/compiler/mlir/tensorflow/utils/
Derror_util_test.cc32 auto id = StringAttr::get(&context, "//tensorflow/python/test.py"); in TEST()
82 StringAttr::get(&context, "//tensorflow/python/keras/keras_file.py"); in TEST()
85 StringAttr::get(&context, "//tensorflow/python/something/my_test.py"); in TEST()
87 auto id3 = StringAttr::get(&context, "python/tensorflow/show_file.py"); in TEST()
93 StringAttr::get(&context, "//tensorflow/python/dir/filtered_file_A.py"); in TEST()
96 StringAttr::get(&context, "dir/tensorflow/python/filtered_file_B.py"); in TEST()
126 StringAttr::get(&context, "//tensorflow/python/keras/keras_file.py"); in TEST()
132 StringAttr::get(&context, "//tensorflow/python/dir/filtered_file_A.py"); in TEST()
135 StringAttr::get(&context, "dir/tensorflow/python/filtered_file_B.py"); in TEST()
138 StringAttr::get(&context, "//tensorflow/python/something/my_op.py"); in TEST()
/external/tensorflow/tensorflow/compiler/mlir/quantization/tensorflow/passes/
Dinsert_main_function.cc59 StringAttr main_func_id = StringAttr::get(module.getContext(), "main"); in HasMainFunction()
91 const StringAttr& attr_name = attr.getName(); in SetFunctionPrivate()
99 const StringAttr& attr_name = attr.getName(); in SetFunctionPrivate()
134 inputs_attr.cast<StringAttr>().getValue().str(); in CreateMainFunction()
142 outputs_attr.cast<StringAttr>().getValue().str(); in CreateMainFunction()
159 {StringAttr::get(context, "inputs"), in CreateMainFunction()
160 StringAttr::get(context, absl::StrJoin(input_names, ","))}); in CreateMainFunction()
162 {StringAttr::get(context, "outputs"), in CreateMainFunction()
163 StringAttr::get(context, absl::StrJoin(output_names, ","))}); in CreateMainFunction()
165 main_func->setAttr(StringAttr::get(context, kEntryFunctionAttr), dictAttr); in CreateMainFunction()
[all …]
/external/tensorflow/tensorflow/core/transforms/consolidate_attrs/
Dpass.cc73 input_shapes_id_ = StringAttr::get(context, "tf._input_shapes"); in initialize()
75 StringAttr::get(context, "tfg.regenerate_input_shapes"); in initialize()
76 output_shapes_id_ = StringAttr::get(context, "tf._output_shapes"); in initialize()
78 StringAttr::get(context, "tfg.regenerate_output_shapes"); in initialize()
79 handle_data_id_ = StringAttr::get(context, "tfg.handle_data"); in initialize()
80 dtype_id_ = StringAttr::get(context, "tfg.dtype"); in initialize()
81 is_ref_id_ = StringAttr::get(context, "tfg.is_ref"); in initialize()
88 StringAttr input_shapes_id_;
90 StringAttr regenerate_input_shapes_id_;
92 StringAttr output_shapes_id_;
[all …]
/external/tensorflow/tensorflow/compiler/mlir/tfrt/transforms/
Dremote_run_encapsulate.cc143 StringAttr callee_name = in runOnOperation()
144 StringAttr::get(&getContext(), callee_sym.getValue()); in runOnOperation()
149 StringAttr::get(&getContext(), txt_module), callee_name); in runOnOperation()
155 StringAttr device = in runOnOperation()
156 callee.getResultAttrOfType<StringAttr>(result.index(), kTFRTDevice); in runOnOperation()
162 if (StringAttr host_attr = callee->getAttrOfType<StringAttr>(kHost)) { in runOnOperation()
171 device = StringAttr::get( in runOnOperation()
Dcross_device_transfer.cc78 if (StringAttr device_attr = op->getAttrOfType<StringAttr>(kDeviceAttr)) { in GetDevice()
84 if (entry.first == kDeviceAttr && entry.second.isa<StringAttr>()) { in GetDevice()
85 device = entry.second.cast<StringAttr>().getValue().str(); in GetDevice()
98 if (StringAttr device_attr = parent_func_op.getArgAttrOfType<StringAttr>( in GetDevice()
/external/tensorflow/tensorflow/compiler/mlir/lite/utils/
Dvalidators.h34 auto attr = op->getAttrOfType<StringAttr>("data_format"); in TFDataFormatIsNHWC()
42 auto attr = op->getAttrOfType<StringAttr>("data_format"); in TFDataFormatIsNDHWC()
96 inline bool TFPaddingIsSameOrValid(Operation *op, StringAttr *padding) { in TFPaddingIsSameOrValid()
97 auto padding_attr = op->getAttrOfType<StringAttr>("padding"); in TFPaddingIsSameOrValid()
/external/tensorflow/tensorflow/core/runtime_fallback/opdefs/
Dtfrt_fallback_common.h33 !key_value.getValue()[0].template isa<mlir::StringAttr>()) in VerifyExecuteOpCommon()
50 !key_value.getValue()[0].template isa<mlir::StringAttr>() || in VerifyFallbackExecuteOp()
51 !key_value.getValue()[1].template isa<mlir::StringAttr>()) in VerifyFallbackExecuteOp()
68 p << key.cast<mlir::StringAttr>().getValue(); in PrintExecuteOpFuncAttribute()
89 p << key.cast<mlir::StringAttr>().getValue(); in PrintExecuteOpCommon()
/external/tensorflow/tensorflow/compiler/mlir/tfrt/ir/
Dtfrt_fallback_common.h33 !key_value.getValue()[0].template isa<mlir::StringAttr>()) in VerifyExecuteOpCommon()
50 !key_value.getValue()[0].template isa<mlir::StringAttr>() || in VerifyFallbackExecuteOp()
51 !key_value.getValue()[1].template isa<mlir::StringAttr>()) in VerifyFallbackExecuteOp()
68 p << key.cast<mlir::StringAttr>().getValue(); in PrintExecuteOpFuncAttribute()
89 p << key.cast<mlir::StringAttr>().getValue(); in PrintExecuteOpCommon()
/external/tensorflow/tensorflow/core/transforms/region_to_functional/
Dimpl.cc64 tfg_regenerate_output_shapes(StringAttr::get( in CachedIdentifiers()
68 StringAttr tfg_name;
70 StringAttr tfg_regenerate_output_shapes;
81 StringAttr GetUniqued(StringAttr name) { in GetUniqued()
85 StringAttr next_name; in GetUniqued()
88 StringAttr::get(ctx_, name.getValue() + "_" + Twine(suffix++)); in GetUniqued()
98 DenseSet<StringAttr> unique_names_;
145 StringAttr TryFindName(Value value, Optional<ValueRange> args) const;
442 for (StringAttr attr_name : {StringAttr::get(ctx_, "_tpu_replicate"), in MakeChainConstant()
450 StringAttr name_id = dialect_.getNameAttrIdentifier(); in MakeChainConstant()
[all …]
/external/tensorflow/tensorflow/core/transforms/cf_sink/
Dpass.cc54 StringAttr name_id_;
85 auto name = op->getAttrOfType<StringAttr>(name_id_); in moveAndRename()
86 auto parent_name = region->getParentOp()->getAttrOfType<StringAttr>(name_id_); in moveAndRename()
88 op->setAttr(name_id_, StringAttr::get(op->getContext(), in moveAndRename()
/external/tensorflow/tensorflow/compiler/mlir/tfrt/jit/transforms/
Dtf_jitrt_fission.cc42 mlir::StringAttr fusion0 = in matchAndRewrite()
43 n > 0 ? op.fused_ops()[0].dyn_cast<mlir::StringAttr>() : nullptr; in matchAndRewrite()
44 mlir::StringAttr fusion1 = in matchAndRewrite()
45 n > 1 ? op.fused_ops()[1].dyn_cast<mlir::StringAttr>() : nullptr; in matchAndRewrite()

123456789