Function report | 
Source Code:kernel\bpf\arraymap.c | 
Create Date:2022-07-28 13:11:05 | 
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick | 
| home page | Tree | 
| Annotation kernel can get tool activity | Download SCCT | Chinese | 
Name:mit BPF instructions equivalent to C code of array_map_lookup_elem()
Proto:static u32 array_map_gen_lookup(struct bpf_map *map, struct bpf_insn *insn_buf)
Type:u32
Parameter:
| Type | Parameter | Name | 
|---|---|---|
| struct bpf_map * | map | |
| struct bpf_insn * | insn_buf | 
| 220 | insn++ = ALU ops on immediates, bpf_add|sub|...: dst_reg += imm32 (BPF_ADD, map_ptr, offsetof(structbpf_array, value)) | 
| 221 | insn++ = Memory load, dst_reg = *(uint *) (src_reg + off16) (32-bit , ret, index, 0) | 
| 222 | If unpriv_array Then | 
| 223 | insn++ = Conditional jumps against immediates, if (dst_reg 'op' imm32) goto pc + off16 (BPF_JGE, ret, max_entries, 4) | 
| 224 | insn++ = BPF_ALU32_IMM(BPF_AND, ret, index_mask) | 
| 225 | Else | 
| 231 | Else | 
| 235 | insn++ = Conditional jumps against immediates, if (dst_reg 'op' imm32) goto pc + off16 (BPF_JA, 0, 0, 1) | 
| 236 | insn++ = Short form of mov, dst_reg = imm32 (ret, 0) | 
| Source code conversion tool public plug-in interface  | X | 
|---|---|
| Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion  |