All of lore.kernel.org
 help / color / mirror / Atom feed
* ppc64 asan issue
@ 2019-02-12 11:03 Joel Stanley
  2019-02-12 19:31 ` William Kennington
  0 siblings, 1 reply; 3+ messages in thread
From: Joel Stanley @ 2019-02-12 11:03 UTC (permalink / raw)
  To: William A. Kennington III, OpenBMC Maillist; +Cc: Michael Ellerman

Hi William,

I saw this change to our build scripts, where we disable the sanitiser
for ppc64:

https://github.com/openbmc/openbmc-build-scripts/commit/282e33011ea62fe80bff2c5ab0e9ef9446d6c551

It would be great if you could open a bug report about this one. As a
starting point it should file it against GCC, but even an openbmc
issue would be a good start.

I did some investigation myself and I could reproduce the failure on
GCC 7 on Ubuntu 18.04 ppc64le. It didn't happen with GCC 8, nor with
GCC trunk.

However even GCC 7 took a few compiles before I started hitting the
issue, so my testing may have not been comprehensive.

Cheers,

Joel

--
My testing looked like this:

$ cat san.c
#include <stdlib.h>
#include <stdio.h>

int main()
{
    void *p = malloc(4);
    printf("%p\n", p);
    return 0;
}
$ gcc -fsanitize=address -o san{,.c}
$ ./san

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: ppc64 asan issue
  2019-02-12 11:03 ppc64 asan issue Joel Stanley
@ 2019-02-12 19:31 ` William Kennington
  2019-02-13  4:38   ` Michael Ellerman
  0 siblings, 1 reply; 3+ messages in thread
From: William Kennington @ 2019-02-12 19:31 UTC (permalink / raw)
  To: Joel Stanley; +Cc: OpenBMC Maillist, Michael Ellerman

I'm doing autodetection for it now, but it is something I need to test
with a compiler closer to upstream.
https://github.com/openbmc/openbmc-build-scripts/commit/0b7fb2bcfd603949f9999127f56e3fc0e0351fbc

On Tue, Feb 12, 2019 at 3:03 AM Joel Stanley <joel@jms.id.au> wrote:
>
> Hi William,
>
> I saw this change to our build scripts, where we disable the sanitiser
> for ppc64:
>
> https://github.com/openbmc/openbmc-build-scripts/commit/282e33011ea62fe80bff2c5ab0e9ef9446d6c551
>
> It would be great if you could open a bug report about this one. As a
> starting point it should file it against GCC, but even an openbmc
> issue would be a good start.
>
> I did some investigation myself and I could reproduce the failure on
> GCC 7 on Ubuntu 18.04 ppc64le. It didn't happen with GCC 8, nor with
> GCC trunk.
>
> However even GCC 7 took a few compiles before I started hitting the
> issue, so my testing may have not been comprehensive.
>
> Cheers,
>
> Joel
>
> --
> My testing looked like this:
>
> $ cat san.c
> #include <stdlib.h>
> #include <stdio.h>
>
> int main()
> {
>     void *p = malloc(4);
>     printf("%p\n", p);
>     return 0;
> }
> $ gcc -fsanitize=address -o san{,.c}
> $ ./san

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: ppc64 asan issue
  2019-02-12 19:31 ` William Kennington
@ 2019-02-13  4:38   ` Michael Ellerman
  0 siblings, 0 replies; 3+ messages in thread
From: Michael Ellerman @ 2019-02-13  4:38 UTC (permalink / raw)
  To: William Kennington, Joel Stanley; +Cc: OpenBMC Maillist

William Kennington <wak@google.com> writes:
> I'm doing autodetection for it now, but it is something I need to test
> with a compiler closer to upstream.
> https://github.com/openbmc/openbmc-build-scripts/commit/0b7fb2bcfd603949f9999127f56e3fc0e0351fbc

For me on 18.04 with GCC 8 it works OK (just a small test program, not
openbmc). Whereas with GCC 7 I get ASAN asserts when compiling.

So I wonder what exact GCC 8 version you're using.

I have: gcc-8 (Ubuntu 8.2.0-1ubuntu2~18.04) 8.2.0


There's a GCC bug tracking some backports to GCC 8:
  https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89308

But it's not clear if they will fix your problem or not.

cheers

> On Tue, Feb 12, 2019 at 3:03 AM Joel Stanley <joel@jms.id.au> wrote:
>>
>> Hi William,
>>
>> I saw this change to our build scripts, where we disable the sanitiser
>> for ppc64:
>>
>> https://github.com/openbmc/openbmc-build-scripts/commit/282e33011ea62fe80bff2c5ab0e9ef9446d6c551
>>
>> It would be great if you could open a bug report about this one. As a
>> starting point it should file it against GCC, but even an openbmc
>> issue would be a good start.
>>
>> I did some investigation myself and I could reproduce the failure on
>> GCC 7 on Ubuntu 18.04 ppc64le. It didn't happen with GCC 8, nor with
>> GCC trunk.
>>
>> However even GCC 7 took a few compiles before I started hitting the
>> issue, so my testing may have not been comprehensive.
>>
>> Cheers,
>>
>> Joel
>>
>> --
>> My testing looked like this:
>>
>> $ cat san.c
>> #include <stdlib.h>
>> #include <stdio.h>
>>
>> int main()
>> {
>>     void *p = malloc(4);
>>     printf("%p\n", p);
>>     return 0;
>> }
>> $ gcc -fsanitize=address -o san{,.c}
>> $ ./san

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-02-13  4:38 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-02-12 11:03 ppc64 asan issue Joel Stanley
2019-02-12 19:31 ` William Kennington
2019-02-13  4:38   ` Michael Ellerman

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.