smp: remove sched context rebind
Remove unnecessary unbind/rebind. Unbinding and binding the sched context doesn’t reset anything that has not already been reset by the TCB_Suspend calls before (e.g. removal from queues).
Signed-off-by: Gerwin Klein gerwin.klein@proofcraft.systems
版权所有:中国计算机学会技术支持:开源发展技术委员会
京ICP备13000930号-9
京公网安备 11010802047560号
The sel4bench repository
sel4bench is a benchmarking applications and support library for seL4.
To work with this project, check out the project manifest.
For past and current data collected by these benchmarks on a variety of boards, see the repository seL4/sel4bench-results
For current results see also the performance page on the seL4 website.
Applications
This repository is structured as multiple separate applications which contain benchmarks for different paths in the kernel.
After finishing, the benchmark produces JSON output on stdout delimited by the strings
BEGIN JSON OUPUT,END JSON OUPUT.All benchmarks report mean, stddev, and n. Some benchmarks additionally produce a raw result array, and the statistics data min, max, median, Q1, and Q3.
sel4bench
This is the driver application: it launches each benchmark in a separate process and collects, processes, and outputs results.
ipc
This is a hot-cache benchmark of various IPC paths.
irquser
This is a hot-cache benchmark of various IRQ paths, measured from user space.
scheduler
This is a hot-cache benchmark for scheduling decisions. It works by using a producer/consumer pattern between two notification objects. This benchmark also measures
seL4_Yield().signal
This is a hot-cache benchmark of the signal paths in the kernel, measured from user space.
smp
This is an intra-core IPC round-trip benchmark to check overhead of kernel synchronisation on IPC throughput. It measures overall IPC throughput under different simulated workloads where each core makes same-core IPC calls. The expectation is that for light work loads the throughput scales linearly in the number of cores, and that for high workloads, there is a limit in the number of cores where the throughput no longer scales linearly because of kernel lock contention.
vcpu (AArch64 only)
This benchmark executes a thread as a VCPU (an EL1 guest kernel) and then obtains numbers for the following actions:
HVCinstruction.ERETinstruction.HVC.seL4_Call()from an EL1 guest thread to a native seL4 thread.seL4_Reply()from an seL4 native thread to an EL1 guest thread.Note: In order to run this benchmark, you must enable it at build time by passing
-DVCPU=trueon theinitorcmakecommand line, which will cause the kernel to be compiled to run in EL2. You must also ensure that you pass-DHARDWARE=falseto disable the hardware tests.Since this benchmark will cause the kernel image to be an EL2 image, it will have an impact on the observed numbers for the other benchmark applications as well. The overhead calculations and other assumptions other benchmarks are making may not be valid for EL2 kernels.
Adding a new benchmark
Contributing a new benchmark to seL4bench requires a few steps:
apps, create a directory for your new benchmark and:CMakelists.txtfile that defines a new executable.srcfolder that contains the source code for your benchmark.apps/sel4bench:CMakeLists.txtto add your new benchmark to the list of benchmarks.src:benchmark.hto include your generated config for your benchmark, and provide a function declaration that will act as the entry point for your benchmark.<benchmark_name>.cfile that implements the above function declaration. This function should return abenchmark_tstruct. Construct this struct accordingly. The struct expects a function to process the results of the benchmark, which you should provide in this file as wellmain.c, add your entry point function that was declared/defined above to the array ofbenchmark_tpresent.easy-settings.cmaketo add your new benchmark. You can define here whether the benchmark should be enabled by default or not.libsel4benchsupport/include:<benchmark_name.h>file that provides any extra definitions that your benchmark may need. You will also generally provide abenchmark_name_results_tstruct here, which will be used to store the results of your benchmark when processing.settings.cmaketo include your new benchmark.