[PATCH] D46666: [libFuzzer] Experimental data flow tracer for fuzz targets.

Matt Morehouse via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu May 10 11:17:35 PDT 2018


morehouse accepted this revision.
morehouse added inline comments.


================
Comment at: lib/fuzzer/dataflow/DataFlow.cpp:59
+"Li j k": describes the label 'i' as a union of labels 'j' and 'k'.
+"Ff l": tells that the function 'f' depends on the label 'l'.
+//===----------------------------------------------------------------------===*/
----------------
Nit:  Why mix `//` comment style with `/* ... */`?


================
Comment at: lib/fuzzer/dataflow/DataFlow.cpp:162
+  for (uint32_t *x = start; x < stop; x++)
+    *x = x - start;
+  NumFuncs += stop - start;
----------------
I think a simple counter variable would be clearer here.


================
Comment at: lib/fuzzer/dataflow/DataFlow.cpp:183
+void __dfsw___sanitizer_cov_trace_switch(uint64_t Val, uint64_t *Cases,
+                                         dfsan_label L1) {
+  assert(CurrentFunc < NumFuncs);
----------------
Does DFSan require a second label here since there's 2 parameters in the original signature?


================
Comment at: test/fuzzer/dataflow.test:28
+IN_ABC: F{{[012]}} 4
+IN_ABC-NO: F
+
----------------
`IN_ABC-NOT`?


Repository:
  rCRT Compiler Runtime

https://reviews.llvm.org/D46666





More information about the llvm-commits mailing list