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] Problem of "\separated" with WP

  • Subject: [Frama-c-discuss] Problem of "\separated" with WP
  • From: marsishandsome at (mars Gu)
  • Date: Thu, 4 Aug 2011 11:05:55 +0200


Thank you for your answer of my question about "separated memory model".
But I still have some problems about how to use it.

I write a program "copy2.c" to test "separated memory model".
The function "void copy(const value_type* a, size_type n, value_type* b)"
could be proved, only if "separated memory model" is used.
I start the program "copy2.c" with the following command: "frama-c-gui -wp
-wp-proof alt-ergo copy2.c".
The version of Frama-c is "Frama-C Carbon-20110201+dev".

The following commands:
"#pragma SeparationPolicy(regions)" and
"requires \separated(a+(0..n-1), b+(0..n-1));"
are used to ensure, that array a and array b are separated.

The result is, that
Line 39, "//@ assert i==0 ==> b[0] == a[0];" can be proved, while
Line 40, "//@ assert i==1 ==> b[0] == a[0];" cannot be proved.

The most likely problem of this result is, that array a and array b are not
I want to know, whether my usage of "separated memory model" is right or
If not, could you give me an example, to illustrate, how to use it?

Thank you
Liangliang Gu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: copy2.c
Type: text/x-csrc
Size: 869 bytes
Desc: not available
URL: <>