No. 128 / project of 147 on the ladder

Scheduler queue/lifetime depth

introduces — per-class shadow scheduler queues; queue occupancy counters; scheduler lifetime measurement

harden statelast run2026-05-06
signoff
  • DRCNOT RUN
  • LVSNOT RUN
  • antennaNOT RUN

P128 keeps P127’s scheduler ready-mask counters and adds a second shadow model: tiny per-class queues for integer, memory, and control work. Each queue has capacity 4. The real core still runs the same in-order FSM.

checkresult
Verilator buildPASS
BusyBox shell workload reaches P128-FILE-OKPASS
Queue-lifetime counters emittedPASS
Hardened layoutNOT RUN
queue counterintegermemorycontrol
enqueues9,815,3023,250,1596,287,452
drains9,815,3023,250,0966,287,452
full drops000
max occupancy111
queue ready-mask countervalue
samples43,664,857
single ready43,664,857
dual ready0
triple ready0
integer ready21,102,727
memory ready9,987,226
control ready12,574,904
two-issue opportunity cycles0
three-issue opportunity cycles0
trap flush clears62
metricP127P128
post-load cycles218,572,787218,746,401
shell window cycles64,621,34664,776,985
retired instructions86,294,69386,351,273
CPI2.53292.5332
S_FETCH cycles7,625,1567,627,087
S_MEM cycles27,732,09427,750,591

This is a sharper negative result than P127. The queues accept and drain millions of records, but every class reaches only occupancy 1 and no sampled cycle has two classes ready. Adding capacity did not create coexistence because modeled arrival and one-lane backend service are still coupled to the serialized backend.

P129 should therefore model scheduler arrival and service as separate contracts before any real multi-issue selector.

shell phases label P128 shell workload cycles 218,746,401 cpi 2.53
  1. kernel banner to /init 116,720,295 53.5%
  2. /init to shell banner 1,081,639 0.5%
  3. shell banner to first command 35,539,415 16.3%
  4. echo command 1,649 0%
  5. uname -a 2,495,714 1.1%
  6. ls /bin /usr/share 31,842,293 14.6%
  7. cat sample file 3,169,008 1.5%
  8. touch/write/cat/rm /tmp file 10,942,283 5%
  9. 8x ash loop with file I/O 16,325,358 7.5%
  10. final marker 680 0%
state breakdown label P128 scheduler queue workload cycles 218,746,401 cpi 2.53
  1. fetch 3.5% 7,627,087
  2. execute 39.5% 86,376,051
  3. mem 12.8% 28,030,027
  4. walker 1.2% 2,687,978
  5. writeback 39.5% 86,351,273
  6. mul/div 3.5% 7,672,269