morehouse accepted this revision.
morehouse added inline comments.
This revision is now accepted and ready to land.


================
Comment at: clang/tools/clang-fuzzer/handle-llvm/handle_llvm.cpp:132
+// Takes a string of IR and compiles it using LLVM's JIT Engine
+static void CreateJITFunc(const std::string &IR, CodeGenOpt::Level OLvl) {
   SMDiagnostic Err;
----------------
`CreateAndRunJITFunc` describes this better.


================
Comment at: clang/tools/clang-fuzzer/handle-llvm/input_arrays.h:36
+  {1, 1, 2, 3, 2, 3, 0, 11, 10, 0, 7, 5, 3, 1, 18, 18, 18, 18, 0, 18, 18, 18, 
18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 
18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 
18, 18},
+  {0, 0, 2, 5, 4, 0, 2, 13, 12, 11, 0, 8, 6, 4, 2, 0, 20, 20, 20, 20, 0, 20, 
20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 
20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 
20, 20},
+  {1, 1, 0, 1, 6, 2, 4, 1, 14, 13, 12, 0, 9, 7, 5, 3, 1, 22, 22, 22, 22, 22, 
0, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 
22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 
22, 22},
----------------
emmettneyman wrote:
> kcc wrote:
> > constants are not diverse enough. 
> Yeah, I will completely redo the input arrays.
Please land today once you do.


================
Comment at: clang/tools/clang-fuzzer/handle-llvm/input_arrays.h:15
+#include <iostream>
+#include <string.h>
+
----------------
Are these includes needed?


================
Comment at: clang/tools/clang-fuzzer/handle-llvm/input_arrays.h:19
+static const int NumArrays = 100;
+static const int TotalSize = sizeof(int) * ArraySize * NumArrays;
+
----------------
Maybe prefix these names with `k` since they are constant.


Repository:
  rC Clang

https://reviews.llvm.org/D50194



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to