On Tue, Jan 09, 2018 at 11:41:17AM +0100, Martin Liška wrote:
> Folowing static assert is added as we may potentially adjust
> ASAN_SHADOW_GRANULARITY
> (via ASAN_SHADOW_SHIFT). The assert ensures stack variables will have
> sufficient
> alignment.
>
> Patch can bootstrap on ppc64le-redhat-linux and survives regression tests.
>
> Ready to be installed?
> Martin
>
> gcc/ChangeLog:
>
> 2018-01-09 Martin Liska <[email protected]>
>
> PR sanitizer/82517
> * asan.c (shadow_mem_size): Add static assert.
STATIC_ASSERT assumes all the 3 macros expand to constants, not sure if we
for the future can always guarantee it, e.g. MAX_SUPPORTED_STACK_ALIGNMENT
could be dependent on some command line option etc.
Use gcc_assert or gcc_checking_assert instead?
Jakub