[compiler-rt] 22a376e - [libFuzzer] Expose fuzzer::FuzzerDriver()

Mitch Phillips via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 23 12:08:45 PDT 2020


Author: Mitch Phillips
Date: 2020-07-23T12:08:14-07:00
New Revision: 22a376e73bc218137738ee4ac8af44e223576475

URL: https://github.com/llvm/llvm-project/commit/22a376e73bc218137738ee4ac8af44e223576475
DIFF: https://github.com/llvm/llvm-project/commit/22a376e73bc218137738ee4ac8af44e223576475.diff

LOG: [libFuzzer] Expose fuzzer::FuzzerDriver()

Summary:
Allows other-language libFuzzer derivatives to invoke the driver.

Patch By: Ian Eldred Pudney <ipudney at google.com>

Reviewers: morehouse, kcc

Reviewed By: morehouse

Subscribers: #sanitizers

Tags: #sanitizers

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

Added: 
    

Modified: 
    compiler-rt/lib/fuzzer/FuzzerDefs.h

Removed: 
    


################################################################################
diff  --git a/compiler-rt/lib/fuzzer/FuzzerDefs.h b/compiler-rt/lib/fuzzer/FuzzerDefs.h
index 1a2752af2f4d..fb9eccd46324 100644
--- a/compiler-rt/lib/fuzzer/FuzzerDefs.h
+++ b/compiler-rt/lib/fuzzer/FuzzerDefs.h
@@ -20,6 +20,7 @@
 #include <string>
 #include <vector>
 
+#include "FuzzerPlatform.h"
 
 namespace fuzzer {
 
@@ -62,7 +63,8 @@ typedef Vector<uint8_t> Unit;
 typedef Vector<Unit> UnitVector;
 typedef int (*UserCallback)(const uint8_t *Data, size_t Size);
 
-int FuzzerDriver(int *argc, char ***argv, UserCallback Callback);
+ATTRIBUTE_INTERFACE int FuzzerDriver(int *argc, char ***argv,
+                                     UserCallback Callback);
 
 uint8_t *ExtraCountersBegin();
 uint8_t *ExtraCountersEnd();


        


More information about the llvm-commits mailing list