public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/64459] __attribute__((returns_nonnull)) creates wrong code on amd64
[not found] <bug-64459-4@http.gcc.gnu.org/bugzilla/>
@ 2014-12-31 18:57 ` pinskia at gcc dot gnu.org
2014-12-31 18:58 ` pinskia at gcc dot gnu.org
` (3 subsequent siblings)
4 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu.org @ 2014-12-31 18:57 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64459
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |WAITING
Last reconfirmed| |2014-12-31
Ever confirmed|0 |1
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
> Since we use 992 returns_nonnull annotated functions in parrot, the bisect
> which function and asm exactly is the problem will need some time...
Without this, it is hard to tell if this is a bug in GCC or parrot. So waiting
on a testcase that shows the problem.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c/64459] __attribute__((returns_nonnull)) creates wrong code on amd64
[not found] <bug-64459-4@http.gcc.gnu.org/bugzilla/>
2014-12-31 18:57 ` [Bug c/64459] __attribute__((returns_nonnull)) creates wrong code on amd64 pinskia at gcc dot gnu.org
@ 2014-12-31 18:58 ` pinskia at gcc dot gnu.org
2015-01-01 0:36 ` rurban@x-ray.at
` (2 subsequent siblings)
4 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu.org @ 2014-12-31 18:58 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64459
--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Maybe parrot has some code it where returns_nonnull is on the function but it
actually can return null and clang/MSVC does not optimize as good as GCC does.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c/64459] __attribute__((returns_nonnull)) creates wrong code on amd64
[not found] <bug-64459-4@http.gcc.gnu.org/bugzilla/>
2014-12-31 18:57 ` [Bug c/64459] __attribute__((returns_nonnull)) creates wrong code on amd64 pinskia at gcc dot gnu.org
2014-12-31 18:58 ` pinskia at gcc dot gnu.org
@ 2015-01-01 0:36 ` rurban@x-ray.at
2015-01-01 9:37 ` rurban@x-ray.at
2015-01-19 20:06 ` jakub at gcc dot gnu.org
4 siblings, 0 replies; 5+ messages in thread
From: rurban@x-ray.at @ 2015-01-01 0:36 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64459
Reini Urban <rurban@x-ray.at> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|WAITING |RESOLVED
Resolution|--- |INVALID
--- Comment #3 from Reini Urban <rurban@x-ray.at> ---
This ticket can be closed, not a bug.
My test script finished after some hours of grinding,
which tested all of the 992 returns_nonnull annotated functions in parrot.
Disabling returns_nonnull on one function made it work.
I've checked the assembly.
It was Parrot_cx_check_scheduler(), which had a wrong
if (Parrot_cx_check_scheduler(...) == 0)
check, and consequently this branch was removed by gcc.
So it's really a missed clang and msvc dead-code removal opportunity.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c/64459] __attribute__((returns_nonnull)) creates wrong code on amd64
[not found] <bug-64459-4@http.gcc.gnu.org/bugzilla/>
` (2 preceding siblings ...)
2015-01-01 0:36 ` rurban@x-ray.at
@ 2015-01-01 9:37 ` rurban@x-ray.at
2015-01-19 20:06 ` jakub at gcc dot gnu.org
4 siblings, 0 replies; 5+ messages in thread
From: rurban@x-ray.at @ 2015-01-01 9:37 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64459
--- Comment #4 from Reini Urban <rurban@x-ray.at> ---
maybe the script is of value to anyone:
https://gist.github.com/rurban/b8b951d03ff22734f05b
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c/64459] __attribute__((returns_nonnull)) creates wrong code on amd64
[not found] <bug-64459-4@http.gcc.gnu.org/bugzilla/>
` (3 preceding siblings ...)
2015-01-01 9:37 ` rurban@x-ray.at
@ 2015-01-19 20:06 ` jakub at gcc dot gnu.org
4 siblings, 0 replies; 5+ messages in thread
From: jakub at gcc dot gnu.org @ 2015-01-19 20:06 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64459
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jakub at gcc dot gnu.org
--- Comment #5 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
GCC5 supports in -fsanitize=undefined runtime warning or error when
returns_nonnull function does return NULL, so in theory it should be able to
tell you without such script.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2015-01-19 20:06 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <bug-64459-4@http.gcc.gnu.org/bugzilla/>
2014-12-31 18:57 ` [Bug c/64459] __attribute__((returns_nonnull)) creates wrong code on amd64 pinskia at gcc dot gnu.org
2014-12-31 18:58 ` pinskia at gcc dot gnu.org
2015-01-01 0:36 ` rurban@x-ray.at
2015-01-01 9:37 ` rurban@x-ray.at
2015-01-19 20:06 ` jakub at gcc dot gnu.org
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).