Commit Graph

37 Commits

Author SHA1 Message Date
Gerwin Klein 314158480a
proof: update to Isabelle2023 mapsto syntax
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2023-10-06 14:41:41 +11:00
Corey Lewis 7999632872 proof: update for changes to nondet monad
Signed-off-by: Corey Lewis <corey.lewis@proofcraft.systems>
2023-10-05 11:24:05 +11:00
Gerwin Klein c1fe4ad10f
lib+refine: rename Corres_Method to CorresK_Method
This also renames most of the corres* methods to corresK* methods,
including corressimp -> corresKsimp.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2023-06-30 10:56:47 +10:00
Gerwin Klein e89813ecf2
proofs: updates for monad refactor
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2023-02-09 11:46:55 +11:00
Corey Lewis 7289575cc7 arm refine: update for changed corres split rules
Signed-off-by: Corey Lewis <corey.lewis@proofcraft.systems>
2022-10-20 08:59:52 +11:00
Corey Lewis 73a52be413 proof: change more simple corres split cases
perl -0777 -pi -e "s/corres_split_nor([\w'-]*) *\[ *OF +_ +([^_][\w'-]+) +([\w'-]+)/corres_split_nor\1\[OF \2 _ \3/g" **/*.thy
perl -0777 -pi -e 's/corres_split_nor([\w]?) *\[ *OF +_ +(?!_)/corres_split_nor\1\[OF /g' **/*.thy
perl -0777 -pi -e 's/corres_split_eqr([\w]?) *\[ *OF +_ +(?!_)/corres_split_eqr\1\[OF /g' **/*.thy
perl -0777 -pi -e 's/corres_split_mapr([\w]?) *\[ *OF +_ +(?!_)/corres_split_mapr\1\[OF /g' **/*.thy
perl -0777 -pi -e 's/corres_split_noop_rhs([\w]?) *\[ *OF +_ +(?!_)/corres_split_noop_rhs\1\[OF /g' **/*.thy
perl -0777 -pi -e 's/corres_split_dc([\w]?) *\[ *OF +_ +(?!_)/corres_split_dc\1\[OF /g' **/*.thy
perl -0777 -pi -e 's/corres_split_handle([\w]?) *\[ *OF +_ +(?!_)/corres_split_handle\1\[OF /g' **/*.thy
perl -0777 -pi -e 's/corres_split_catch([\w]?) *\[ *OF +_ +(?!_)/corres_split_catch\1\[OF /g' **/*.thy
perl -0777 -pi -e "s/corres_split_eqr(\w?) *\[ *OF +([^\W_][\w'-]+) +([^\W_][\w'-]*)/corres_split_eqr\1\[OF \3 \2/g" **/*.thy
perl -0777 -pi -e 's/corres_split_nor(\w?) *(.*)\)\n\s*prefer +2/corres_split_nor\1\2\)/g' **/*.thy

Signed-off-by: Corey Lewis <corey.lewis@proofcraft.systems>
2022-10-20 08:59:52 +11:00
Corey Lewis f4e9295424 proof: change simple corres_split_deprecated cases
perl -0777 -pi -e 's/corres_split_deprecated *\[ *OF +_ +([^_].*)\)\n\s*prefer 2/corres_split[OF \1\)/g' **/*.thy
perl -0777 -pi -e 's/corres_split_deprecated *\[ *OF +_ +(?!_)/corres_split[OF /g' **/*.thy
perl -0777 -pi -e 's/corres_split_deprecated *\[ *OF +([^_]\w+) +([^_]\w+) +(.*)\)\n\s*prefer +2/corres_split[OF \2 \1 \3\)/g' **/*.thy
perl -0777 -pi -e 's/corres_split_deprecated *\[ *OF +([^_]\w+) +([^_]\w+)/corres_split[OF \2 \1/g' **/*.thy
perl -0777 -pi -e 's/corres_split_deprecated *(.*)\)\n\s*prefer +2/corres_split\1\)/g' **/*.thy

Signed-off-by: Corey Lewis <corey.lewis@proofcraft.systems>
2022-10-20 08:59:52 +11:00
Corey Lewis 6d37587b0b proof: rename corres_split' to corres_underlying_split
sed -E -i "s/\bcorres_split'\b/corres_underlying_split/g" proof/**/*.thy

Signed-off-by: Corey Lewis <corey.lewis@proofcraft.systems>
2022-10-20 08:59:52 +11:00
Mitchell Buckley 2cf89e20c8 Cleanup some FIXMEs in AInvs and related sessions
Mostly moving lemmas up into various lemma bucket theories. Also:
* replace cte_wp_at_eqD with cte_wp_at_norm (equal lemmas)
* pd_shifting_gen generalise pd_shifting' in 2 architectures
* remove some redundant crunch lemmas

Signed-off-by: Mitchell Buckley <Mitchell.Buckley@data61.csiro.au>
2021-07-16 14:13:07 +10:00
Mitchell Buckley 7180ee4e70 refine: Standardise names of some corres lemmas
Ideally all corres lemmas of the form
`corres rrel P P' my_abstract_function myHaskellFunction`
should be named `myHaskellFunction_corres`.

This commit renames over 200 lemmas to match this style.

Signed-off-by: Mitchell Buckley <mitchell.alan.buckley@gmail.com>
Co-authored-by: Victor Phan <Victor.Phan@data61.csiro.au>
2021-06-21 10:30:04 +10:00
Corey Lewis dd07ffd197 refine: move invariant field update lemmas
Signed-off-by: Corey Lewis <Corey.Lewis@data61.csiro.au>
2021-03-11 10:42:49 +11:00
Corey Lewis 008969fc02 lib proof: reorder the assumptions of corres_split
Currently this just modifies the rule but not any of the proofs that use
it. The old version is kept for now but should be removed once all of
the proofs are updated.

Signed-off-by: Corey Lewis <Corey.Lewis@data61.csiro.au>
2021-02-19 11:37:12 +11:00
Gerwin Klein 66b2774155 arm refine: Isabelle2020 update
Signed-off-by: Gerwin Klein <gerwin.klein@data61.csiro.au>
2020-10-27 15:52:31 +10:00
Gerwin Klein a424d55e3e licenses: convert license tags to SPDX 2020-03-13 14:38:24 +08:00
Victor Phan f2d1f5ada7 refine/crefine: convert crunch with multiple constants into crunches 2020-02-03 16:29:19 +11:00
Victor Phan 285c47f622 cleanup for crunch_ignore in refine and crefine for all arches
Several constants are are added to the top level crunch_ignore statement in
Bits_R.thy, then removed from individual crunch statements across Refine and
CRefine.
2020-02-03 16:29:18 +11:00
Corey Lewis dd48e0d899 proof: update for wp changes
Updated 'wp_once' to 'wp (once)' and removed several stray uses of 'wp_trace'.
2019-10-14 17:12:18 +11:00
Gerwin Klein c34840d09b global: isabelle update_cartouches 2019-06-14 11:41:21 +10:00
Michael McInerney 4463e9750e SELFOUR-1198: update proofs for correct restart PC
Fixes a case where a thread can go from Running->Inactive->Restart and
use a restart PC that is out of date. An out of date restart PC occurs
when a thread was transitioned to running after being in a blocked
state, but was never scheduled and so did not execute the traps code
that updates the restart PC.

This also renames relevant register names for consistency across
architectures (FaultIP and NextIP).
2019-06-13 11:43:50 +10:00
Edward Pierzchalski 2035f444a0 refine: Remove unused lemmas. 2019-05-28 10:00:10 +10:00
Victor Phan d707c97df9 arm refine: update for new definition of set_object 2019-04-18 14:32:08 +10:00
Rafal Kolanski c02d0406f5 arm refine: update for GrantReply (SELFOUR-6)
Initial setup and sorrying by Thibaut Perami.
2018-12-10 20:01:37 +11:00
Gerwin Klein 6b9d9d24dd Isabelle2018: new "op x" syntax; now is "(x)"
(result of "isabelle update_op -m <dir>")
2018-08-20 09:06:35 +10:00
Corey Lewis 2d0baab462 Proof update for crunch changes 2018-04-04 14:13:55 +10:00
Thomas Sewell 0f38e20094 Many proof repairs. 2018-03-16 14:57:51 +11:00
Thomas Sewell 652cbb966e Initial proof updates for combinator changes. 2018-03-16 14:53:22 +11:00
Joel Beeren 4601f2a1ab Genericise deletion actions that occur after empty_slot
This patch adds a generic "post_cap_deletion" step that is called by
finalise_slot. Previous to this, the only caps which had actions
required at this stage were IRQHandlerCaps -- it was required that the
IRQ bitmap be updated after the cap itself was removed (as the
invariants state that for any existing IRQHandlerCap, the corresponding
bit in the IRQ bitmap must be set).

By genericising this, we add the capacity for new, arch-specific post
cap deletion actions to occur in the future.
2018-02-23 09:12:55 +11:00
Miki Tanaka 2a1beffac1 arm: update for simple_ko getter/setter 2017-12-14 18:02:48 +11:00
Miki Tanaka 3841b6e8ba arm : add AEndpoint and ANTFN a_type simplification
in addition to the a_type ATCB simplification, the following two are now in the simpset:
  "a_type (Endpoint x) = AEndpoint"
  "a_type (Notification v) = ANTFN"
2017-12-14 07:17:27 +11:00
Matthew Brecknell 48b3a8b4ca update object and field widths for x64, and remove some magic numbers
In X64 update the following to match the C kernel:
  - TCB size-bits (11).
  - Endpoint size-bits (4).
  - Guard bits (58).
  - Message registers.

For all architectures, replace magic numbers with defined constants in
specifications, and as far as possible in proofs:
  - tcb_bits in abstract spec.
  - tcbBlockSizeBits, cteSizeBits, ntfnSizeBits, epSizeBits in Haskell
    spec, Haskell and C refinement proofs.
2017-10-26 14:05:35 +11:00
Alejandro Gomez-Londono 796887d9b1 Removes all trailing whitespaces 2017-07-12 15:13:51 +10:00
Alejandro Gomez-Londono 2d20221396 arm refine: updates for the backport from arm-hyp completed 2017-06-19 14:32:44 +10:00
Alejandro Gomez-Londono b76709967b arm refine: Updating theories for ainvs changes 2017-06-19 14:32:44 +10:00
Miki Tanaka 7ad3ef3b3e wp: update the proofs for the new wp/wpc/wpsimp 2017-03-16 19:39:11 +11:00
Matthew Brecknell 6ce6c97397 arch_split: DetSchedDomainTime_AI, DetSchedSchedule_AI for ARM 2017-03-09 12:10:44 +11:00
Miki Tanaka 3db5dd778d Refine fix for prepare_thread_delete 2017-02-20 09:23:55 +11:00
Rafal Kolanski 7657681fca move refine/* to refine/ARM/*, parametrise over $L4V_ARCH 2017-01-30 12:22:22 +11:00