NIKSS-vSwitch / nikss

Native In-Kernel P4-programmable Software Switch for Software-Defined Networking (previously PSA-eBPF)
Apache License 2.0
48 stars 4 forks source link

Improve performance of meter extern #100

Open tatry opened 1 year ago

tatry commented 1 year ago

Current implementation of meter use bpf helper BPF_FUNC_ktime_get_ns which can be quite slow.

To get rid of the helper, daemon process can be added which regularly updates array map with current time. Such daemon would be implemented using bpf prog type BPF_PROG_TYPE_PERF_EVENT .

Question is if we need such optimization?