public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Konstantin Serebryany <konstantin.s.serebryany@gmail.com>
To: Peter Bergner <bergner@vnet.ibm.com>
Cc: Jakub Jelinek <jakub@redhat.com>,
	"gcc-patches@gcc.gnu.org" <gcc-patches@gcc.gnu.org>
Subject: Re: [PATCH, RFC] Enable libsanitizer on powerpc{,64}
Date: Mon, 19 Nov 2012 15:29:00 -0000	[thread overview]
Message-ID: <CAGQ9bdzHKDuMdbn7DjEh7UfuAvBUBkH2qQjfc+iDAFcop3S=8Q@mail.gmail.com> (raw)
In-Reply-To: <1353336570.17833.42.camel@otta>

On Mon, Nov 19, 2012 at 6:49 PM, Peter Bergner <bergner@vnet.ibm.com> wrote:
> On Mon, 2012-11-19 at 15:29 +0100, Jakub Jelinek wrote:
>> On Fri, Nov 16, 2012 at 05:08:06PM -0600, Peter Bergner wrote:
>> > One question that I have is that the toplev.c test for port support
>> > tests for !FRAME_GROWS_DOWNWARD.  The rs6000 port has FRAME_GROWS_DOWNWARD
>> > defined as (flag_stack_protect != 0), so ASAN only works when we use
>> > -fstack-protector.  Is there a technical reason why FRAME_GROWS_DOWNWARD
>> > must be false?
>>
>> It would be way too much work to support FRAME_GROWS_DOWNWARD.
>
> Do you you have a pointer or a reference that describes why ASAN
> relies on that?

The only part where I know for sure that asan relies on stack growing
down is the custom unwinder, which is not applicable to PowerPC
anyway.
Another suspect is the way we poison redzones in the stack frame and
report an error if one found, but It may actually just work.
If the tests pass, I would say it indeed just works.


> I don't doubt you are correct, but for my own
> education, I'd like to know the reason.
>
>
>> IMHO far simple for targets like ppc is to define
>> FRAME_GROWS_DOWNWARD as (flag_stack_protect != 0 || flag_address_sanitizer != 0).
>
> That looks like a better idea than what I was thinking of, so
> I'll go ahead and add that to our target patch.  Thanks!
>
> Peter
>
>
>

  parent reply	other threads:[~2012-11-19 15:29 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-16 23:08 Peter Bergner
2012-11-16 23:48 ` Konstantin Serebryany
     [not found]   ` <CACT4Y+YzjEMeo0ZaFUcaiO4QNAJ-EhfAO+zeh0XXYaT70-sdvA@mail.gmail.com>
2012-11-19 14:24     ` Peter Bergner
2012-11-19 20:07   ` Peter Bergner
2012-11-20  7:08     ` Konstantin Serebryany
2012-11-20 13:41       ` Peter Bergner
2012-11-20 13:53         ` Konstantin Serebryany
2012-11-20 18:09           ` Peter Bergner
2012-11-20 18:54             ` Konstantin Serebryany
     [not found]           ` <CABMLtrioRsU18HqOqWzJ2toNOGUFOBZSp-ODRFrgzAnp84c0dw@mail.gmail.com>
2012-11-20 14:21             ` Konstantin Serebryany
2012-11-20 14:47               ` Dmitry Vyukov
2012-11-20 15:12                 ` Evgeniy Stepanov
2012-11-20 15:17                   ` Konstantin Serebryany
2012-11-20 19:08             ` Peter Bergner
2012-11-20 19:24               ` Konstantin Serebryany
2012-11-20 20:20                 ` Peter Bergner
2012-11-20 20:36                   ` Richard Henderson
2012-11-20 22:15                     ` Peter Bergner
2012-11-20 22:27                       ` Richard Henderson
2012-11-21  9:47                         ` Evgeniy Stepanov
2012-11-21 16:16                           ` Peter Bergner
2012-11-21 16:23                             ` Konstantin Serebryany
2012-11-21 17:14                               ` Peter Bergner
     [not found]                                 ` <CABMLtriDyx+38pvRRQma+rrb0V0mLpU8CnCzVgcv9VZc12Ohew@mail.gmail.com>
2012-11-22  8:38                                   ` Evgeniy Stepanov
2012-11-22 17:36                                     ` Konstantin Serebryany
2012-11-19  8:23 ` Konstantin Serebryany
2012-11-19 14:30 ` Jakub Jelinek
2012-11-19 14:50   ` Peter Bergner
2012-11-19 15:06     ` Jakub Jelinek
2012-11-19 15:29     ` Konstantin Serebryany [this message]
2012-11-19 15:32       ` Jakub Jelinek

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAGQ9bdzHKDuMdbn7DjEh7UfuAvBUBkH2qQjfc+iDAFcop3S=8Q@mail.gmail.com' \
    --to=konstantin.s.serebryany@gmail.com \
    --cc=bergner@vnet.ibm.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=jakub@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).