Giter Club home page Giter Club logo

freeboogie's People

Contributors

rgrig avatar

Watchers

 avatar

freeboogie's Issues

typechecker for boogie v2

I should skim thru the MSR implementation before writing mine. In any case,
it shouldn't be to different from the existing one, which already handles
generics.

Original issue reported on code.google.com by [email protected] on 27 Jul 2009 at 7:45

add axioms for %

I thought z3 interprets % as modulo but it seems to be uninterpreted. Check
and fix.

Original issue reported on code.google.com by [email protected] on 27 Aug 2009 at 9:54

interface to parse from strings

The ANTLR generated parser has methods for each rule but processes only
some "antlr streams". I should write an adapter between String and those
streams. Try to make the interface nice as it will be used in the Eclipse
editor.

Original issue reported on code.google.com by [email protected] on 27 Aug 2009 at 9:58

macro cycles

At the moment a macro cycle like
  \def\A{\B}
  \def\B{\A}
  \A
leads to an infinite loop that eventually runs out of memory. (Note that
macro definitions are NOT expanded until macros are used.)

There should be some sort of check for that. The simplest to implement
without affecting performance in the common case is to put a fixed limit on
the depth of macro expansions.

A bit fancier is to not immediately report an error when the limit is
reached but rather check if there is indeed a cycle and, if not, increase
the limit. To check if there is indeed a cycle you go up the macro 'stack'
(which doesn't exist explicitly) and check for duplicates.

Original issue reported on code.google.com by [email protected] on 30 Jul 2009 at 3:49

reformat cmdline usage message to take less space

Instead of
--log-level=[info|warning|error]  (default: warning)
-ll=[info|warning|error]  (default: warning)
     Configure how much information should be logged.

--dump-intermediate-stages=<file>
-dis=<file>
     Specify  a directory where to dump the result  of each transformation.
     The  dump includes  a  Boogie  program,  its  symbol  table,  and  its
     flowgraphs.

It should be more like
--log-level|-ll=[info|warning|error]  default: warning
     how much information should be logged
--dump-intermediate-stages|-dis=<file>
     directory where intermediate results are dumped

Original issue reported on code.google.com by [email protected] on 25 Jul 2009 at 7:52

location tracking

I believe there are a few places where FileLocation is not carried over
appropriately. There should be a debug switch that prints/logs all the
places from which the mk() methods are called without locations.

Original issue reported on code.google.com by [email protected] on 3 Aug 2009 at 3:08

  • Blocked on: #22

change ast to use immutable lists instead of functional ones

The FreeBoogie AST now uses singly linked lists. The rationale was that:
(1) we want immutable lists (in general, immutable AST), 
(2) there is no class for immutable lists in the Java API, and 
(3) implementing singly linked lists ourselves didn't require support from
AstGen.

However, there are disadvantages:
(1) David Cok complained that this leads to hard-to-maintain code. I
respectfully disagree but, even so, I expect others to feel the same.
(2) Performance: The JVM does not support tail calls and won't support them
for a while [http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4726340].
This leads to slowness (not sure how much) and the _necessity_ of setting a
higher stack.
(3) Exceptions backtraces are hard to read.
(4) You can't loop over the list using the nice foreach syntax. The natural
recursive implementation is somewhat cumbersome in Java because defining a
new function requires typing lots of crap. In general, you can't use
Iterator and related facilities.

Since Google Collections have been recently added as an external dependency
we now have a nice ImmutableList class for free. Using it would allow us to
keep the AST immutable (thus avoiding ASTs that change from "under your
feet") and avoid the problems outlined above. The downside: This requires
changing pretty much every existing visitor.

Original issue reported on code.google.com by [email protected] on 25 Jul 2009 at 9:32

organize the grammar

The grammar is somewhat disorganized.

I should reorder the rules so that:
(1) they are laid out in BFS order, and alphabetically
(2) all the list rules are grouped together, and alphabetically


Original issue reported on code.google.com by [email protected] on 26 Aug 2009 at 2:42

file issues

Move all issues from TODO files into the googlecode tracker.

Original issue reported on code.google.com by [email protected] on 25 Jul 2009 at 7:58

wiki page for AstGen

Right now the best place that documents AstGen is in some FreeBoogie
javadoc. A wiki page is much better suited for that, given that people may
want to use AstGen independent of FreeBoogie.

Original issue reported on code.google.com by [email protected] on 27 Jul 2009 at 7:50

desugar if

if statements (commands) can always be desugarred using assume and goto

Original issue reported on code.google.com by [email protected] on 26 Aug 2009 at 12:19

basic eclipse pligin

The current FreeBoogie plugin doesn't do anything useful. There should be
an editor and a way to run FreeBoogie on a Boogie file.

Original issue reported on code.google.com by [email protected] on 31 Jul 2009 at 5:01

antlr parser for boogie v2

It can be tested with
 (1) the hand-written tests taken from krml178
 (2) the examples that come with Spec#
 (3) the automatically translated boogie benchmarks

Original issue reported on code.google.com by [email protected] on 27 Jul 2009 at 10:52

parse <: properly

At the moment the operator <: is parsed as in Boogie 1 and not interpreted
properly. It should be parsed as in Boogie 2, at least.

Original issue reported on code.google.com by [email protected] on 26 Aug 2009 at 2:37

building ASTs from code

The code in MapRemover is horrible. There must be a better way to construct
the corresponding ASTs. Perhaps use the parser.

Original issue reported on code.google.com by [email protected] on 9 Aug 2009 at 12:53

carry on triggers

Triggers don't end up in the VC at the moment and that affects performance
a *lot*.

Original issue reported on code.google.com by [email protected] on 27 Aug 2009 at 9:56

fix unchecked in Logger

At the moment there is a @supresswarnings in Logger that can lead to ugly
trouble. This really needs more type-safety (since I already fall for it).
When you say:
  Logger<C,L> log = Logger.get("foo");
there is no guarantee that the name "foo" is attached to something of the
type Logger<C,L>. The problem, of course, is that generics aren't reified
in Java. I'm not sure what's a good solution.

Original issue reported on code.google.com by [email protected] on 26 Aug 2009 at 4:44

visiting methods should take one argument

It's convenient sometimes to have
  void see(
    VariableDecl vd,
    ImmutableList<Attribute> attr,
    String name,
    Type type,
    ImmutableList<AtomId> typeArgs,
    Expr where)
and then say
  name

instead of having
  void see(VariableDecl variableDecl)
and then say
  variabledecl.name()

BUT... the former is a *pain* to maintain when the abstract grammar
changes. Plus, the (necessary) vertical alignment of the arguments looks ugly.

This task is boring, takes time, but make further changes easier.

Original issue reported on code.google.com by [email protected] on 22 Aug 2009 at 10:40

support for tags

Add support for tagging members in AstGen. This way templates can do
something different for lists.

Original issue reported on code.google.com by [email protected] on 25 Jul 2009 at 8:19

ast for body

The AST for the body of functions should *be* a graph.

It is convenient (although not efficient) to redo name resolution instead
of forcing each transformer to work harder and update the symbol table too.
However, it is inconvenient (*and* inefficient) to recompute the graph of
commands from (possibly nested) blocks (which are lists of commands) and
goto-s. This is because I tend to think of the program as a graph anyway,
and keeping track of lowly things such as labels is a headache I'd rather
avoid.

Of course, if WhileCmd is not desugared and dealt with, we *have* to work
with blocks, labels, and goto-s.

Original issue reported on code.google.com by [email protected] on 19 Aug 2009 at 6:26

unified terms naming

Have a mechanism to make sure that all term names start with "term$$", and
make sure this prefix is not accidentally added to number literals.

Original issue reported on code.google.com by [email protected] on 27 Aug 2009 at 10:03

include files

It should be possible to include another file with a macro like:
  \include{file_path}
Make sure to check for cycles.

Original issue reported on code.google.com by [email protected] on 30 Jul 2009 at 3:40

alpha renaming

Implement an alpha renaming phase that makes sure each definition uses an
unique name throughout the program. Also, keep the correspondence to the
original name, for error reporting.

This will allow:
(1) processing the intermediate dumps (which use "forbidden names")
(2) hash-consing for ASTs, if deemed necessary

Original issue reported on code.google.com by [email protected] on 27 Aug 2009 at 10:09

re-think backend

At the moment the split between general terms and smt terms seems to be an
overkill.

Original issue reported on code.google.com by [email protected] on 27 Aug 2009 at 10:00

desugar function bodies

The code
  function f(args) returns (results) { expr }
is equivalent to
  function f(args) returns (results);
  axiom (forall args, results :: f(args) == expr);

Do the desugaring.

Original issue reported on code.google.com by [email protected] on 26 Aug 2009 at 2:36

better location tracking

It should be possible to parse a string and know for each terminal and
non-terminal which substring it matched. This will be useful for
edit-and-verify reloaded.

Original issue reported on code.google.com by [email protected] on 31 Jul 2009 at 7:05

  • Blocking: #23

file names should work on all system

If the template contains
  \file{a/b}
it should work on both Linux and Windows, even if the natural way to say it
on windows is
  \file{a\b}
This one would be confused with macros anyway.

Original issue reported on code.google.com by [email protected] on 30 Jul 2009 at 2:07

astgen conditions

With immutable data structures it is sometimes convenient to be able to
"change" one field:
  Command newCommand = oldCommand.changeLabels(emptyList);
To be able to generate code for changeLables one would need to write a
template like
  \members{
    public \ClassName change\MemberName(\MemberType newMember) {
      return new \ClassName(\members[,]
        {\if{\MemberName==\MemberName[1]}{newMember}{\memberName}});
    }
  }
or something similar.

There are two things that must be done to get the template above to work:
1. support references to outer loops, as in \MemberName[0], \MemberName[1]
2. evaluate conditions

Original issue reported on code.google.com by [email protected] on 19 Aug 2009 at 5:54

list separator should be more flexible

At the moment you can only say
  \members[SEP]{foo}
if SEP doesn't contain any special character like [, *, |, etc. The
separator should be read as a string up to the matching ], so that one can say
  \members[&&]{\memberName}
for example.

It might even be worth processing the inside of [] using the current
context (including macros), save the result as a string, and use that string.

Original issue reported on code.google.com by [email protected] on 30 Jul 2009 at 4:13

crash when {} are not balanced

This issue was created by revision r566.

If there are more } than { the TemplateParser tries to rewind
when there is no mark. I believe this used to be a no-op, but
the proper fix would be to fix the TemplateParser to not try to
rewind the token stream when it didn't set a mark on it.

Original issue reported on code.google.com by [email protected] on 3 Aug 2009 at 4:05

dump state after each transformation

Basically, implement --dump-intermediate-stages.

This should create a directory with one subdirectory for each phase. In
each subdirectory there should be a boogie file, a symbol table file, and a
bunch of flow-graph files (one for each implementation). In short: a dump
of the AST and of the TypeChecker information in a readable form.

The first stage should be 'parsing', which isn't strictly speaking an AST
transformer.

Original issue reported on code.google.com by [email protected] on 25 Jul 2009 at 8:06

desugar break

break statements are just convenient syntactic sugar for goto

Original issue reported on code.google.com by [email protected] on 26 Aug 2009 at 12:18

add support for user defined macros

In FreeBoogie templates I have the string
  "\if_primitive{\Membertype}{\MemberType}"
in so many places that I wish I'd be able to define
  \def\mt{\if_primitive{\Membertype}{\MemberType}}
and then use it simply as
  \mt

It's probably not worth it to support parameters. If a use-case arises then
I should consider parameters too.

Original issue reported on code.google.com by [email protected] on 27 Jul 2009 at 4:44

AstGen/test/ag_parser.huge is too slow

That test is designed to check that 1MB is processed in less than 5
seconds. At the moment the 5 second limit is removed because at some point
AstGen became too slow.

Original issue reported on code.google.com by [email protected] on 27 Jul 2009 at 4:12

macro parameters

It should be possible to say
  \def\terminals[1]{\classes{\if_terminal{#0}{}}}
The [1] is the number of parameters and #0 stands for the first parameter.
It is used as:
  \terminals{\ClassName}

Original issue reported on code.google.com by [email protected] on 30 Jul 2009 at 3:39

add a switch for Coq

There is a preliminary (?) coq implementation that dumps proof obligations
in a file, but no switch so that normal users can activate it.

Original issue reported on code.google.com by [email protected] on 27 Aug 2009 at 9:52

type encoding

Withe the Boogie 2 type system it is not safe to erase types. Instead they
need to be encoded, as explained here:
  http://research.microsoft.com/en-us/um/people/leino/papers/krml186.pdf

Original issue reported on code.google.com by [email protected] on 26 Aug 2009 at 4:13

svn periodic checks

Change the cron script to check that
(1) the svn trunk in googlecode compiles
(2) the svn trunk in mobius passes tests

Also, put the script in the svn.

Original issue reported on code.google.com by [email protected] on 25 Jul 2009 at 7:57

handle where

Make sure that 'where' on variable declarations is handled correctly. This
task is mainly about adding tests.

Original issue reported on code.google.com by [email protected] on 22 Aug 2009 at 10:32

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.