Lines Matching +full:string +full:- +full:support
1 //===- TensorSpec.cpp - tensor type abstraction ---------------------------===//
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7 //===----------------------------------------------------------------------===//
12 //===----------------------------------------------------------------------===//
19 #include "llvm/Support/CommandLine.h"
20 #include "llvm/Support/Debug.h"
21 #include "llvm/Support/JSON.h"
22 #include "llvm/Support/ManagedStatic.h"
23 #include "llvm/Support/raw_ostream.h"
39 static std::array<std::string, static_cast<size_t>(TensorType::Total)> in SUPPORTED_TENSOR_TYPES()
62 TensorSpec::TensorSpec(const std::string &Name, int Port, TensorType Type, in TensorSpec()
72 [&](const llvm::Twine &Message) -> std::optional<TensorSpec> { in getTensorSpecFromJSON()
73 std::string S; in getTensorSpecFromJSON()
85 std::string TensorName; in getTensorSpecFromJSON()
86 int TensorPort = -1; in getTensorSpecFromJSON()
87 std::string TensorType; in getTensorSpecFromJSON()
90 if (!Mapper.map<std::string>("name", TensorName)) in getTensorSpecFromJSON()
91 return EmitError("'name' property not present or not a string"); in getTensorSpecFromJSON()
92 if (!Mapper.map<std::string>("type", TensorType)) in getTensorSpecFromJSON()
93 return EmitError("'type' property not present or not a string"); in getTensorSpecFromJSON()
107 std::string tensorValueToString(const char *Buffer, const TensorSpec &Spec) { in tensorValueToString()