Function report |
Source Code:lib\test_bpf.c |
Create Date:2022-07-28 06:26:59 |
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
| home page | Tree |
| Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:__bpf_fill_stxdw
Proto:static int __bpf_fill_stxdw(struct bpf_test *self, int size)
Type:int
Parameter:
| Type | Parameter | Name |
|---|---|---|
| struct bpf_test * | self | |
| int | size |
| 430 | len = BPF_MAXINSNS |
| 434 | insn = kmalloc_array - allocate memory for an array.*@n: number of elements.*@size: element size.*@flags: the type of memory to allocate (see kmalloc). |
| 438 | insn[0] = BPF_ALU32_IMM(mov reg to reg , Redefine REGs to make tests less verbose , 1) |
| 439 | insn[1] = Memory store, *(uint *) (dst_reg + off16) = imm32 (size, R10, - 40, 42) |
| 441 | When i < len - 2 cycle insn[i] = Atomic memory add, *(uint *)(dst_reg + off16) += src_reg (size, R10, Redefine REGs to make tests less verbose , - 40) |
| 444 | insn[len - 2] = Memory load, dst_reg = *(uint *) (src_reg + off16) (size, Redefine REGs to make tests less verbose , R10, - 40) |
| 445 | insn[len - 1] = Program exit () |
| 451 | Return 0 |
| Name | Describe |
|---|---|
| bpf_fill_stxw | |
| bpf_fill_stxdw |
| 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 |