[Bug libfortran/67535] write.c sanitizer detects null pointer passed to memcpy

2015-09-12 Thread fxcoudert at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67535 --- Comment #7 from Francois-Xavier Coudert --- Author: fxcoudert Date: Sat Sep 12 12:05:44 2015 New Revision: 227705 URL: https://gcc.gnu.org/viewcvs?rev=227705=gcc=rev Log: PR libfortran/67527 PR libfortran/67535 PR

[Bug libfortran/67535] write.c sanitizer detects null pointer passed to memcpy

2015-09-12 Thread fxcoudert at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67535 Francois-Xavier Coudert changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED CC|

[Bug libfortran/67535] write.c sanitizer detects null pointer passed to memcpy

2015-09-11 Thread zeccav at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67535 --- Comment #6 from Vittorio Zecca --- The cost of adding "if(base_name_len)" is two x86-64 machine instructions cmpl$0, -20(%rbp) je .L2 Six instructions follow then call memcpy which is not exactly a NOP

[Bug libfortran/67535] write.c sanitizer detects null pointer passed to memcpy

2015-09-10 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67535 Jakub Jelinek changed: What|Removed |Added CC||jakub at gcc dot gnu.org --- Comment #2

[Bug libfortran/67535] write.c sanitizer detects null pointer passed to memcpy

2015-09-10 Thread zeccav at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67535 --- Comment #3 from Vittorio Zecca --- (In reply to kargl from comment #1) > What happens to performance? Simply making changes to > make sanitizer happy seems rather questionable. It's clear > from context that if base_name == NULL, then

[Bug libfortran/67535] write.c sanitizer detects null pointer passed to memcpy

2015-09-10 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67535 --- Comment #5 from Jakub Jelinek --- (In reply to Steve Kargl from comment #4) > It's undefined behavior to pass a NULL pointer into a function? To a function that does not allow it? Yes. Citing the C standard: 7.21.2.1/2: "The memcpy

[Bug libfortran/67535] write.c sanitizer detects null pointer passed to memcpy

2015-09-10 Thread sgk at troutmask dot apl.washington.edu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67535 --- Comment #4 from Steve Kargl --- On Thu, Sep 10, 2015 at 09:00:06AM +, zeccav at gmail dot com wrote: > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67535 > > --- Comment #3 from Vittorio Zecca --- > (In reply to kargl from comment #1)

[Bug libfortran/67535] write.c sanitizer detects null pointer passed to memcpy

2015-09-10 Thread kargl at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67535 kargl at gcc dot gnu.org changed: What|Removed |Added CC||kargl at gcc dot gnu.org ---