You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
So I have a bunch of theorems that use autocorres heap constructs (in particular "heap_w32, heap_w32_update, etc.") that I would like to use across multiple runs of AutoCorres. The way it looks like this is done internally is with the "valid_typ_heap" function.
However, as is written here (page 154), this is a good use case for locales. So, to start with, I have the locale:
This is alright for my use cases (meaning I can transfer my proofs into the locale no problem). Then when I want to create an interpretation of this to use with a specific C file, I can write (in a given file after loading AutoCorres):
However, I see no way to convince isabelle of that fact. Until now, I had manually re-proved the valid_typ_heap condition, but this is very fragile, and breaks when, for example, new types are introduced to the C file. Is there any way I could access the valid_typ_heap proof to prove my interpretation here?
Are there any other suggestions for writing these general proofs? Using valid_typ_heap as a precondition is too restrictive in general, as it makes it much more difficult to generalize constructs such as functions that would otherwise live within the locale.
The text was updated successfully, but these errors were encountered:
And I guess that's the problem you're describing: Autocorres doesn't give you a way to get hold of those theorems.
I can see two or three ways to attack this:
Refactor heap_lift.ML so that it saves additional theorems into the local theory context as it generates them.
Factor out the ML tactic so you can use it elsewhere.
Duplicate the logic of the ML tactic as an Isar method.
The third might be the most straightforward. The ML tactic is found in the first part of lifted_globals_lemmas. It looks like it's roughly equivalent to the following:
You'll need to figure out how to construct valid_typ_heap_simps to match the ss ruleset in lifted_globals_lemmas. As you pointed out, that ruleset will depend on the particular C you've parsed, but hopefully you can find a way to construct a ruleset that's robust to changes in the C.
So I have a bunch of theorems that use autocorres heap constructs (in particular "heap_w32, heap_w32_update, etc.") that I would like to use across multiple runs of AutoCorres. The way it looks like this is done internally is with the "valid_typ_heap" function.
However, as is written here (page 154), this is a good use case for locales. So, to start with, I have the locale:
This is alright for my use cases (meaning I can transfer my proofs into the locale no problem). Then when I want to create an interpretation of this to use with a specific C file, I can write (in a given file after loading AutoCorres):
The problem is proving this interpretation is correct. I know through much reading and troubleshooting that internally, AutoCorres proves that:
However, I see no way to convince isabelle of that fact. Until now, I had manually re-proved the
valid_typ_heap
condition, but this is very fragile, and breaks when, for example, new types are introduced to the C file. Is there any way I could access thevalid_typ_heap
proof to prove my interpretation here?Are there any other suggestions for writing these general proofs? Using
valid_typ_heap
as a precondition is too restrictive in general, as it makes it much more difficult to generalize constructs such as functions that would otherwise live within the locale.The text was updated successfully, but these errors were encountered: