MCPcopy Create free account
hub / github.com/ROCm/AMDMIGraphX / any_sm_next

Function any_sm_next

src/split_single_dyn_dim.cpp:96–110  ·  view source on GitHub ↗

* Check the parameters in std::vector object to see if any of the * parameters outputs to a select_module operator. */

Source from the content-addressed store, hash-verified

94 * parameters outputs to a select_module operator.
95 */
96static bool any_sm_next(const_module_ref mm, const std::vector<dynamic_dimensions_check>& ddcs)
97{
98 for(const auto& ddc : ddcs)
99 {
100 auto p_outputs = mm->get_parameter(ddc.dyn_param_str)->outputs();
101 bool is_sm_next = std::any_of(p_outputs.cbegin(), p_outputs.cend(), [](auto ins) {
102 return ins->name() == "select_module";
103 });
104 if(is_sm_next)
105 {
106 return true;
107 };
108 }
109 return false;
110}
111
112/**
113 * Makes all the shapes in the dynamic_dimension range. Probably won't work for `if`

Callers 1

applyMethod · 0.85

Calls 4

outputsMethod · 0.80
any_ofFunction · 0.50
get_parameterMethod · 0.45
nameMethod · 0.45

Tested by

no test coverage detected