Home
last modified time | relevance | path

Searched full:costs (Results 1 – 25 of 2007) sorted by relevance

12345678910>>...81

/aosp_15_r20/external/tensorflow/tensorflow/core/grappler/costs/
H A Dop_level_cost_estimator_test.cc16 #include "tensorflow/core/grappler/costs/op_level_cost_estimator.h"
60 void ExpectZeroCost(const Costs& cost) { in ExpectZeroCost()
62 EXPECT_EQ(cost.compute_time, Costs::Duration::zero()); in ExpectZeroCost()
63 EXPECT_EQ(cost.execution_time, Costs::Duration::zero()); in ExpectZeroCost()
64 EXPECT_EQ(cost.memory_time, Costs::Duration::zero()); in ExpectZeroCost()
516 Costs PredictCosts(const OpContext& op_context) const { in PredictCosts()
675 EXPECT_EQ(Costs::Duration(0), cost.memory_time); in TEST_F()
676 EXPECT_EQ(Costs::Duration(1), cost.compute_time); in TEST_F()
677 EXPECT_EQ(Costs::Duration(1), cost.execution_time); in TEST_F()
694 // Huge first input shouldn't affect Gather execution and memory costs. in TEST_F()
[all …]
H A Dcost_estimator_test.cc16 #include "tensorflow/core/grappler/costs/cost_estimator.h"
25 Costs c = Costs::ZeroCosts(); in TEST()
26 c.execution_time = Costs::NanoSeconds(1); in TEST()
27 c.compute_time = Costs::NanoSeconds(2); in TEST()
28 c.memory_time = Costs::NanoSeconds(3); in TEST()
29 c.intermediate_memory_time = Costs::NanoSeconds(4); in TEST()
30 c.intermediate_memory_read_time = Costs::NanoSeconds(5); in TEST()
31 c.intermediate_memory_write_time = Costs::NanoSeconds(6); in TEST()
39 Costs sum = CombineCosts(c, c); in TEST()
41 EXPECT_EQ(sum.execution_time, Costs::NanoSeconds(2)); in TEST()
[all …]
H A Dcost_estimator.h75 struct Costs { struct
76 // Returns a Costs structure with default values for all of the fields.
77 inline Costs();
79 // Builds a Costs structure with all zero values, rather than unknowns.
80 static inline Costs ZeroCosts(bool inaccurate = false);
165 // Number of ops included in this Costs in total. argument
179 inline std::ostream& operator<<(std::ostream& os, const Costs::MilliSeconds d) { argument
183 inline std::ostream& operator<<(std::ostream& os, const Costs::MicroSeconds d) {
187 inline std::ostream& operator<<(std::ostream& os, const Costs::NanoSeconds d) {
192 Costs::Costs() { in Costs() function
[all …]
H A Dvirtual_scheduler.h28 #include "tensorflow/core/grappler/costs/cost_estimator.h"
29 #include "tensorflow/core/grappler/costs/graph_properties.h"
30 #include "tensorflow/core/grappler/costs/op_context.h"
31 #include "tensorflow/core/grappler/costs/virtual_placer.h"
64 Costs::Duration time_ready;
65 Costs::Duration time_scheduled;
66 Costs::Duration time_finished;
69 std::unordered_map<int, Costs::Duration> time_no_references;
82 Costs node_costs; // Node costs per execution
83 Costs TotalNodeCosts() const { in TotalNodeCosts()
[all …]
H A Dcost_estimator.cc16 #include "tensorflow/core/grappler/costs/cost_estimator.h"
21 Costs CombineCosts(const Costs& left, const Costs& right) { in CombineCosts()
26 Costs result = left; in CombineCosts()
55 // Multiplies Costs by a scalar.
58 Costs MultiplyCosts(const Costs& costs, int multiplier) { in MultiplyCosts() argument
61 return Costs::ZeroCosts(); in MultiplyCosts()
64 return costs; in MultiplyCosts()
67 Costs result = costs; in MultiplyCosts()
H A Danalytical_cost_estimator.cc16 #include "tensorflow/core/grappler/costs/analytical_cost_estimator.h"
24 #include "tensorflow/core/grappler/costs/graph_properties.h"
25 #include "tensorflow/core/grappler/costs/op_performance_data.pb.h"
26 #include "tensorflow/core/grappler/costs/utils.h"
27 #include "tensorflow/core/grappler/costs/virtual_placer.h"
28 #include "tensorflow/core/grappler/costs/virtual_scheduler.h"
41 int node_id, const Costs& node_costs, in AddCostNode()
159 Costs* costs) const { in PredictCosts()
175 if (costs) { in PredictCosts()
176 costs->execution_time = Costs::Duration::max(); in PredictCosts()
[all …]
/aosp_15_r20/external/swiftshader/third_party/llvm-16.0/llvm/include/llvm/CodeGen/PBQP/
H A DGraph.h68 NodeEntry(VectorPtr Costs) : Costs(std::move(Costs)) {} in NodeEntry() argument
94 VectorPtr Costs; variable
103 EdgeEntry(NodeId N1Id, NodeId N2Id, MatrixPtr Costs) in EdgeEntry() argument
104 : Costs(std::move(Costs)) { in EdgeEntry()
152 MatrixPtr Costs; variable
371 /// Add a node with the given costs.
372 /// @param Costs Cost vector for the new node.
375 NodeId addNode(OtherVectorT Costs) { in addNode() argument
377 VectorPtr AllocatedCosts = CostAlloc.getVector(std::move(Costs)); in addNode()
385 /// @param Costs Cost vector ptr for the new node (must be convertible to
[all …]
/aosp_15_r20/external/swiftshader/third_party/llvm-10.0/llvm/include/llvm/CodeGen/PBQP/
H A DGraph.h68 NodeEntry(VectorPtr Costs) : Costs(std::move(Costs)) {} in NodeEntry() argument
94 VectorPtr Costs; variable
103 EdgeEntry(NodeId N1Id, NodeId N2Id, MatrixPtr Costs) in EdgeEntry() argument
104 : Costs(std::move(Costs)) { in EdgeEntry()
152 MatrixPtr Costs; variable
371 /// Add a node with the given costs.
372 /// @param Costs Cost vector for the new node.
375 NodeId addNode(OtherVectorT Costs) { in addNode() argument
377 VectorPtr AllocatedCosts = CostAlloc.getVector(std::move(Costs)); in addNode()
385 /// @param Costs Cost vector ptr for the new node (must be convertible to
[all …]
/aosp_15_r20/prebuilts/clang/host/linux-x86/clang-r530567b/include/llvm/CodeGen/PBQP/
DGraph.h68 NodeEntry(VectorPtr Costs) : Costs(std::move(Costs)) {} in NodeEntry() argument
94 VectorPtr Costs; variable
103 EdgeEntry(NodeId N1Id, NodeId N2Id, MatrixPtr Costs) in EdgeEntry() argument
104 : Costs(std::move(Costs)) { in EdgeEntry()
152 MatrixPtr Costs; variable
371 /// Add a node with the given costs.
372 /// @param Costs Cost vector for the new node.
375 NodeId addNode(OtherVectorT Costs) { in addNode() argument
377 VectorPtr AllocatedCosts = CostAlloc.getVector(std::move(Costs)); in addNode()
385 /// @param Costs Cost vector ptr for the new node (must be convertible to
[all …]
/aosp_15_r20/prebuilts/clang/host/linux-x86/clang-r522817/include/llvm/CodeGen/PBQP/
DGraph.h68 NodeEntry(VectorPtr Costs) : Costs(std::move(Costs)) {} in NodeEntry() argument
94 VectorPtr Costs; variable
103 EdgeEntry(NodeId N1Id, NodeId N2Id, MatrixPtr Costs) in EdgeEntry() argument
104 : Costs(std::move(Costs)) { in EdgeEntry()
152 MatrixPtr Costs; variable
371 /// Add a node with the given costs.
372 /// @param Costs Cost vector for the new node.
375 NodeId addNode(OtherVectorT Costs) { in addNode() argument
377 VectorPtr AllocatedCosts = CostAlloc.getVector(std::move(Costs)); in addNode()
385 /// @param Costs Cost vector ptr for the new node (must be convertible to
[all …]
/aosp_15_r20/prebuilts/clang/host/linux-x86/clang-r530567/include/llvm/CodeGen/PBQP/
DGraph.h68 NodeEntry(VectorPtr Costs) : Costs(std::move(Costs)) {} in NodeEntry() argument
94 VectorPtr Costs; variable
103 EdgeEntry(NodeId N1Id, NodeId N2Id, MatrixPtr Costs) in EdgeEntry() argument
104 : Costs(std::move(Costs)) { in EdgeEntry()
152 MatrixPtr Costs; variable
371 /// Add a node with the given costs.
372 /// @param Costs Cost vector for the new node.
375 NodeId addNode(OtherVectorT Costs) { in addNode() argument
377 VectorPtr AllocatedCosts = CostAlloc.getVector(std::move(Costs)); in addNode()
385 /// @param Costs Cost vector ptr for the new node (must be convertible to
[all …]
/aosp_15_r20/prebuilts/clang/host/linux-x86/clang-r536225/include/llvm/CodeGen/PBQP/
DGraph.h68 NodeEntry(VectorPtr Costs) : Costs(std::move(Costs)) {} in NodeEntry() argument
94 VectorPtr Costs; variable
103 EdgeEntry(NodeId N1Id, NodeId N2Id, MatrixPtr Costs) in EdgeEntry() argument
104 : Costs(std::move(Costs)) { in EdgeEntry()
152 MatrixPtr Costs; variable
371 /// Add a node with the given costs.
372 /// @param Costs Cost vector for the new node.
375 NodeId addNode(OtherVectorT Costs) { in addNode() argument
377 VectorPtr AllocatedCosts = CostAlloc.getVector(std::move(Costs)); in addNode()
385 /// @param Costs Cost vector ptr for the new node (must be convertible to
[all …]
/aosp_15_r20/external/google-cloud-java/java-recommendations-ai/proto-google-cloud-recommendations-ai-v1beta1/src/main/java/com/google/cloud/recommendationengine/v1beta1/
H A DPurchaseTransactionOrBuilder.java125 * Optional. All the costs associated with the product. These can be
126 * manufacturing costs, shipping expenses not borne by the end user, or any
127 * other costs.
129 * profit = revenue - (sum(taxes) + sum(costs))
131 * profit = revenue - tax - shipping - sum(CatalogItem.costs).
136 * <code>map&lt;string, float&gt; costs = 4 [(.google.api.field_behavior) = OPTIONAL];</code>
143 * Optional. All the costs associated with the product. These can be
144 * manufacturing costs, shipping expenses not borne by the end user, or any
145 * other costs.
147 * profit = revenue - (sum(taxes) + sum(costs))
[all …]
H A DPurchaseTransaction.java285 * Optional. All the costs associated with the product. These can be
286 * manufacturing costs, shipping expenses not borne by the end user, or any
287 * other costs.
289 * profit = revenue - (sum(taxes) + sum(costs))
291 * profit = revenue - tax - shipping - sum(CatalogItem.costs).
296 * <code>map&lt;string, float&gt; costs = 4 [(.google.api.field_behavior) = OPTIONAL];</code>
315 * Optional. All the costs associated with the product. These can be
316 * manufacturing costs, shipping expenses not borne by the end user, or any
317 * other costs.
319 * profit = revenue - (sum(taxes) + sum(costs))
[all …]
H A DProductCatalogItemOrBuilder.java114 * Optional. A map to pass the costs associated with the product.
118 * * If 'exactPrice' is provided, profit = displayPrice - sum(costs)
119 * * If 'priceRange' is provided, profit = minPrice - sum(costs)
122 * <code>map&lt;string, float&gt; costs = 3 [(.google.api.field_behavior) = OPTIONAL];</code>
129 * Optional. A map to pass the costs associated with the product.
133 * * If 'exactPrice' is provided, profit = displayPrice - sum(costs)
134 * * If 'priceRange' is provided, profit = minPrice - sum(costs)
137 * <code>map&lt;string, float&gt; costs = 3 [(.google.api.field_behavior) = OPTIONAL];</code>
147 * Optional. A map to pass the costs associated with the product.
151 * * If 'exactPrice' is provided, profit = displayPrice - sum(costs)
[all …]
/aosp_15_r20/external/llvm/include/llvm/CodeGen/PBQP/
H A DGraph.h74 NodeEntry(VectorPtr Costs) : Costs(std::move(Costs)) {} in NodeEntry() argument
96 VectorPtr Costs; variable
104 EdgeEntry(NodeId N1Id, NodeId N2Id, MatrixPtr Costs) in EdgeEntry() argument
105 : Costs(std::move(Costs)) { in EdgeEntry()
116 Costs = nullptr; in invalidate()
168 MatrixPtr Costs; variable
378 /// @brief Add a node with the given costs.
379 /// @param Costs Cost vector for the new node.
382 NodeId addNode(OtherVectorT Costs) { in addNode() argument
384 VectorPtr AllocatedCosts = CostAlloc.getVector(std::move(Costs)); in addNode()
[all …]
/aosp_15_r20/external/llvm/lib/Analysis/
H A DTargetTransformInfo.cpp53 assert(Cost >= 0 && "TTI should not produce negative costs!"); in getOperationCost()
59 assert(Cost >= 0 && "TTI should not produce negative costs!"); in getCallCost()
66 assert(Cost >= 0 && "TTI should not produce negative costs!"); in getCallCost()
82 assert(Cost >= 0 && "TTI should not produce negative costs!"); in getIntrinsicCost()
88 assert(Cost >= 0 && "TTI should not produce negative costs!"); in getUserCost()
149 assert(Cost >= 0 && "TTI should not produce negative costs!"); in getScalingFactorCost()
208 assert(Cost >= 0 && "TTI should not produce negative costs!"); in getFPOpCost()
216 assert(Cost >= 0 && "TTI should not produce negative costs!"); in getIntImmCodeSizeCost()
222 assert(Cost >= 0 && "TTI should not produce negative costs!"); in getIntImmCost()
229 assert(Cost >= 0 && "TTI should not produce negative costs!"); in getIntImmCost()
[all …]
/aosp_15_r20/external/zopfli/src/zopfli/
H A Dsqueeze.c222 ZopfliHash* h, float* costs) { in GetBestLengths() argument
243 for (i = 1; i < blocksize + 1; i++) costs[i] = ZOPFLI_LARGE_FLOAT; in GetBestLengths()
244 costs[0] = 0; /* Because it's the start. */ in GetBestLengths()
248 size_t j = i - instart; /* Index in the costs array and length_array. */ in GetBestLengths()
264 costs[j + ZOPFLI_MAX_MATCH] = costs[j] + symbolcost; in GetBestLengths()
278 double newCost = costmodel(in[i], 0, costcontext) + costs[j]; in GetBestLengths()
280 if (newCost < costs[j + 1]) { in GetBestLengths()
281 costs[j + 1] = newCost; in GetBestLengths()
287 mincostaddcostj = mincost + costs[j]; in GetBestLengths()
293 if (costs[j + k] <= mincostaddcostj) continue; in GetBestLengths()
[all …]
/aosp_15_r20/external/google-cloud-java/java-optimization/proto-google-cloud-optimization-v1/src/main/java/com/google/cloud/optimization/v1/
H A DOptimizeToursResponse.java243 * solution. In other words, costs["model.shipments.pickups.cost"] is the
244 * sum of all pickup costs over the solution. All costs defined in the model
245 * are reported in detail here with the exception of costs related to
250 * <code>map&lt;string, double&gt; costs = 10;</code>
261 * solution. In other words, costs["model.shipments.pickups.cost"] is the
262 * sum of all pickup costs over the solution. All costs defined in the model
263 * are reported in detail here with the exception of costs related to
268 * <code>map&lt;string, double&gt; costs = 10;</code>
282 * solution. In other words, costs["model.shipments.pickups.cost"] is the
283 * sum of all pickup costs over the solution. All costs defined in the model
[all …]
/aosp_15_r20/external/tensorflow/tensorflow/core/grappler/optimizers/
H A Dstatic_schedule_test.cc50 std::vector<Costs::NanoSeconds> GetOrderedTimes( in GetOrderedTimes()
51 const std::unordered_map<const NodeDef*, Costs::NanoSeconds> in GetOrderedTimes()
53 std::map<Costs::NanoSeconds, std::string> ordered_completion_times; in GetOrderedTimes()
59 std::vector<Costs::NanoSeconds> ordered_times; in GetOrderedTimes()
69 const std::unordered_map<const NodeDef*, Costs::NanoSeconds> in GetOrderedNodeNames()
71 std::map<Costs::NanoSeconds, std::string> ordered_completion_times; in GetOrderedNodeNames()
93 std::unordered_map<const NodeDef*, Costs::NanoSeconds> completion_times; in TEST_F()
101 std::vector<Costs::NanoSeconds> ordered_times = in TEST_F()
108 EXPECT_EQ(ordered_times[0], Costs::NanoSeconds(1)); in TEST_F()
138 std::unordered_map<const NodeDef*, Costs::NanoSeconds> completion_times; in TEST_F()
[all …]
H A Dstatic_schedule.cc21 #include "tensorflow/core/grappler/costs/graph_properties.h"
22 #include "tensorflow/core/grappler/costs/op_level_cost_estimator.h"
23 #include "tensorflow/core/grappler/costs/virtual_placer.h"
32 static Costs::NanoSeconds PredictExecutionTime( in PredictExecutionTime()
54 Costs::NanoSeconds estimate = in PredictExecutionTime()
58 return std::max(estimate, Costs::NanoSeconds(1)); in PredictExecutionTime()
63 std::unordered_map<const NodeDef*, Costs::NanoSeconds>* completion_times) { in EstimateEarliestExecutionTimes()
108 Costs::NanoSeconds execution_time = in EstimateEarliestExecutionTimes()
110 Costs::NanoSeconds completion_time = in EstimateEarliestExecutionTimes()
124 Costs::NanoSeconds ready_time = in EstimateEarliestExecutionTimes()
[all …]
/aosp_15_r20/external/llvm/lib/Target/AArch64/
H A DAArch64PBQPRegAlloc.cpp185 // costs. in addIntraChainConstraint()
191 PBQPRAGraph::RawMatrix costs(vRdAllowed->size() + 1, in addIntraChainConstraint() local
198 costs[i + 1][j + 1] = std::numeric_limits<PBQP::PBQPNum>::infinity(); in addIntraChainConstraint()
200 costs[i + 1][j + 1] = haveSameParity(pRd, pRa) ? 0.0 : 1.0; in addIntraChainConstraint()
203 G.addEdge(node1, node2, std::move(costs)); in addIntraChainConstraint()
213 PBQPRAGraph::RawMatrix costs(G.getEdgeCosts(edge)); in addIntraChainConstraint() local
223 if (costs[i + 1][j + 1] != in addIntraChainConstraint()
225 costs[i + 1][j + 1] > sameParityMax) in addIntraChainConstraint()
226 sameParityMax = costs[i + 1][j + 1]; in addIntraChainConstraint()
234 if (sameParityMax > costs[i + 1][j + 1]) in addIntraChainConstraint()
[all …]
/aosp_15_r20/external/swiftshader/third_party/llvm-10.0/llvm/lib/Target/AArch64/
H A DAArch64PBQPRegAlloc.cpp184 // costs. in addIntraChainConstraint()
190 PBQPRAGraph::RawMatrix costs(vRdAllowed->size() + 1, in addIntraChainConstraint() local
197 costs[i + 1][j + 1] = std::numeric_limits<PBQP::PBQPNum>::infinity(); in addIntraChainConstraint()
199 costs[i + 1][j + 1] = haveSameParity(pRd, pRa) ? 0.0 : 1.0; in addIntraChainConstraint()
202 G.addEdge(node1, node2, std::move(costs)); in addIntraChainConstraint()
212 PBQPRAGraph::RawMatrix costs(G.getEdgeCosts(edge)); in addIntraChainConstraint() local
222 if (costs[i + 1][j + 1] != in addIntraChainConstraint()
224 costs[i + 1][j + 1] > sameParityMax) in addIntraChainConstraint()
225 sameParityMax = costs[i + 1][j + 1]; in addIntraChainConstraint()
233 if (sameParityMax > costs[i + 1][j + 1]) in addIntraChainConstraint()
[all …]
/aosp_15_r20/external/swiftshader/third_party/llvm-16.0/llvm/lib/Target/AArch64/
H A DAArch64PBQPRegAlloc.cpp184 // costs. in addIntraChainConstraint()
190 PBQPRAGraph::RawMatrix costs(vRdAllowed->size() + 1, in addIntraChainConstraint() local
197 costs[i + 1][j + 1] = std::numeric_limits<PBQP::PBQPNum>::infinity(); in addIntraChainConstraint()
199 costs[i + 1][j + 1] = haveSameParity(pRd, pRa) ? 0.0 : 1.0; in addIntraChainConstraint()
202 G.addEdge(node1, node2, std::move(costs)); in addIntraChainConstraint()
212 PBQPRAGraph::RawMatrix costs(G.getEdgeCosts(edge)); in addIntraChainConstraint() local
222 if (costs[i + 1][j + 1] != in addIntraChainConstraint()
224 costs[i + 1][j + 1] > sameParityMax) in addIntraChainConstraint()
225 sameParityMax = costs[i + 1][j + 1]; in addIntraChainConstraint()
233 if (sameParityMax > costs[i + 1][j + 1]) in addIntraChainConstraint()
[all …]
/aosp_15_r20/packages/modules/AppSearch/testing/servicestests/src/com/android/server/appsearch/
DAppSearchRateLimitConfigTest.java42 // Verify that API costs are set to default of 1 in testDefaultRateLimitConfig()
61 // Unset API costs = 1 by default in testCustomRateLimitConfig()
96 // API costs = 1 by default in testRateLimitConfigRebuild_changeTotalCapacity()
118 // API costs = 1 by default in testRateLimitConfigRebuild_changePerPackagePercentage()
148 // Unset API costs = 1 by default in testRateLimitConfigRebuild_changeApiCosts()
170 // Unset API costs = 1 by default in testRateLimitConfigRebuild_allConfigsChanged()
186 // Unable to set API costs since the API name is case-sensitive in testApiCostStringCaseSensitive()
190 // Unset API costs = 1 by default in testApiCostStringCaseSensitive()
209 // Unset API costs = 1 by default in testInvalidApiCostsString_unspecifiedApiCosts()
228 // Unset API costs = 1 by default in testInvalidApiCostsString_nonIntegerApiCosts()
[all …]

12345678910>>...81