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

Function log_eval_state

dpdk/lib/bpf/bpf_validate.c:2252–2276  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2250}
2251
2252static void
2253log_eval_state(const struct bpf_verifier *bvf, const struct ebpf_insn *ins,
2254 uint32_t pc, int32_t loglvl)
2255{
2256 const struct bpf_eval_state *st;
2257 const struct bpf_reg_val *rv;
2258
2259 rte_log(loglvl, rte_bpf_logtype, "%s(pc=%u):\n", __func__, pc);
2260
2261 st = bvf->evst;
2262 rv = st->rv + ins->dst_reg;
2263
2264 rte_log(loglvl, rte_bpf_logtype,
2265 "r%u={\n"
2266 "\tv={type=%u, size=%zu, buf_size=%zu},\n"
2267 "\tmask=0x%" PRIx64 ",\n"
2268 "\tu={min=0x%" PRIx64 ", max=0x%" PRIx64 "},\n"
2269 "\ts={min=%" PRId64 ", max=%" PRId64 "},\n"
2270 "};\n",
2271 ins->dst_reg,
2272 rv->v.type, rv->v.size, rv->v.buf_size,
2273 rv->mask,
2274 rv->u.min, rv->u.max,
2275 rv->s.min, rv->s.max);
2276}
2277
2278/*
2279 * compare two evaluation states.

Callers 1

evaluateFunction · 0.85

Calls 1

rte_logFunction · 0.85

Tested by

no test coverage detected