[erlang-questions] Help find bugs before OTP-18.0 is released

Tuncer Ayaz tuncer.ayaz@REDACTED
Wed Sep 24 00:11:39 CEST 2014


On Wed, Sep 24, 2014 at 12:00 AM, Shayan Pooya wrote:
> I tried building the source code with gcc 4.8.3 and it complains:
> >
> > gcc: error: unrecognized command line option
> > ‘-fsanitize=address,undefined’
>
>
> It seems like this option is added to gcc 4.9:
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60275

Sorry about that, I've tested UBSan only with gcc 4.9, so that
information was incorrect.

But ASan is available in 4.8.3, right?

Also, I forgot to say that issues found should be reported to
erlang-bugs@REDACTED

> On Tue, Sep 23, 2014 at 4:59 PM, Tuncer Ayaz wrote:
> >
> > Now that the --enable-sanitizers patch has been merged, it would be
> > great if more users could test their code with an OTP install built
> > with one or more sanitizers enabled in a dev/test environment. To be
> > clear, it's _not_ a good idea to use in a production node.
> >
> > So far using only UBSan (undefined behavior sanitizer), we already
> > found a couple bugs in the VM, and there's still time to find and fix
> > more issues before OTP-18.0.
> >
> > The way sanitizers work is that the generated code is instrumented to
> > find bugs at runtime. Basically, such an Erlang/OTP install will print
> > what condition it encountered and possibly terminate.
> >
> > If you're interested and are using gcc >= 4.8 or clang >= 3.3, just
> > make sure to enable it during ./configure as follows:
> >
> > # enable only undefined behavior sanitizer
> > $ ./configure <your_usual_flags> --enable-sanitizers=undefined
> >
> > # enable both address sanitizer and undefined behavior sanitizer
> > $ ./configure <your_usual_flags> --enable-sanitizers
> >
> > # enable just address sanitizer
> > $ ./configure <your_usual_flags> --enable-sanitizers=address
> >
> > There are heavier and more specific sanitizers you can enable, and if
> > you'd like to learn more, see the following links:
> > http://clang.llvm.org/docs/UsersManual.html#controlling-code-generation
> > https://code.google.com/p/address-sanitizer/
> > http://clang.llvm.org/docs/AddressSanitizer.html
> > https://code.google.com/p/thread-sanitizer/
> > http://clang.llvm.org/docs/ThreadSanitizer.html



More information about the erlang-questions mailing list