Files
LithosAnanake/capsules/BLOCK_MAP.md
T
Robert Allan JamesandClaude Sonnet 5 43aa0a2a36 aarch64: arm the ARM Generic Timer -- CNTP/CNTHP TVAL+CTL, per-tick re-arm
Punch list §25 item 0.7 complete. This is what finally makes items 0.5 and
0.6 provably work end to end.

apic_timer_start(): writes CNTP_TVAL_EL0 (or CNTHP_TVAL_EL2 at EL2 --
aarch64_current_el(), same EL-aware discipline as 0.4-0.6) to
s_timer_period_tsc, then CTL.ENABLE=1/IMASK=0, followed by an ISB. The ISB
is not decorative: confirmed against Linux's own arch_timer_reg_write_cp15()
(arch/arm64/include/asm/arch_timer.h) that only the *control* register write
needs synchronising before the enable/mask state is guaranteed visible to
the interrupt pipeline -- TVAL/CVAL writes do not carry the same
requirement, which is why apic_timer_rearm() omits it.

TVAL is architecturally 32-bit but MSR-to-system-register is always a
64-bit instruction form -- passing a uint32_t operand directly failed to
build (-Wasm-operand-widths). Fixed by truncating to 32 bits ourselves then
zero-extending back to 64 for the operand, which supplies explicit,
provably-correct zeros in the RES0 upper field rather than depending on
unverified hardware behaviour -- Linux's own driver never exercises this
path (it always uses the 64-bit CVAL form instead), so there was no local
source to confirm the alternative against.

apic_timer_rearm() (new): re-writes TVAL only, no ISB needed. TVAL is
relative to "now," not an absolute deadline like riscv64's SBI interface
(item 0.3), so there is no drift-correction bookkeeping -- each write means
"N ticks from this instant." Wired into aarch64_irq_handler() and called
*first*, before heartbeat_tick(), matching riscv64_timer_rearm()'s ordering
discipline exactly: the ARM Generic Timer does not auto-reload, so a return
path that skips this leaves the interrupt condition latched, which the GIC
would redeliver the instant it's EOI'd -- a real storm, the same class of
failure item 0.6's verification investigated (and that time found absent,
because nothing was armed yet).

Verified: builds clean; every generated instruction checked against
disassembly, not just reviewed by eye (both EL branches, correct TVAL/CTL
register names, single shared ISB in apic_timer_start(), no ISB in
apic_timer_rearm()). Boots to ok> with no regression, dict_hash
0x3d4e1daf289da94f unchanged.

Rate measured directly against real wall-clock time via QEMU's own -d int
trap trace (same method as riscv64's item 0.3), two independent windows:
1,090 interrupts over 11.05 s (98.679 Hz) and 4,031 over 40.88 s (98.614 Hz)
-- consistent across both, so this is a real, small, systematic bias
(~1.3-1.4% slow), not measurement noise from polling granularity, which
would have shrunk with the longer window and did not. Attributed to genuine
per-interrupt service latency: TVAL is rewritten mid-ISR, so the trampoline
save/restore, GICC_IAR read, EL branch and GICC_EOIR write all lengthen the
effective period slightly versus the nominal 10 ms, inherent to any
relative-countdown re-arm scheme. Reported as measured, not smoothed over.
The interrupt sustained continuously across both windows with no stall and
no storm, which is the primary evidence re-arm-every-tick is correct;
the small rate bias is overhead, not a defect.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-03 22:14:52 -04:00

226 lines
12 KiB
Markdown

# Capsule Block Manifest — Auto-generated
<!-- Generated by mkcapsule --manifest 2026-08-04T02:14:10Z -->
<!-- DO NOT EDIT — re-run mkcapsule --manifest to refresh. -->
<!-- Hand-written justifications and immutability notes live -->
<!-- in MANIFEST.md alongside this auto-generated index. -->
## Capsule Summary
| Capsule | Blocks claimed | xxHash64 |
|---------|----------------|----------|
| `ACL.4th` | 4000, 4001, 4002, 4003, 4004, 4005, 4006, 4007, 4015 | `0xd781d22148ff171d` |
| `artemis:init.4th` | 4110, 4111, 4112, 4113, 4122, 4123, 4124, 4125, 4126, 4127, 4128, 4129, 4130, 4131, 4132, 4133, 4134, 4135, 4136, 4137, 4138, 4139, 4140, 4141, 4160, 4161, 4162, 4163, 4164, 4165, 4166, 4167, 4168, 4169, 4170, 4171, 4172, 4173, 4174, 4851, 4852 | `0xc9e92cd18f4c7b49` |
| `common:msg.4th` | 4055 | `0xa99c5bcd3877f80e` |
| `doe-campaign.4th` | 4060, 4061, 4062, 4063, 4064, 4065 | `0x3d4549142d91ec20` |
| `doe.4th` | 2100, 2101, 2102, 2103, 2104, 2105, 2106, 2107 | `0xb6ecf5374e8ee77c` |
| `hermes:init.4th` | 4100, 4101, 4102, 4103, 4104, 4105, 4106, 4107, 4108, 4109, 4114, 4115, 4116, 4117, 4118, 4119, 4120, 4121, 4142, 4143, 4144, 4145, 4146, 4147, 4148, 4149, 4150, 4151, 4152, 4153 | `0xbb77f3ac463f507f` |
| `init-0.4th` | 2200, 2201 | `0xd0a9550baf786bb3` |
| `init-1.4th` | 4406, 4415, 4425, 4435 | `0x63e251adb0a03613` |
| `init-2.4th` | 4506, 4515, 4525, 4535, 4545 | `0xf113b3d0bcccae47` |
| `init-3.4th` | 4606, 4615, 4625, 4635, 4645, 4655, 4665 | `0x62b7a71576ad1041` |
| `init-4.4th` | 2130, 2131, 2132 | `0x89e3ef1db5ac0627` |
| `init-5.4th` | *(none — raw code capsule)* | `0xda0c179af10a46a9` |
| `init-6.4th` | 2080, 2081, 2082, 2083, 2084, 2085, 2086, 2087, 2088, 2089, 2090, 2091, 2092, 2093, 2094, 2095 | `0x06fc0ce1e369ef5a` |
| `init-7.4th` | 2150 | `0xb88df2efeb753d64` |
| `init-8.4th` | 2160 | `0x714746312b72f83d` |
| `init-9.4th` | 4706, 4715, 4725, 4735, 4745 | `0x3f2bec73142aa424` |
| `init-l8-diverse.4th` | 4820, 4821, 4822 | `0xaa293201a6c91838` |
| `init-l8-omni.4th` | 2064, 2065, 2066, 2067, 2068, 2069, 2070, 2071, 2072, 2073, 2074, 2075, 2076, 2077, 2078, 2079 | `0x5979e314d6452045` |
| `init-l8-stable.4th` | 4806 | `0xdc3830f189063a9a` |
| `init-l8-temporal.4th` | 4830, 4831 | `0x51abd4c138246651` |
| `init-l8-transition.4th` | 4840, 4841, 4842 | `0xbcc1a81976f0a4c9` |
| `init-l8-volatile.4th` | 4810, 4811, 4812, 4813 | `0x98caabbbd92abac4` |
| `init.4th` | 2049, 2050, 2057 | `0xb4c4b5559146a3bd` |
| `lib.4th` | 4050 | `0x20625ebf1276c239` |
| `process.4th` | 4300, 4301 | `0x781afc1dbd0294f7` |
| `zuse.4th` | 4016, 4017, 4018 | `0x12f38ec782434a77` |
## Block Map (sorted by LBN)
| LBN | Capsule | xxHash64 | Status |
|-----|---------|----------|--------|
| 2049 | `init.4th` | `0xb4c4b5559146a3bd` | ok |
| 2050 | `init.4th` | `0xb4c4b5559146a3bd` | ok |
| 2057 | `init.4th` | `0xb4c4b5559146a3bd` | ok |
| 2064 | `init-l8-omni.4th` | `0x5979e314d6452045` | ok |
| 2065 | `init-l8-omni.4th` | `0x5979e314d6452045` | ok |
| 2066 | `init-l8-omni.4th` | `0x5979e314d6452045` | ok |
| 2067 | `init-l8-omni.4th` | `0x5979e314d6452045` | ok |
| 2068 | `init-l8-omni.4th` | `0x5979e314d6452045` | ok |
| 2069 | `init-l8-omni.4th` | `0x5979e314d6452045` | ok |
| 2070 | `init-l8-omni.4th` | `0x5979e314d6452045` | ok |
| 2071 | `init-l8-omni.4th` | `0x5979e314d6452045` | ok |
| 2072 | `init-l8-omni.4th` | `0x5979e314d6452045` | ok |
| 2073 | `init-l8-omni.4th` | `0x5979e314d6452045` | ok |
| 2074 | `init-l8-omni.4th` | `0x5979e314d6452045` | ok |
| 2075 | `init-l8-omni.4th` | `0x5979e314d6452045` | ok |
| 2076 | `init-l8-omni.4th` | `0x5979e314d6452045` | ok |
| 2077 | `init-l8-omni.4th` | `0x5979e314d6452045` | ok |
| 2078 | `init-l8-omni.4th` | `0x5979e314d6452045` | ok |
| 2079 | `init-l8-omni.4th` | `0x5979e314d6452045` | ok |
| 2080 | `init-6.4th` | `0x06fc0ce1e369ef5a` | ok |
| 2081 | `init-6.4th` | `0x06fc0ce1e369ef5a` | ok |
| 2082 | `init-6.4th` | `0x06fc0ce1e369ef5a` | ok |
| 2083 | `init-6.4th` | `0x06fc0ce1e369ef5a` | ok |
| 2084 | `init-6.4th` | `0x06fc0ce1e369ef5a` | ok |
| 2085 | `init-6.4th` | `0x06fc0ce1e369ef5a` | ok |
| 2086 | `init-6.4th` | `0x06fc0ce1e369ef5a` | ok |
| 2087 | `init-6.4th` | `0x06fc0ce1e369ef5a` | ok |
| 2088 | `init-6.4th` | `0x06fc0ce1e369ef5a` | ok |
| 2089 | `init-6.4th` | `0x06fc0ce1e369ef5a` | ok |
| 2090 | `init-6.4th` | `0x06fc0ce1e369ef5a` | ok |
| 2091 | `init-6.4th` | `0x06fc0ce1e369ef5a` | ok |
| 2092 | `init-6.4th` | `0x06fc0ce1e369ef5a` | ok |
| 2093 | `init-6.4th` | `0x06fc0ce1e369ef5a` | ok |
| 2094 | `init-6.4th` | `0x06fc0ce1e369ef5a` | ok |
| 2095 | `init-6.4th` | `0x06fc0ce1e369ef5a` | ok |
| 2100 | `doe.4th` | `0xb6ecf5374e8ee77c` | ok |
| 2101 | `doe.4th` | `0xb6ecf5374e8ee77c` | ok |
| 2102 | `doe.4th` | `0xb6ecf5374e8ee77c` | ok |
| 2103 | `doe.4th` | `0xb6ecf5374e8ee77c` | ok |
| 2104 | `doe.4th` | `0xb6ecf5374e8ee77c` | ok |
| 2105 | `doe.4th` | `0xb6ecf5374e8ee77c` | ok |
| 2106 | `doe.4th` | `0xb6ecf5374e8ee77c` | ok |
| 2107 | `doe.4th` | `0xb6ecf5374e8ee77c` | ok |
| 2130 | `init-4.4th` | `0x89e3ef1db5ac0627` | ok |
| 2131 | `init-4.4th` | `0x89e3ef1db5ac0627` | ok |
| 2132 | `init-4.4th` | `0x89e3ef1db5ac0627` | ok |
| 2150 | `init-7.4th` | `0xb88df2efeb753d64` | ok |
| 2160 | `init-8.4th` | `0x714746312b72f83d` | ok |
| 2200 | `init-0.4th` | `0xd0a9550baf786bb3` | ok |
| 2201 | `init-0.4th` | `0xd0a9550baf786bb3` | ok |
| 4000 | `ACL.4th` | `0xd781d22148ff171d` | ok |
| 4001 | `ACL.4th` | `0xd781d22148ff171d` | ok |
| 4002 | `ACL.4th` | `0xd781d22148ff171d` | ok |
| 4003 | `ACL.4th` | `0xd781d22148ff171d` | ok |
| 4004 | `ACL.4th` | `0xd781d22148ff171d` | ok |
| 4005 | `ACL.4th` | `0xd781d22148ff171d` | ok |
| 4006 | `ACL.4th` | `0xd781d22148ff171d` | ok |
| 4007 | `ACL.4th` | `0xd781d22148ff171d` | ok |
| 4015 | `ACL.4th` | `0xd781d22148ff171d` | ok |
| 4016 | `zuse.4th` | `0x12f38ec782434a77` | ok |
| 4017 | `zuse.4th` | `0x12f38ec782434a77` | ok |
| 4018 | `zuse.4th` | `0x12f38ec782434a77` | ok |
| 4050 | `lib.4th` | `0x20625ebf1276c239` | ok |
| 4055 | `common:msg.4th` | `0xa99c5bcd3877f80e` | ok |
| 4060 | `doe-campaign.4th` | `0x3d4549142d91ec20` | ok |
| 4061 | `doe-campaign.4th` | `0x3d4549142d91ec20` | ok |
| 4062 | `doe-campaign.4th` | `0x3d4549142d91ec20` | ok |
| 4063 | `doe-campaign.4th` | `0x3d4549142d91ec20` | ok |
| 4064 | `doe-campaign.4th` | `0x3d4549142d91ec20` | ok |
| 4065 | `doe-campaign.4th` | `0x3d4549142d91ec20` | ok |
| 4100 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4101 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4102 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4103 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4104 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4105 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4106 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4107 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4108 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4109 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4110 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4111 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4112 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4113 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4114 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4115 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4116 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4117 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4118 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4119 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4120 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4121 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4122 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4123 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4124 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4125 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4126 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4127 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4128 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4129 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4130 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4131 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4132 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4133 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4134 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4135 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4136 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4137 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4138 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4139 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4140 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4141 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4142 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4143 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4144 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4145 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4146 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4147 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4148 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4149 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4150 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4151 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4152 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4153 | `hermes:init.4th` | `0xbb77f3ac463f507f` | ok |
| 4160 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4161 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4162 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4163 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4164 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4165 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4166 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4167 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4168 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4169 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4170 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4171 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4172 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4173 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4174 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4300 | `process.4th` | `0x781afc1dbd0294f7` | ok |
| 4301 | `process.4th` | `0x781afc1dbd0294f7` | ok |
| 4406 | `init-1.4th` | `0x63e251adb0a03613` | ok |
| 4415 | `init-1.4th` | `0x63e251adb0a03613` | ok |
| 4425 | `init-1.4th` | `0x63e251adb0a03613` | ok |
| 4435 | `init-1.4th` | `0x63e251adb0a03613` | ok |
| 4506 | `init-2.4th` | `0xf113b3d0bcccae47` | ok |
| 4515 | `init-2.4th` | `0xf113b3d0bcccae47` | ok |
| 4525 | `init-2.4th` | `0xf113b3d0bcccae47` | ok |
| 4535 | `init-2.4th` | `0xf113b3d0bcccae47` | ok |
| 4545 | `init-2.4th` | `0xf113b3d0bcccae47` | ok |
| 4606 | `init-3.4th` | `0x62b7a71576ad1041` | ok |
| 4615 | `init-3.4th` | `0x62b7a71576ad1041` | ok |
| 4625 | `init-3.4th` | `0x62b7a71576ad1041` | ok |
| 4635 | `init-3.4th` | `0x62b7a71576ad1041` | ok |
| 4645 | `init-3.4th` | `0x62b7a71576ad1041` | ok |
| 4655 | `init-3.4th` | `0x62b7a71576ad1041` | ok |
| 4665 | `init-3.4th` | `0x62b7a71576ad1041` | ok |
| 4706 | `init-9.4th` | `0x3f2bec73142aa424` | ok |
| 4715 | `init-9.4th` | `0x3f2bec73142aa424` | ok |
| 4725 | `init-9.4th` | `0x3f2bec73142aa424` | ok |
| 4735 | `init-9.4th` | `0x3f2bec73142aa424` | ok |
| 4745 | `init-9.4th` | `0x3f2bec73142aa424` | ok |
| 4806 | `init-l8-stable.4th` | `0xdc3830f189063a9a` | ok |
| 4810 | `init-l8-volatile.4th` | `0x98caabbbd92abac4` | ok |
| 4811 | `init-l8-volatile.4th` | `0x98caabbbd92abac4` | ok |
| 4812 | `init-l8-volatile.4th` | `0x98caabbbd92abac4` | ok |
| 4813 | `init-l8-volatile.4th` | `0x98caabbbd92abac4` | ok |
| 4820 | `init-l8-diverse.4th` | `0xaa293201a6c91838` | ok |
| 4821 | `init-l8-diverse.4th` | `0xaa293201a6c91838` | ok |
| 4822 | `init-l8-diverse.4th` | `0xaa293201a6c91838` | ok |
| 4830 | `init-l8-temporal.4th` | `0x51abd4c138246651` | ok |
| 4831 | `init-l8-temporal.4th` | `0x51abd4c138246651` | ok |
| 4840 | `init-l8-transition.4th` | `0xbcc1a81976f0a4c9` | ok |
| 4841 | `init-l8-transition.4th` | `0xbcc1a81976f0a4c9` | ok |
| 4842 | `init-l8-transition.4th` | `0xbcc1a81976f0a4c9` | ok |
| 4851 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
| 4852 | `artemis:init.4th` | `0xc9e92cd18f4c7b49` | ok |
## Conflicts
None.
---
*26 capsule(s) scanned. Re-run `mkcapsule --manifest <dir>` to refresh.*