[Bug sanitizer/101744] [12 regression] hwasan new failures since r12-2424

2022-03-08 Thread rguenth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101744

Richard Biener  changed:

   What|Removed |Added

 Resolution|--- |FIXED
 Status|UNCONFIRMED |RESOLVED

--- Comment #9 from Richard Biener  ---
Fixed.

[Bug sanitizer/101744] [12 regression] hwasan new failures since r12-2424

2021-12-19 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101744

--- Comment #8 from Andrew Pinski  ---
I think this is fixed.

[Bug sanitizer/101744] [12 regression] hwasan new failures since r12-2424

2021-08-05 Thread matmal01 at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101744

--- Comment #7 from Matthew Malcomson  ---
Hi there,

I didn't check all the new tests that Christophe mentioned, but all those I
checked had `dg-require-effective-target hwaddress_exec` in them.

The test that determines that effective target should only pass with a modern
enough kernel (one that supports passing tagged pointers to its syscalls).
It is still failing on my native AArch64 machine.

For anyone that is seeing them -- what kernel version are you running?
If your kernel has not changed could you manually run the check and see if it
passes and why?

I've unfortunately lost my testing environment.  I'm working on getting it back
but will be a while before I can see if I can reproduce the failures on a
machine with the required kernel.

[Bug sanitizer/101744] [12 regression] hwasan new failures since r12-2424

2021-08-04 Thread crazylht at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101744

--- Comment #6 from Hongtao.liu  ---
(In reply to Martin Liška from comment #5)
> > > ``` 
> > Just want to clarify that it's our developping lam version which is at
> > https://gitlab.com/x86-gcc/gcc/-/tree/users/intel/lam/master
> 
> What can you see for a vanilla GCC compiler?

hwasan is not enabled by x86 on the trunk which means there must be no impact
for a vanilla x86 GCC compiler.

[Bug sanitizer/101744] [12 regression] hwasan new failures since r12-2424

2021-08-04 Thread marxin at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101744

--- Comment #5 from Martin Liška  ---
> > ``` 
> Just want to clarify that it's our developping lam version which is at
> https://gitlab.com/x86-gcc/gcc/-/tree/users/intel/lam/master

What can you see for a vanilla GCC compiler?

[Bug sanitizer/101744] [12 regression] hwasan new failures since r12-2424

2021-08-04 Thread crazylht at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101744

--- Comment #4 from Hongtao.liu  ---
(In reply to Hongtao.liu from comment #3)
> x86 also get 2 new failures
> ```
> FAIL: c-c++-common/hwasan/alloca-gets-different-tag.c   -O2 -flto
> -fuse-linker-plugin -fno-fat-lto-objects  execution test
> FAIL: c-c++-common/hwasan/alloca-outside-caught.c   -O2 -flto
> -fuse-linker-plugin -fno-fat-lto-objects  output pattern test
> ``` 
Just want to clarify that it's our developping lam version which is at
https://gitlab.com/x86-gcc/gcc/-/tree/users/intel/lam/master

[Bug sanitizer/101744] [12 regression] hwasan new failures since r12-2424

2021-08-04 Thread crazylht at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101744

Hongtao.liu  changed:

   What|Removed |Added

 CC||crazylht at gmail dot com

--- Comment #3 from Hongtao.liu  ---
x86 also get 2 new failures
```
FAIL: c-c++-common/hwasan/alloca-gets-different-tag.c   -O2 -flto
-fuse-linker-plugin -fno-fat-lto-objects  execution test
FAIL: c-c++-common/hwasan/alloca-outside-caught.c   -O2 -flto
-fuse-linker-plugin -fno-fat-lto-objects  output pattern test
``` 

And failure is because pointer passes to __hwasan_tag_memory is supposed to be
untagged(it will call TagMemoryAligned and then call MemToShadow where it shift
the address w/ kShadowScale(here is 4).

inline uptr MemToShadow(uptr untagged_addr) {
  return (untagged_addr >> kShadowScale) + GetShadowOffset();
}

And for local arrays which need to be tagged, pointer passed to
__hwasan_tag_memory is rsp+offset where rsp is not tagged, and this should be
ok, but sometimes gcc will do optimization to convert rsp+offset to rbp+offset,
but rbp is tagged, then it will raise an exception of  SGEV SGEV for illegal
address.

[Bug sanitizer/101744] [12 regression] hwasan new failures since r12-2424

2021-08-03 Thread marxin at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101744

Martin Liška  changed:

   What|Removed |Added

 CC||matmal01 at gcc dot gnu.org

--- Comment #2 from Martin Liška  ---
I can see just few failures on a native system:

FAIL: c-c++-common/hwasan/alloca-gets-different-tag.c   -O2 -flto
-fuse-linker-plugin -fno-fat-lto-objects  execution test
FAIL: c-c++-common/hwasan/alloca-outside-caught.c   -O2 -flto
-fuse-linker-plugin -fno-fat-lto-objects  output pattern test
FAIL: c-c++-common/hwasan/alloca-gets-different-tag.c   -O2 -flto
-fuse-linker-plugin -fno-fat-lto-objects  execution test
FAIL: c-c++-common/hwasan/alloca-outside-caught.c   -O2 -flto
-fuse-linker-plugin -fno-fat-lto-objects  output pattern test

CCing Matthew

[Bug sanitizer/101744] [12 regression] hwasan new failures since r12-2424

2021-08-03 Thread rguenth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101744

Richard Biener  changed:

   What|Removed |Added

   Target Milestone|--- |12.0
 Target||aarch64

[Bug sanitizer/101744] [12 regression] hwasan new failures since r12-2424

2021-08-03 Thread schwab--- via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101744

--- Comment #1 from Andreas Schwab  ---
*** Bug 101745 has been marked as a duplicate of this bug. ***