Skip to content
Snippets Groups Projects

Draft: Ci/tree borrows

Merged Neven Villani requested to merge ci/tree-borrows into master

Merge request reports

Pipeline #96266 passed

Pipeline passed for 409af31d on ci/tree-borrows

Approval is optional

Merged by Ralf JungRalf Jung 1 year ago (Feb 6, 2024 9:44am UTC)

Merge details

  • Changes merged into master with 36e4daa7.
  • Deleted the source branch.

Pipeline #96293 passed

Pipeline passed for 36e4daa7 on master

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
59 59 Global Instance subG_bor_stateΣ Σ :
60 60 subG bor_stateΣ Σ bor_stateGpreS Σ.
61 61 Proof. solve_inG. Qed.
62 62
63 Section utils.
64
65 Record item_for_loc : Type := {
66 lperm : lazy_permission;
67 tg : tag;
68 cid : option protector;
69 }.
70
71 Inductive item_for_loc_in_tree (i : item_for_loc) (tree : tree item) (l' : Z) : Prop :=
72 is_in_tree item :
73 exists_node (IsTag i.(tg)) tree
74 every_node (λ i', i.(tg) = i'.(itag) i' = item) tree
  • Neven Villani
    Neven Villani @neven started a thread on commit e4813c39
  • 67 tg : tag;
    68 cid : option protector;
    69 }.
    70
    71 Inductive item_for_loc_in_tree (i : item_for_loc) (tree : tree item) (l' : Z) : Prop :=
    72 is_in_tree item :
    73 exists_node (IsTag i.(tg)) tree
    74 every_node (λ i', i.(tg) = i'.(itag) i' = item) tree
    75 i.(cid) = item.(iprot)
    76 i.(lperm) = default {| initialized := PermLazy; perm := item.(initp) |}
    77 (item.(iperm) !! l')
    78 item_for_loc_in_tree i tree l'.
    79
    80 Inductive item_for_loc_in_trees (i : item_for_loc) (t : trees) (l : loc) : Prop :=
    81 is_in_trees tree :
    82 t !! (fst l) = Some tree item_for_loc_in_tree i tree (snd l) item_for_loc_in_trees i t l.
    • Author Developer

      Do we want t !! (fst l) = Some tree -> item_for_loc_in_tree ... or t !! (fst l) = Some tree /\ item_for_loc_in_tree ... ? It might not make a difference, but the second one seems more intuitively impossible to misuse ?

    • Usually, you write inductives like this. If you put an \land there, you need to use more destruct patterns..

      Or am I misunderstanding your points

    • Author Developer

      Oh you're right. Yeah I forgot this was an Inductive and not a Definition.

    • Please register or sign in to reply
  • Neven Villani
    Neven Villani @neven started a thread on commit e4813c39
  • 82 t !! (fst l) = Some tree item_for_loc_in_tree i tree (snd l) item_for_loc_in_trees i t l.
    83
    84 Context (C : gset call_id).
    85
    86 Inductive protected_by: option protector Prop :=
    87 is_protected_by p :
    88 p.(call) C protected_by (Some p).
    89
    90 Inductive pseudo_conflicted (tr : tree item) (l : Z) (tg1 : tag) : res_conflicted option protector Prop :=
    91 pseudo_conflicted_conflicted c :
    92 protected_by c
    93 pseudo_conflicted tr l tg1 ResConflicted c
    94 | pseudo_conflicted_cousin_init conf c it :
    95 protected_by c
    96 item_for_loc_in_tree it tr l
    97 rel_dec tr it.(tg) tg1 = Uncle
  • Neven Villani
    Neven Villani @neven started a thread on commit e4813c39
  • 68 129 Section defs.
    69 130 (* We need all the maps from the tag interpretation here....
    70 131 TODO: can we make that more beautiful? all the different invariants are interleaved in subtle ways, which makes modular reasoning really hard... *)
    71 Context (M_tag : gmap ptr_id (tag_kind * unit)) (M_t M_s : gmap (ptr_id * loc) scalar) (Mcall_t : gmap call_id (gmap ptr_id (gset loc))).
    132 Context (M_tag : gmap nat (tag_kind * unit)) (M_t M_s : gmap (nat * loc) scalar) (Mcall_t : gmap call_id (gmap nat (gset loc))).
  • Neven Villani
    Neven Villani @neven started a thread on commit e4813c39
  • 221 283 state_rel M_tag M_t Mcall σ_t σ_s -∗
    222 284 pub_loc sc_rel σ_t σ_s l ⌜∃ t, priv_loc M_tag M_t Mcall t l⌝.
    223 285 Proof.
    286 From simuliris.stacked_borrows Require Import steps_progress steps_retag.
  • Neven Villani
    Neven Villani @neven started a thread on commit e4813c39
  • 444 507 Lemma loc_controlled_local_authoritative l t t' tk' sc sc' σ f :
    445 508 loc_controlled l t tk_local sc (state_upd_mem f σ)
    446 509 loc_controlled l t' tk' sc' σ
    510 From simuliris.stacked_borrows Require Import steps_progress steps_retag.
  • assigned to @neven

  • Neven Villani marked this merge request as draft

    marked this merge request as draft

  • Author Developer

    Before merging:

    • rename Uncle into Cousin ?
    • remove accidental stacked_borrows imports
  • added 1 commit

    • 9926b829 - Lemmas about X should not be named X

    Compare with previous version

  • Neven Villani added 2 commits

    added 2 commits

    • 355dd479 - pseudo-conflicted needs to be per-loc *and* per-tag
    • 0a1c3cf2 - Merge branch 'ci/tree-borrows' of gitlab.mpi-sws.org:iris/simuliris into ci/tree-borrows

    Compare with previous version

  • Neven Villani added 1 commit

    added 1 commit

    • 0664130f - Merge branch 'ci/tree-borrows' of gitlab.mpi-sws.org:iris/simuliris into ci/tree-borrows

    Compare with previous version

  • Neven Villani added 4 commits

    added 4 commits

    • 62826206 - rename Uncle -> Cousin
    • 12c5797f - bug: double free
    • 341876fe - [INCOMPLETE] fix wf after double free bug
    • fb3e1288 - [INCOMPLETE] partial fix missing tk

    Compare with previous version

  • added 1 commit

    Compare with previous version

  • added 1 commit

    • b3f8fe3a - Remove intermediate unneeded commented-out proof

    Compare with previous version

  • added 1 commit

    • e57d0566 - Make definition of same_blocks have less casts (to make things see through it better)

    Compare with previous version

  • added 1 commit

    • c9ca449e - Fix tkmap_view, logical_state

    Compare with previous version

  • added 1 commit

    Compare with previous version

  • Neven Villani added 2 commits

    added 2 commits

    • 8b07c34b - Alloc progress ok. Eliminated some useless lemmas. Thinking about write.
    • 9780f4f6 - Annoying line comments

    Compare with previous version

  • Neven Villani added 1 commit

    added 1 commit

    Compare with previous version

  • Neven Villani added 2 commits

    added 2 commits

    • 54734a13 - flatten single-constructor tag type into just nat
    • 79c31342 - key lemma for stating future read/write success

    Compare with previous version

  • Neven Villani added 1 commit

    added 1 commit

    • 477e090b - lift per-node access success to the full tree

    Compare with previous version

  • Johannes Hostert added 2 commits

    added 2 commits

    • 1510b7f7 - Some work in steps-refl, needs to be refactored
    • 17483f72 - more partial progress with steps_refl

    Compare with previous version

  • Neven Villani added 1 commit

    added 1 commit

    Compare with previous version

  • Neven Villani added 1 commit

    added 1 commit

    • 836310c0 - symmetry of eq_up_to_C and trees_equal

    Compare with previous version

  • Johannes Hostert added 2 commits

    added 2 commits

    Compare with previous version

  • added 1 commit

    Compare with previous version

  • merged

  • Please register or sign in to reply
    Loading