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

Function imm_size

dpdk/lib/bpf/bpf_jit_x86.c:125–131  ·  view source on GitHub ↗

* In many cases for imm8 we can produce shorter code. */

Source from the content-addressed store, hash-verified

123 * In many cases for imm8 we can produce shorter code.
124 */
125static size_t
126imm_size(int32_t v)
127{
128 if (v == (int8_t)v)
129 return sizeof(int8_t);
130 return sizeof(int32_t);
131}
132
133static void
134emit_bytes(struct bpf_jit_state *st, const uint8_t ins[], uint32_t sz)

Callers 10

emit_ror_immFunction · 0.85
emit_alu_immFunction · 0.85
emit_shift_immFunction · 0.85
emit_ld_regFunction · 0.85
emit_st_commonFunction · 0.85
emit_st_xaddFunction · 0.85
emit_abs_jmpFunction · 0.85
emit_abs_jccFunction · 0.85
emit_cmp_immFunction · 0.85
emit_tst_immFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected