Release 1.9, patchlevel 3

Official release date: 10/11/2004.

Summary

This release of CodeSurfer is an update to CodeSurfer 1.9p2 that adds some new features and fixes some bugs, as described below.

What's new in CodeSurfer 1.9p3

The release has the following new features:

  • Pointer Analysis
    • Two new pointer-analysis hints have been introduced that are very effective at making pointer analysis more accurate, albeit at the risk of introducing some false negatives. The new hints are numbered 7 and 8 in the documentation. One of these hints (number 7) is enabled by default.
    • A new pointer-analysis option (-pa of) uses struct-field offsets assigned by the CodeSurfer compiler, which can be more accurate, but is not portable. This contrasts with the (-pa af) option, which attempts a portable analysis by using the common-initial sequence rule of ANSI C.
    • The heuristic for assigning types to heap variables has been improved.
  • Set Expressions

Representation Changes

  • Global and static variables without explicit initializations, which in C are implicitly initialized to 0, are now explicitly initialized to zero in the CodeSurfer representation.
  • There have been some changes in the code normalizations:
    • The infinite loop for(;;){...} is now normalized to contain a control point with a true condition.
    • Expressions of the form
        <non-pointer-expression><relation><pointer-expression>
      were previously normalized to
        <pointer-expression><relation><non-pointer-expression>.
      This normalization has now been removed.
  • There is a new option to create PI nodes in the representation.
  • asm functions are now parsed; their bodies are represented by program points of kind "unknown".
  • Support has been added for representing the bodies of try statements in C++. Handlers are still ignored.
  • There is improved support for the Microsoft extensions __try, __except, __finally, and __leave.
  • The CodeSurfer Library Models have been extended to include additional functions.

Scheme API Changes

Fixes

The following bugs have been fixed since 1.9p2:

  • Project definition
    • Fixed a bug where invoking Remove Files could lead to an error.
    • Fixed a bug in command-line processing that prevented the name of the target file from having a slash in it.
  • Compilation
    • Fixed a bug where the xcc compiler model failed to define __CSURF__.
    • Fixed a bug where a crash could occur when the Compute Control Dependence build option was yes, and the Basic Block build option was no.
    • Fixed a bug where the CodeSurfer build would continue when the Invoke Compiler build option was yes, and the native compiler detected compilation errors.
    • Fixed a bug that could cause a crash associated with compilation of calls to destructor functions.
    • Fixed a problem in which the GUI could crash during Build Project when the CodeSurfer Library Models and the user's project are on different disk drives.
    • Fixed a problem in which shifting a constant more bits than it has would lead to a compilation failure.
    • Fixed a problem in which assigning a string constant to a void* would lead to a compilation failure.
  • Representation
    • Fixed a bug where casting a function name to a function pointer would lead to there being no call target whatsoever in the dependence graph.
    • Fixed a bug where the dependence graph of a function could contain disconnected nodes of kind "auxiliary".
  • Queries
    • Fixed a bug where Find Type, with option In Variable Definition, would omit formals.
    • Fixed a bug where Forward Slice could be wrong when the return value of a function is immediately dereferenced.
    • Fixed a problem in which the LOC metric could be wrong.
  • Performance
    • Fixed a performance bug where the importing of interest sets in PureCover format could be very slow.
  • API
    • Fixed a problem in which the pattern (list ?x ?y) would fail to match.
  • Libraries
    • Fixed a bug in the CodeSurfer Library Models treatment of the length argument of strncat.
    • Improved the pointer analysis treatment of structs in library models.
  • Improved alpha-level support for C++
    • Fixed some problems in the compiler models for C++.
    • Fixed a bug where g++ -O2 caused two versions of libc functions to be included.
    • Fixed a problem where name demangling could fail.

Documentation

The following changes have been made to the documentation:

  • The material on sets has been reorganized and extended to include set expressions.
  • The semantics of the built-in Scheme procedures eq?, eqv?, equal?, and hash-table-hash on the Core API types has been clarified.
  • All new features and API changes have been documented.

Known Problems

Cygwin ld 2.15.91 20040725-2 contains a NULL pointer deference bug that causes it to crash when used in conjunction with a CodeSurfer build. This bug will be fixed in the next Cygwin binutils release. In the mean time, you could either downgrade your binutils to the 2.15.90 20040312-1 version, or apply a patch to the 20040725 source and build it yourself.


Free Trial | Products | Customers | Support | News | Jobs | About Us         © 2007, GrammaTech, Inc. All rights reserved.