Skip to content

feat(x86_64/uhyve): drop support for non-FDT TSC frequencies - #2592

Merged
mkroening merged 2 commits into
mainfrom
tsc-fdt-uhyve-only
Aug 3, 2026
Merged

feat(x86_64/uhyve): drop support for non-FDT TSC frequencies#2592
mkroening merged 2 commits into
mainfrom
tsc-fdt-uhyve-only

Conversation

@mkroening

Copy link
Copy Markdown
Member

This PR

  1. tries to read the TSC frequency from the FDT on Uhyve and
  2. drops support for non-FDT Uhyve TSC frequencies.

The second commit makes the kernel guess a wrong frequency on pre-hermit-os/uhyve@e4fb46f builds of Uhyve. Uhyve 0.5.0 (Feb 2025) or newer are unaffected.

This PR is a step towards #2546.

@mkroening
mkroening requested a review from jounathaen August 2, 2026 17:00
@mkroening mkroening self-assigned this Aug 2, 2026
@mkroening
mkroening force-pushed the tsc-fdt-uhyve-only branch from 70be23b to 2f2f65a Compare August 2, 2026 17:03

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Benchmark Results

Details
Benchmark Current: dee78ed Previous: 2e23902 Performance Ratio
startup_benchmark Build Time 82.04 s 80.34 s 1.02
startup_benchmark File Size 0.79 MB 0.80 MB 0.99
Startup Time - 1 core 0.75 s (±0.02 s) 0.75 s (±0.02 s) 1.01
Startup Time - 2 cores 0.75 s (±0.02 s) 0.74 s (±0.02 s) 1.03
Startup Time - 4 cores 0.76 s (±0.02 s) 0.74 s (±0.02 s) 1.02
multithreaded_benchmark Build Time 81.40 s 82.11 s 0.99
multithreaded_benchmark File Size 0.90 MB 0.86 MB 1.05
Multithreaded Pi Efficiency - 2 Threads 90.83 % (±8.72 %) 85.89 % (±6.61 %) 1.06
Multithreaded Pi Efficiency - 4 Threads 44.23 % (±3.59 %) 43.43 % (±2.56 %) 1.02
Multithreaded Pi Efficiency - 8 Threads 25.89 % (±1.86 %) 25.76 % (±1.53 %) 1.01
micro_benchmarks Build Time 78.55 s 80.40 s 0.98
micro_benchmarks File Size 0.90 MB 0.86 MB 1.05
Scheduling time - 1 thread 64.43 ticks (±2.33 ticks) 62.65 ticks (±4.06 ticks) 1.03
Scheduling time - 2 threads 34.09 ticks (±3.92 ticks) 34.08 ticks (±4.10 ticks) 1.00
Micro - Time for syscall (getpid) 4.00 ticks (±0.59 ticks) 3.45 ticks (±0.58 ticks) 1.16
Memcpy speed - (built_in) block size 4096 82942.34 MByte/s (±57442.13 MByte/s) 82448.38 MByte/s (±56997.13 MByte/s) 1.01
Memcpy speed - (built_in) block size 1048576 30483.05 MByte/s (±24491.35 MByte/s) 30585.98 MByte/s (±24707.84 MByte/s) 1.00
Memcpy speed - (built_in) block size 16777216 29308.18 MByte/s (±24063.15 MByte/s) 26340.06 MByte/s (±21720.96 MByte/s) 1.11
Memset speed - (built_in) block size 4096 83254.84 MByte/s (±57657.41 MByte/s) 82292.76 MByte/s (±56891.50 MByte/s) 1.01
Memset speed - (built_in) block size 1048576 31235.93 MByte/s (±24944.83 MByte/s) 31323.85 MByte/s (±25145.86 MByte/s) 1.00
Memset speed - (built_in) block size 16777216 30095.88 MByte/s (±24529.64 MByte/s) 27104.68 MByte/s (±22209.94 MByte/s) 1.11
Memcpy speed - (rust) block size 4096 73966.81 MByte/s (±51683.06 MByte/s) 74097.96 MByte/s (±51811.44 MByte/s) 1.00
Memcpy speed - (rust) block size 1048576 30219.19 MByte/s (±24410.81 MByte/s) 30361.60 MByte/s (±24602.37 MByte/s) 1.00
Memcpy speed - (rust) block size 16777216 29297.00 MByte/s (±24059.84 MByte/s) 27625.34 MByte/s (±22806.88 MByte/s) 1.06
Memset speed - (rust) block size 4096 74459.81 MByte/s (±52048.89 MByte/s) 74373.47 MByte/s (±51976.48 MByte/s) 1.00
Memset speed - (rust) block size 1048576 30972.29 MByte/s (±24862.29 MByte/s) 31110.89 MByte/s (±25033.24 MByte/s) 1.00
Memset speed - (rust) block size 16777216 30075.23 MByte/s (±24518.93 MByte/s) 28386.93 MByte/s (±23265.03 MByte/s) 1.06
alloc_benchmarks Build Time 77.80 s 74.76 s 1.04
alloc_benchmarks File Size 0.87 MB 0.87 MB 0.99
Allocations - Allocation success 91.31 % 91.31 % 1
Allocations - Deallocation success 100.00 % 100.00 % 1
Allocations - Pre-fail Allocations 61.44 % 61.44 % 1
Allocations - Average Allocation time 4491.22 Ticks (±77.85 Ticks) 5860.58 Ticks (±98.43 Ticks) 0.77
Allocations - Average Allocation time (no fail) 5309.70 Ticks (±88.80 Ticks) 6554.81 Ticks (±92.86 Ticks) 0.81
Allocations - Average Deallocation time 1305.57 Ticks (±168.00 Ticks) 1805.01 Ticks (±250.35 Ticks) 0.72
mutex_benchmark Build Time 78.53 s 79.82 s 0.98
mutex_benchmark File Size 0.90 MB 0.86 MB 1.05
Mutex Stress Test Average Time per Iteration - 1 Threads 12.20 ns (±0.57 ns) 12.10 ns (±0.41 ns) 1.01
Mutex Stress Test Average Time per Iteration - 2 Threads 39.52 ns (±2.36 ns) 40.26 ns (±1.68 ns) 0.98

This comment was automatically generated by workflow using github-action-benchmark.

@mkroening

Copy link
Copy Markdown
Member Author

I'll approve this myself, since we don't seem to have any compatibility with pre-0.9.1 versions anyway.

@mkroening
mkroening added this pull request to the merge queue Aug 3, 2026
Merged via the queue into main with commit 59c312b Aug 3, 2026
21 checks passed
@mkroening
mkroening deleted the tsc-fdt-uhyve-only branch August 3, 2026 08:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant