[PATCH] D43384: [llvm-opt-fuzzer] Add another pack of passes for continuous fuzzing
Igor Laevsky via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Feb 16 06:51:17 PST 2018
igor-laevsky created this revision.
igor-laevsky added reviewers: bogner, kcc.
I'm planning on expanding continuous fuzzer runs with another bunch of passes, this time mostly loop-oriented.
https://reviews.llvm.org/D43384
Files:
lib/FuzzMutate/FuzzerCLI.cpp
Index: lib/FuzzMutate/FuzzerCLI.cpp
===================================================================
--- lib/FuzzMutate/FuzzerCLI.cpp
+++ lib/FuzzMutate/FuzzerCLI.cpp
@@ -83,16 +83,36 @@
SmallVector<StringRef, 4> Opts;
NameAndArgs.second.split(Opts, '-');
for (StringRef Opt : Opts) {
- if (Opt.startswith("instcombine")) {
+ if (Opt == "instcombine") {
Args.push_back("-passes=instcombine");
- } else if (Opt.startswith("earlycse")) {
+ } else if (Opt == "earlycse") {
Args.push_back("-passes=early-cse");
- } else if (Opt.startswith("simplifycfg")) {
+ } else if (Opt == "simplifycfg") {
Args.push_back("-passes=simplify-cfg");
- } else if (Opt.startswith("gvn")) {
+ } else if (Opt == "gvn") {
Args.push_back("-passes=gvn");
- } else if (Opt.startswith("sccp")) {
+ } else if (Opt == "sccp") {
Args.push_back("-passes=sccp");
+
+ } else if (Opt == "loop_predication") {
+ Args.push_back("-passes=loop-predication");
+ } else if (Opt == "guard_widening") {
+ Args.push_back("-passes=guard-widening");
+ } else if (Opt == "loop_rotate") {
+ Args.push_back("-passes=loop(rotate)");
+ } else if (Opt == "loop_unswitch") {
+ Args.push_back("-passes=loop(unswitch)");
+ } else if (Opt == "loop_unroll") {
+ Args.push_back("-passes=unroll");
+ } else if (Opt == "loop_vectorize") {
+ Args.push_back("-passes=loop-vectorize");
+ } else if (Opt == "licm") {
+ Args.push_back("-passes=licm");
+ } else if (Opt == "indvars") {
+ Args.push_back("-passes=indvars");
+ } else if (Opt == "strength_reduce") {
+ Args.push_back("-passes=strength-reduce");
+
} else if (Triple(Opt).getArch()) {
Args.push_back("-mtriple=" + Opt.str());
} else {
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D43384.134607.patch
Type: text/x-patch
Size: 1806 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180216/10d36292/attachment.bin>
More information about the llvm-commits
mailing list