-
Notifications
You must be signed in to change notification settings - Fork 106
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
make proofs generic in maxIRQ and irq bit width #773
Commits on Jul 5, 2024
-
aarch64 machine+crefine: clear up irqInvalid confusion
- getActiveIRQ in machine/ was trying to ensure that we're not returning "Some Kernel_C.irqInvalid", but it was using the wrong value (0xFF), and Kernel_C.irqInvalid is not representable in the type getActiveIRQ returns, so nothing needs to be done here. This is a remnant of old ARM 32 bit proofs were irqInvalid was 0xFF. Even in those times, it would not have been needed, because on platforms that use 0xFF, we already know maxIRQ < 0xFF. - remove the lemmas in CRefine that were trying to make use of that obsolete check. It is obvious by type (and by simp) that Kernel_C.irqInvalid can't be returned, so none of them are needed on gic_v2/gic_v3 platforms. Signed-off-by: Gerwin Klein <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for bed780f - Browse repository at this point
Copy the full SHA bed780fView commit details -
arm machine+proof: treat irqInvalid abstractly
Signed-off-by: Gerwin Klein <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 3795ee5 - Browse repository at this point
Copy the full SHA 3795ee5View commit details -
arm-hyp machine+proof: treat irqInvalid abstractly
Signed-off-by: Gerwin Klein <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 9a568b5 - Browse repository at this point
Copy the full SHA 9a568b5View commit details -
word_lib: lemma on toEnum (ucast _)
Signed-off-by: Gerwin Klein <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 46170b5 - Browse repository at this point
Copy the full SHA 46170b5View commit details -
word_lib: more lemmas about mask
Signed-off-by: Gerwin Klein <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 7daf753 - Browse repository at this point
Copy the full SHA 7daf753View commit details -
lib: add variation on mod_less_eq_dividend
Signed-off-by: Gerwin Klein <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 973bc91 - Browse repository at this point
Copy the full SHA 973bc91View commit details -
cspec: remove duplicate keys in gen-config-thy.py
Signed-off-by: Gerwin Klein <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for a7001e5 - Browse repository at this point
Copy the full SHA a7001e5View commit details -
cspec: extract maxIRQ definition from platform_gen.h
For Arm platforms (32 and 64), maxIRQ is defined in platform_gen.h as an explicit number. Parse this number and emit in Kernel_Config.thy. For X64, the value is fixed and does not need to be generated. For RISCV64, the value is computed (by virtue of being the last constant in the enum) and extraction is more complex. Leaving it unimplemented for now. Signed-off-by: Gerwin Klein <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 380f108 - Browse repository at this point
Copy the full SHA 380f108View commit details -
arm+arm-hyp+aarch64 spec: use maxIRQ from Kernel_Config
Signed-off-by: Gerwin Klein <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for b3f1326 - Browse repository at this point
Copy the full SHA b3f1326View commit details -
cspec: extract irqBits from platform_gen.h
Extract the value of IRQ_CNODE_SLOT_BITS into Kernel_Config.irqBits, for later use in value_type to define irq_len and the irq type. Signed-off-by: Gerwin Klein <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for cfa2c2c - Browse repository at this point
Copy the full SHA cfa2c2cView commit details -
machine+design: use irqBits for ASpec irq type
Define irq_len and the irq type in terms of Kernel_Config.irqBits for Arm and RISC-V platforms (fixed on X64). Use that type in ASpec via machine/L4V_ARCH/Platform.thy. Signed-off-by: Gerwin Klein <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 4840ea4 - Browse repository at this point
Copy the full SHA 4840ea4View commit details -
machine: make int_word available on all arches
Consistently make `int_word` available on all architectures for the word type that corresponds to a plain `int` in C for that architecture. All unadorned C numerals are of this type. This name can now be used generically in the rest of the proofs. Signed-off-by: Gerwin Klein <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 5f3ddd5 - Browse repository at this point
Copy the full SHA 5f3ddd5View commit details -
aarch64 machine+ainvs+refine+crefine: make proofs generic in maxIRQ
- Kernel_Config lemmas for maxIRQ - remove all unfoldings of maxIRQ_def - use Arch_Kernel_Config lemmas for maxIRQ for array guards and other proof obligations. Signed-off-by: Gerwin Klein <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 2b6b02f - Browse repository at this point
Copy the full SHA 2b6b02fView commit details -
arm+arm-hyp machine+proof: make proofs generic in maxIRQ
- add Kernel_Config lemmas for maxIRQ - use irq and irq_len types instead of magic type numbers - use Kernel_Config.maxIRQ where possible instead of numbers - avoid unfoldings of Kernel_Config.maxIRQ and Kernel_C.maxIRQ Signed-off-by: Gerwin Klein <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 65c25df - Browse repository at this point
Copy the full SHA 65c25dfView commit details -
x64 machine+crefine: reduce magic numbers
Give names to irq bith width, size of IRQ array, and size of interrupt state array. Since there is no Kernel_Config.maxIRQ on X64, use Kernel_C.maxIRQ where necessary. Signed-off-by: Gerwin Klein <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 1a44075 - Browse repository at this point
Copy the full SHA 1a44075View commit details -
riscv crefine: reduce magic numbers
Define size of IRQ array and interrupt state array symbolically. Signed-off-by: Gerwin Klein <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 37e0bdd - Browse repository at this point
Copy the full SHA 37e0bddView commit details -
aarch64 crefine: make proof generic in irq type size
It turns out that there are platforms with 8-bit wide IRQ types on AArch64. This means we need the same kind of invariant for VPPIEvent fault here as we have in ARM_HYP, saying that VPPIEvent only stores IRQs up to the IRQ bit width, even though the C declares a potentially wider type. Signed-off-by: Gerwin Klein <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 13e6d82 - Browse repository at this point
Copy the full SHA 13e6d82View commit details -
proof/Makefile: declare InfoFlowCBase dependencies
Signed-off-by: Gerwin Klein <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 4a9a6c6 - Browse repository at this point
Copy the full SHA 4a9a6c6View commit details