Skip to content

Commit ffcd221

Browse files
CodemodService Botfacebook-github-bot
authored andcommitted
fbcode//executorch/backends/vulkan:vulkan_graph_runtime
Reviewed By: dtolnay Differential Revision: D79042088
1 parent 6d4b68a commit ffcd221

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

backends/vulkan/runtime/graph/Logging.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -97,11 +97,11 @@ void ComputeGraph::print_readable() {
9797
// Node type
9898
std::cout << std::setw(10);
9999
{
100-
if (input_set.count(value_idx) > 0) {
100+
if (input_set.contains(value_idx)) {
101101
std::cout << "INPUT";
102-
} else if (output_set.count(value_idx) > 0) {
102+
} else if (output_set.contains(value_idx)) {
103103
std::cout << "OUTPUT";
104-
} else if (prepack_set.count(value_idx) > 0) {
104+
} else if (prepack_set.contains(value_idx)) {
105105
std::cout << "PREPACK";
106106
} else {
107107
std::cout << "";
@@ -119,7 +119,7 @@ void ComputeGraph::print_readable() {
119119
}
120120

121121
std::cout << std::setw(10);
122-
if (value_ref_to_shared_object_idx.count(value_idx) > 0) {
122+
if (value_ref_to_shared_object_idx.contains(value_idx)) {
123123
size_t shared_obj_idx = value_ref_to_shared_object_idx.at(value_idx);
124124
std::cout << shared_obj_idx;
125125
} else {

backends/vulkan/runtime/graph/ops/OperatorRegistry.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
namespace vkcompute {
1212

1313
bool OperatorRegistry::has_op(const std::string& name) {
14-
return table_.count(name) > 0;
14+
return table_.contains(name);
1515
}
1616

1717
OperatorRegistry::OpFunction& OperatorRegistry::get_op_fn(

0 commit comments

Comments
 (0)