Giter VIP home page Giter VIP logo

Comments (6)

zvonimir avatar zvonimir commented on June 5, 2024

Good point Mike.
I would actually like to see something similar even for imprecise choices, such as for example our current implementation of inttoptr. Something like "WARNING: false bugs possible due to inttoptr" or something like that.

from smack.

zvonimir avatar zvonimir commented on June 5, 2024

Mike, I think we are not issuing these warnings, right?
We should then close this one...

from smack.

michael-emmi avatar michael-emmi commented on June 5, 2024

Ah but we are issuing (some of) these warnings; for instance, here's an excerpt from the "globals" regression:

$bb0:
assume {:sourceloc "globals.c", 8, 18} true;
call $p := $malloc($off($ptr($NULL, 4)));
assume {:sourceloc "globals.c", 8, 18} true;
// WARNING: ignoring bitcast instruction : %"$p1" = bitcast i8* %"$p" to i32*, !dbg !14
$p1 := $p;
assume {:sourceloc "globals.c", 8, 18} true;
// WARNING: ignoring llvm.debug call.
assume true;

However, I'm not sure we should close this issue before doing a more careful review of all places where we might be unsound :-)

M

from smack.

shaobo-he avatar shaobo-he commented on June 5, 2024

Just a follow-up on this issue: currently we provide warnings when unsoundness occurs.

from smack.

zvonimir avatar zvonimir commented on June 5, 2024

To me it seems that sometimes we print out such warnings into bpl files and sometimes to the console. Is that right?
I think that printing them just into bpl files is not enough. I think we should do both for each warning, where that is feasible.
Thoughts?

from smack.

michael-emmi avatar michael-emmi commented on June 5, 2024

I tend to agree: the Boogie code we generate should probably be thought of as opaque, and not inspected by any Smack user. Therefore issuing warnings (only) there would not be caught. I am not against leaving comments there in the code also though.

As far as Console warnings go: perhaps it would be good to follow the style of Clang warnings and errors. People tend to find them effective.

Also related: @danielsn was wondering whether we can regularize Smack’s output information, e.g., as JSON. This could include any information currently printed to the console and warnings included in the BPL file. Such a data format would simplify the lives of tools which consume Smack results. I think these unsoundness warnings might be a good place to start with that.

from smack.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.