MCPcopy Create free account
hub / github.com/F-Stack/f-stack / graph_init_parallel_tree

Function graph_init_parallel_tree

dpdk/app/test/test_graph_perf.c:929–980  ·  view source on GitHub ↗

Graph Topology * nodes per stage: 4 * stages: 5 * src: 4 * sink: 4 */

Source from the content-addressed store, hash-verified

927 * sink: 4
928 */
929static inline int
930graph_init_parallel_tree(void)
931{
932 uint8_t edge_map[][4][4] = {
933 {
934 {100, 0, 0, 0},
935 {0, 100, 0, 0},
936 {0, 0, 100, 0},
937 {0, 0, 0, 100}
938 },
939 {
940 {100, 0, 0, 0},
941 {0, 100, 0, 0},
942 {0, 0, 100, 0},
943 {0, 0, 0, 100}
944 },
945 {
946 {100, 0, 0, 0},
947 {0, 100, 0, 0},
948 {0, 0, 100, 0},
949 {0, 0, 0, 100}
950 },
951 {
952 {100, 0, 0, 0},
953 {0, 100, 0, 0},
954 {0, 0, 100, 0},
955 {0, 0, 0, 100}
956 },
957 {
958 {100, 0, 0, 0},
959 {0, 100, 0, 0},
960 {0, 0, 100, 0},
961 {0, 0, 0, 100}
962 },
963 };
964 uint8_t src_map[][4] = {
965 {100, 0, 0, 0},
966 {0, 100, 0, 0},
967 {0, 0, 100, 0},
968 {0, 0, 0, 100}
969 };
970 uint8_t snk_map[][4] = {
971 {100, 0, 0, 0},
972 {0, 100, 0, 0},
973 {0, 0, 100, 0},
974 {0, 0, 0, 100}
975 };
976
977 return graph_init("graph_parallel", SOURCES(src_map), SINKS(snk_map),
978 STAGES(edge_map), NODES_PER_STAGE(edge_map), src_map,
979 snk_map, edge_map, 0);
980}
981
982/** Graph Creation cheat sheet
983 * edge_map -> dictates graph flow from worker stage 0 to worker stage n-1.

Callers

nothing calls this directly

Calls 1

graph_initFunction · 0.70

Tested by

no test coverage detected