** Description of the problem ** `is_matched_graph` implementation is a bit confusing because is not so easy to understand the comparison between the current graph and the properties of the cached graphs. The usage of `continue` to skip graphs of different sizes, and a combination of a `break` and a flag to exit the inner loop to simulate a `continue` in the outer loop, make it very difficult to follow the logic. Moreover, the passed arguments and the function name do not match the intended semantics properly. ** Proposed solution ** * Rename the function to `is_matched_graph_in_cache` to better reflect its intention. * Pass only the graph cache list instead of the whole context. * Enclose the graph node traversal check inside a lambda to avoid having to use statements that break the control flow arbitrarily. * Rename variables in a more meaningful way. * Update the corresponding function call. |
||
|---|---|---|
| .. | ||
| cmake | ||
| include | ||
| src | ||
| .gitignore | ||
| CMakeLists.txt | ||