[all-commits] [llvm/llvm-project] 166d40: [FuzzMutate] Add mutator to modify instruction flags.

Florian Hahn via All-commits all-commits at lists.llvm.org
Sat Jan 23 11:10:22 PST 2021


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 166d40f2ed3db1ddd2868b23d496b4e299d99533
      https://github.com/llvm/llvm-project/commit/166d40f2ed3db1ddd2868b23d496b4e299d99533
  Author: Florian Hahn <flo at fhahn.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M llvm/include/llvm/FuzzMutate/IRMutator.h
    M llvm/lib/FuzzMutate/IRMutator.cpp
    M llvm/tools/llvm-opt-fuzzer/llvm-opt-fuzzer.cpp
    M llvm/unittests/FuzzMutate/StrategiesTest.cpp

  Log Message:
  -----------
  [FuzzMutate] Add mutator to modify instruction flags.

This patch adds a new InstModificationIRStrategy to mutate flags/options
for instructions. For example, it may add or remove nuw/nsw flags from
add, mul, sub, shl instructions or change the predicate for icmp
instructions.

Subtle changes such as those mentioned above should lead to a more
interesting range of inputs. The presence or absence of overflow flags
can expose subtle bugs, for example.

Reviewed By: bogner

Differential Revision: https://reviews.llvm.org/D94905




More information about the All-commits mailing list