public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/67652] New: liboffloadmic/runtime/offload_engine.cpp:176: strange expression in sizeof ?
@ 2015-09-20 16:38 dcb314 at hotmail dot com
2015-09-21 13:11 ` [Bug c/67652] " mpolacek at gcc dot gnu.org
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: dcb314 at hotmail dot com @ 2015-09-20 16:38 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67652
Bug ID: 67652
Summary: liboffloadmic/runtime/offload_engine.cpp:176: strange
expression in sizeof ?
Product: gcc
Version: 6.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c
Assignee: unassigned at gcc dot gnu.org
Reporter: dcb314 at hotmail dot com
Target Milestone: ---
[trunk/liboffloadmic/runtime/offload_engine.cpp:176]: (warning) Found
calculation inside sizeof().
Source code is
char * env_var = (char*) malloc(sizeof("COI_DMA_CHANNEL_COUNT=2" +
1));
Maybe better code
char * env_var = (char*) malloc(sizeof("COI_DMA_CHANNEL_COUNT=2") +
1);
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c/67652] liboffloadmic/runtime/offload_engine.cpp:176: strange expression in sizeof ?
2015-09-20 16:38 [Bug c/67652] New: liboffloadmic/runtime/offload_engine.cpp:176: strange expression in sizeof ? dcb314 at hotmail dot com
@ 2015-09-21 13:11 ` mpolacek at gcc dot gnu.org
2015-09-21 13:16 ` iverbin at gcc dot gnu.org
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: mpolacek at gcc dot gnu.org @ 2015-09-21 13:11 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67652
Marek Polacek <mpolacek at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2015-09-21
CC| |iverbin at gcc dot gnu.org,
| |mpolacek at gcc dot gnu.org
Ever confirmed|0 |1
--- Comment #1 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
That certainly looks wrong.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c/67652] liboffloadmic/runtime/offload_engine.cpp:176: strange expression in sizeof ?
2015-09-20 16:38 [Bug c/67652] New: liboffloadmic/runtime/offload_engine.cpp:176: strange expression in sizeof ? dcb314 at hotmail dot com
2015-09-21 13:11 ` [Bug c/67652] " mpolacek at gcc dot gnu.org
@ 2015-09-21 13:16 ` iverbin at gcc dot gnu.org
2015-09-28 16:10 ` [Bug other/67652] " iverbin at gcc dot gnu.org
2015-09-29 13:07 ` iverbin at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: iverbin at gcc dot gnu.org @ 2015-09-21 13:16 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67652
iverbin at gcc dot gnu.org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |ASSIGNED
Assignee|unassigned at gcc dot gnu.org |iverbin at gcc dot gnu.org
--- Comment #2 from iverbin at gcc dot gnu.org ---
Thanks, I will fix it.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug other/67652] liboffloadmic/runtime/offload_engine.cpp:176: strange expression in sizeof ?
2015-09-20 16:38 [Bug c/67652] New: liboffloadmic/runtime/offload_engine.cpp:176: strange expression in sizeof ? dcb314 at hotmail dot com
2015-09-21 13:11 ` [Bug c/67652] " mpolacek at gcc dot gnu.org
2015-09-21 13:16 ` iverbin at gcc dot gnu.org
@ 2015-09-28 16:10 ` iverbin at gcc dot gnu.org
2015-09-29 13:07 ` iverbin at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: iverbin at gcc dot gnu.org @ 2015-09-28 16:10 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67652
--- Comment #3 from iverbin at gcc dot gnu.org ---
Author: iverbin
Date: Mon Sep 28 16:10:16 2015
New Revision: 228210
URL: https://gcc.gnu.org/viewcvs?rev=228210&root=gcc&view=rev
Log:
PR other/67652
liboffloadmic/
* runtime/offload_engine.cpp (Engine::init_process): Fix sizeof.
Modified:
trunk/liboffloadmic/ChangeLog
trunk/liboffloadmic/runtime/offload_engine.cpp
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug other/67652] liboffloadmic/runtime/offload_engine.cpp:176: strange expression in sizeof ?
2015-09-20 16:38 [Bug c/67652] New: liboffloadmic/runtime/offload_engine.cpp:176: strange expression in sizeof ? dcb314 at hotmail dot com
` (2 preceding siblings ...)
2015-09-28 16:10 ` [Bug other/67652] " iverbin at gcc dot gnu.org
@ 2015-09-29 13:07 ` iverbin at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: iverbin at gcc dot gnu.org @ 2015-09-29 13:07 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67652
iverbin at gcc dot gnu.org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution|--- |FIXED
--- Comment #4 from iverbin at gcc dot gnu.org ---
Fixed in trunk.
GCC 5 doesn't have such an issue.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2015-09-29 13:07 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-09-20 16:38 [Bug c/67652] New: liboffloadmic/runtime/offload_engine.cpp:176: strange expression in sizeof ? dcb314 at hotmail dot com
2015-09-21 13:11 ` [Bug c/67652] " mpolacek at gcc dot gnu.org
2015-09-21 13:16 ` iverbin at gcc dot gnu.org
2015-09-28 16:10 ` [Bug other/67652] " iverbin at gcc dot gnu.org
2015-09-29 13:07 ` iverbin 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).