Frama-C-discuss mailing list archives

This page gathers the archives of the old Frama-C-discuss archives, that was hosted by Inria's gforge before its demise at the end of 2020. To search for mails newer than September 2020, please visit the page of the new mailing list on Renater.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Frama-c-discuss] Automating proof on data invariant with Wp

  • Subject: [Frama-c-discuss] Automating proof on data invariant with Wp
  • From: josselin.giet at (Josselin Giet)
  • Date: Tue, 7 Jul 2020 15:52:51 +1000
  • In-reply-to: <>
  • References: <>


I'm currently working on a project to verify invariant on data-types 
with relaxed concurrency models: reading are made out of critical 
regions, it's up to the writing thread to maintain the invariant each 
time a data is available to others.

I'm aware there is a way to declare weak and strong invariant, but I 
want to check them at specific instructions.
My typical example is the follow :

struct point {
   int x, y;
\\@ on_visible (this.x > this.y);

int main(){
   struct point *pt = malloc(...);
   //@ make_visible pt;      <- invariant should hold at this point!

With the `register_global` function we have a `lexpr_node` that 
represents the invariant. I want to avoid an «ad hoc» translator since 
it may not be generic.
How can we translate it to an assertion that could be checked with Wp?

Best regards,

Josselin Giet