Skip to content
  1. Nov 13, 2012
  2. Nov 12, 2012
  3. Nov 10, 2012
    • Jordan Rose's avatar
      [analyzer] When invalidating symbolic offset regions, take fields into account. · 9eb409ac
      Jordan Rose authored
      Previously, RegionStore was being VERY conservative in saying that because
      p[i].x and p[i].y have a concrete base region of 'p', they might overlap.
      Now, we check the chain of fields back up to the base object and check if
      they match.
      
      This only kicks in when dealing with symbolic offset regions because
      RegionStore's "base+offset" representation of concrete offset regions loses
      all information about fields. In cases where all offsets are concrete
      (s.x and s.y), RegionStore will already do the right thing, but mixing
      concrete and symbolic offsets can cause bindings to be invalidated that
      are known to not overlap (e.g. p[0].x and p[i].y).
      This additional refinement is tracked by <rdar://problem/12676180>.
      
      <rdar://problem/12530149>
      
      llvm-svn: 167654
      9eb409ac
  4. Nov 07, 2012
  5. Nov 06, 2012
  6. Nov 05, 2012
    • Jordan Rose's avatar
      [analyzer] Move convenience REGISTER_*_WITH_PROGRAMSTATE to CheckerContext.h · 520a30fd
      Jordan Rose authored
      As Anna pointed out, ProgramStateTrait.h is a relatively obscure header,
      and checker writers may not know to look there to add their own custom
      state.
      
      The base macro that specializes the template remains in ProgramStateTrait.h
      (REGISTER_TRAIT_WITH_PROGRAMSTATE), which allows the analyzer core to keep
      using it.
      
      llvm-svn: 167385
      520a30fd
  7. Nov 03, 2012
  8. Nov 02, 2012
  9. Nov 01, 2012
  10. Oct 31, 2012
  11. Oct 30, 2012
  12. Oct 29, 2012
    • Anna Zaks's avatar
      [analyzer] Malloc checker cleanup/refactor · 58a2c4e4
      Anna Zaks authored
      No need for the auxiliary flag. No need to generate a leak node when
      there is no error.
      
      llvm-svn: 166977
      58a2c4e4
    • Anna Zaks's avatar
      [analyzer] Add SimpleStreamChecker. · be70d4d0
      Anna Zaks authored
      This is an example checker for catching fopen fclose API misuses.
      
      llvm-svn: 166976
      be70d4d0
    • Anna Zaks's avatar
      [analyzer] Add checker helpers to CheckerContext. · 2ab0321b
      Anna Zaks authored
      - Adding Immutable Map to GDM and getIdentifierInfo helper method.
      
      llvm-svn: 166975
      2ab0321b
    • Jordan Rose's avatar
      [analyzer] New option to not suppress null return paths if an argument is null. · ec44ac6a
      Jordan Rose authored
      Our one basic suppression heuristic is to assume that functions do not
      usually return NULL. However, when one of the arguments is NULL it is
      suddenly much more likely that NULL is a valid return value. In this case,
      we don't suppress the report here, but we do attach /another/ visitor to
      go find out if this NULL argument also comes from an inlined function's
      error path.
      
      This new behavior, controlled by the 'avoid-suppressing-null-argument-paths'
      analyzer-config option, is turned off by default. Turning it on produced
      two false positives and no new true positives when running over LLVM/Clang.
      
      This is one of the possible refinements to our suppression heuristics.
      <rdar://problem/12350829>
      
      llvm-svn: 166941
      ec44ac6a
    • Jordan Rose's avatar
      [analyzer] Use the CallEnter node to get a value for tracked null arguments. · 199fdd82
      Jordan Rose authored
      Additionally, don't collect PostStore nodes -- they are often used in
      path diagnostics.
      
      Previously, we tried to track null arguments in the same way as any other
      null values, but in many cases the necessary nodes had already been
      collected (a memory optimization in ExplodedGraph). Now, we fall back to
      using the value of the argument at the time of the call, which may not
      always match the actual contents of the region, but often will.
      
      This is a precursor to improving our suppression heuristic.
      <rdar://problem/12350829>
      
      llvm-svn: 166940
      199fdd82
Loading