Home
last modified time | relevance | path

Searched refs:helpers (Results 1 – 13 of 13) sorted by relevance

/DragonOS/kernel/crates/rbpf/examples/
H A Duptime.rs5 use rbpf::helpers;
26 let hkey = helpers::BPF_KTIME_GETNS_IDX as u8; in main()
51 vm.register_helper(helpers::BPF_KTIME_GETNS_IDX, helpers::bpf_time_getns) in main()
H A Dload_elf.rs10 use rbpf::helpers;
93 vm.register_helper(helpers::BPF_TRACE_PRINTK_IDX, helpers::bpf_trace_printf) in main()
H A Dhelper.rs2 rbpf::helpers::show_helper(); in main()
/DragonOS/kernel/crates/rbpf/src/
H A Dlib.rs43 pub mod helpers; module
123 helpers: HashMap<u32, ebpf::Helper>, field
154 helpers: HashMap::new(), in new()
258 self.helpers.insert(key, function); in register_helper()
299 interpreter::execute_program(self.prog, mem, mbuff, &self.helpers) in execute_program()
330 self.jit = Some(jit::JitMemory::new(prog, &self.helpers, true, false)?); in jit_compile()
450 let mut compiler = CraneliftCompiler::new(self.helpers.clone()); in cranelift_compile()
848 self.parent.jit = Some(jit::JitMemory::new(prog, &self.parent.helpers, true, true)?); in jit_compile()
962 let mut compiler = CraneliftCompiler::new(self.parent.helpers.clone()); in cranelift_compile()
1208 helpers: &HashMap<u32, fn(u64, u64, u64, u64, u64) -> u64>, in register_helper_set()
[all …]
H A Dcranelift.rs39 helpers: HashMap<u32, ebpf::Helper>, field
61 pub(crate) fn new(helpers: HashMap<u32, ebpf::Helper>) -> Self { in new()
80 for (k, v) in helpers.iter() { in new()
96 helpers, in new()
179 for (k, _) in self.helpers.iter() { in build_function_prelude()
H A Djit.rs479 helpers: &HashMap<u32, ebpf::Helper>, in jit_compile()
895 if let Some(helper) = helpers.get(&(insn.imm as u32)) { in jit_compile()
987 helpers: &HashMap<u32, ebpf::Helper>, in new()
1013 jit.jit_compile(&mut mem, prog, use_mbuff, update_data_ptr, helpers)?; in new()
H A Dinterpreter.rs10 helpers::BPF_FUNC_MAPPER,
87 helpers: &HashMap<u32, ebpf::Helper>, in execute_program()
640 if let Some(function) = helpers.get(&(insn.imm as u32)) { in execute_program()
/DragonOS/docs/kernel/trace/
H A DeBPF.md301 // Map helpers::Generic map helpers
309 // Map helpers::Perf event array helpers
311 // Probe and trace helpers::Memory helpers
313 // Print helpers
316 // Map helpers::Queue and stack helpers
/DragonOS/kernel/crates/rbpf/tests/
H A Dcranelift.rs9 use rbpf::{assembler::assemble, helpers};
274 vm.register_helper(0, helpers::gather_bytes).unwrap(); in test_cranelift_call()
313 vm.register_helper(1, helpers::memfrob).unwrap(); in test_cranelift_call_memfrob()
1778 vm.register_helper(0, helpers::gather_bytes).unwrap(); in test_cranelift_stack2()
1779 vm.register_helper(1, helpers::memfrob).unwrap(); in test_cranelift_stack2()
1854 vm.register_helper(4, helpers::strcmp).unwrap(); in test_cranelift_string_stack()
H A Dmisc.rs23 use rbpf::helpers;
150 vm.register_helper(helpers::BPF_TRACE_PRINTK_IDX, helpers::bpf_trace_printf) in test_vm_block_port()
216 vm.register_helper(helpers::BPF_TRACE_PRINTK_IDX, helpers::bpf_trace_printf) in test_jit_block_port()
H A Dubpf_jit_x86_64.rs26 use rbpf::{assembler::assemble, helpers};
350 vm.register_helper(0, helpers::gather_bytes).unwrap(); in test_jit_call()
372 vm.register_helper(1, helpers::memfrob).unwrap(); in test_jit_call_memfrob()
2462 vm.register_helper(0, helpers::gather_bytes).unwrap(); in test_jit_stack2()
2463 vm.register_helper(1, helpers::memfrob).unwrap(); in test_jit_stack2()
2558 vm.register_helper(4, helpers::strcmp).unwrap(); in test_jit_string_stack()
H A Dubpf_vm.rs25 use rbpf::{assembler::assemble, helpers};
365 vm.register_helper(0, helpers::gather_bytes).unwrap(); in test_vm_call()
384 vm.register_helper(1, helpers::memfrob).unwrap(); in test_vm_call_memfrob()
2281 vm.register_helper(0, helpers::gather_bytes).unwrap(); in test_vm_stack2()
2282 vm.register_helper(1, helpers::memfrob).unwrap(); in test_vm_stack2()
2385 vm.register_helper(4, helpers::strcmp).unwrap(); in test_vm_string_stack()
/DragonOS/kernel/crates/rbpf/
H A DREADME.md399 use rbpf::helpers;
454 vm.register_helper(helpers::BPF_TRACE_PRINTK_IDX,
455 helpers::bpf_trace_printf).unwrap();
640 a high number of helpers, several kinds of maps, tail calls.
642 * Additional helpers should be easy to add, but very few of the existing Linux
643 helpers have been replicated in rbpf so far.
648 * The interaction with maps is done through the use of specific helpers, so
694 * Add helpers (some of those supported in the kernel, such as checksum update,