-
Notifications
You must be signed in to change notification settings - Fork 373
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Save corpus continuously while fuzzing; add TestSimplified and ErrorEvent events; change event system #1048
Conversation
be5ca8a
to
bbf3f58
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great work! We can do a few improvements to make it more robust.
42b0ba0
to
c0e3206
Compare
|
||
-- mainly for handling events, but can be used for any purpose | ||
-- `wait` is called on this group before echidna closes | ||
, threadGroup :: ThreadGroup |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should move this to spawnListener
and make all the handlers spawned async
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure I understand what you mean here? I got rid of spawnListener
, and all handlers are spawned async now
@@ -127,6 +131,8 @@ main = withUtf8 $ withCP65001 $ do | |||
|
|||
tests <- readIORef testsRef | |||
|
|||
ThreadGroup.wait threadGroup |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should move this to spawnListener
before putMVar stopVar ()
8a2fca4
to
e3b86cd
Compare
e3b86cd
to
a6faa99
Compare
Done in #1167. |
This PR:
unsimplified-
IORef [event -> IO ()]
instead of channels. Channels were annoying because you would have to duplicate the channel and make a new thread for each event handlerspawnThread
andawaitThreads
helper functions to spawn temporary threads and wait for all threads to be finished (in this PR used to save files, so that the worker doesn't have to wait while the file is saved)-12345.txt
files(Most of these changes are just solutions to problems I encountered while trying to make echidna save corpus while fuzzing)
Replaces #1047