[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[csmith-project/csmith] 5ca737: Adds Index out-of-bound probability option to csmi...



  Branch: refs/heads/master
  Home:   https://github.com/csmith-project/csmith
  Commit: 5ca737d05133d0283493e7a218dcbac0657127bd
      https://github.com/csmith-project/csmith/commit/5ca737d05133d0283493e7a218dcbac0657127bd
  Author: Ali Shuja Siddiqui <alishuja@gmail.com>
  Date:   2021-01-13 (Wed, 13 Jan 2021)

  Changed paths:
    M src/Bookkeeper.cpp
    M src/Bookkeeper.h
    M src/CGOptions.cpp
    M src/CGOptions.h
    M src/Probabilities.cpp
    M src/Probabilities.h
    M src/RandomProgramGenerator.cpp
    M src/StatementFor.cpp

  Log Message:
  -----------
  Adds Index out-of-bound probability option to csmith (#113)

* Adds Index out-of-bound probability option to csmith
Using the --add-oob-prob flag csmith can be used to generate code
that may result in an index out-of-bound (OOB) situation. This
patch may be helpful in making testcases for utilities used for
performing crash-analysis and fault triage.

* Requested update to PR#113
- The argument is now --array-oob-prob
- Fixed indentation
- Removed unnecessary comments
- Set lower limit (for decrementing loops) and init  (for
incrementing loop). Tests with very low limit and init values only
result in almost endless loops in cases where arrays are not
accessed within these loops. --array-oob-prob has been seen to work
better when used with higher value --max-array-dim argument.

* Add bookkeeping statistics for PR#113

Co-authored-by: Ali Shuja Siddiqui <alissidd@cisco.com>