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] strlen axioms and memory space


  • Subject: [Frama-c-discuss] strlen axioms and memory space
  • From: efremov at ispras.ru (Denis Efremov)
  • Date: Fri, 31 Jul 2020 00:44:42 +0300
  • In-reply-to: <CA+RLCQx4DaVUCrK__=ocAXYMzKrzCtQcxoc9eMfgV6i3JuXVXw@mail.gmail.com>
  • References: <CA+RLCQx4DaVUCrK__=ocAXYMzKrzCtQcxoc9eMfgV6i3JuXVXw@mail.gmail.com>

Hi,

On 7/30/20 11:36 PM, Yurii Rashkovskii wrote:
>
> I have a question / thought to bounce off. I've been recently trying to prove a few properties on some trivial functions in a small project of mine (https://github.com/yrashk/clam).
>
> I ran into an interesting aspect where I needed to do extensive checks on certain counters not hitting UINTPTR_MAX. I have managed to simplify that with a rather trivial axiom: 
>
> https://github.com/yrashk/clam/commit/e84af3bf8d72ebdcec392589e189952d560ba28a
>
> (obviously, I would have preferred an actual prove, but I am but a novice)
>
> I am wondering if any thought has been previously given on such cases where, for example `strlen` axioms are bound by \forall ℤ which is admittedly wider than pointers would allow?
>
> Is my approach anywhere close to reasonable? Should Frama-C axiomatics include more consideration for the [limited] pointer integer universe?

I faced it while proving strcat

https://github.com/evdenis/verker/blob/master/src/strcat.h#L14

Regards,

Denis