This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Demangler fuzzer
- From: Gary Benson <gbenson at redhat dot com>
- To: Ian Lance Taylor <iant at google dot com>
- Cc: Jakub Jelinek <jakub at redhat dot com>, David Malcolm <dmalcolm at redhat dot com>, Andi Kleen <andi at firstfloor dot org>, gcc-patches <gcc-patches at gcc dot gnu dot org>
- Date: Tue, 12 Aug 2014 18:11:59 +0100
- Subject: Re: [PATCH] Demangler fuzzer
- Authentication-results: sourceware.org; auth=none
- References: <20140811092703 dot GA3193 at blade dot nx> <87bnrrjcbo dot fsf at tassilo dot jf dot intel dot com> <1407769769 dot 28418 dot 66 dot camel at surprise> <20140811160420 dot GA3355 at blade dot nx> <20140811175710 dot GD1784 at tucnak dot redhat dot com> <20140812090240 dot GA15234 at blade dot nx> <CAKOQZ8x3pR0QG-8hJqgM5uuXkxKuPZvyycUzgvg4hWn3xjCBLg at mail dot gmail dot com>
Ian Lance Taylor wrote:
> On Tue, Aug 12, 2014 at 2:02 AM, Gary Benson <gbenson@redhat.com> wrote:
> > +#include <demangle.h>
>
> Include demangle.h with "".
Ok.
> > +int
> > +main (int argc, char *argv[])
> > +{
> > + char symbol[2 + MAXLEN + 1] = "_Z";
> > + int seed = -1, seed_set = 0;
> > + int count = 0, maxcount = -1;
>
> I think that by default the program should stop. That will make it
> possible to eventually run as part of "make check". Give it some
> number of iterations that stops it in a second or so. You can still
> have it run forever by using -m -1.
On my machine it usually fails in 3-5 seconds, so a 1 second run seems
a little too short. How does 10 seconds sound?
Thanks,
Gary
--
http://gbenson.net/