public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/55418] New: Valgrind: Conditional jump or move depends on uninitialised value(s) in implicitly_declare_fn() method.c:1623
@ 2012-11-20 21:36 markus at trippelsdorf dot de
2012-11-21 14:09 ` [Bug c++/55418] " markus at trippelsdorf dot de
` (6 more replies)
0 siblings, 7 replies; 8+ messages in thread
From: markus at trippelsdorf dot de @ 2012-11-20 21:36 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55418
Bug #: 55418
Summary: Valgrind: Conditional jump or move depends on
uninitialised value(s) in implicitly_declare_fn()
method.c:1623
Classification: Unclassified
Product: gcc
Version: 4.8.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: markus@trippelsdorf.de
Just saw this during a -enable-checking=yes,valgrind build:
% /var/tmp/gcc_valgrind/usr/local/bin/g++ -std=gnu++11 -c
/home/markus/gcc/libstdc++-v3/src/c++11/functexcept.cc
==1267== Conditional jump or move depends on uninitialised value(s)
==1267== at 0x637C0F: implicitly_declare_fn(special_function_kind,
tree_node*, bool, tree_node*, tree_node*) (method.c:1623)
==1267== by 0x6392DF: lazily_declare_fn(special_function_kind, tree_node*)
(method.c:1894)
==1267== by 0x63FB74: lookup_fnfields_1(tree_node*, tree_node*)
(search.c:1441)
==1267== by 0x63FD3B: lookup_fnfields_slot(tree_node*, tree_node*)
(search.c:1471)
==1267== by 0x64367B: lookup_field_r(tree_node*, void*) (search.c:1031)
==1267== by 0x6400CE: dfs_walk_all(tree_node*, tree_node* (*)(tree_node*,
void*), tree_node* (*)(tree_node*, void*), void*) (search.c:1572)
==1267== by 0x6402E7: lookup_member(tree_node*, tree_node*, int, bool, int)
(search.c:1204)
==1267== by 0x640640: lookup_fnfields(tree_node*, tree_node*, int)
(search.c:1295)
==1267== by 0x4DF3B0: build_special_member_call(tree_node*, tree_node*,
vec<tree_node*, va_gc, vl_embed>**, tree_node*, int, int) (call.c:7282)
==1267== by 0x4E0693: convert_like_real(conversion*, tree_node*, tree_node*,
int, int, bool, bool, int) (call.c:5718)
==1267== by 0x4E1D91: build_over_call(z_candidate*, int, int) (call.c:6867)
==1267== by 0x4DE229: build_new_method_call(tree_node*, tree_node*,
vec<tree_node*, va_gc, vl_embed>**, tree_node*, int, tree_node**, int)
(call.c:7668)
==1267==
Looks like some booleans in implicitly_declare_fn should be initialised.
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug c++/55418] Valgrind: Conditional jump or move depends on uninitialised value(s) in implicitly_declare_fn() method.c:1623
2012-11-20 21:36 [Bug c++/55418] New: Valgrind: Conditional jump or move depends on uninitialised value(s) in implicitly_declare_fn() method.c:1623 markus at trippelsdorf dot de
@ 2012-11-21 14:09 ` markus at trippelsdorf dot de
2012-11-21 15:51 ` hp at gcc dot gnu.org
` (5 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: markus at trippelsdorf dot de @ 2012-11-21 14:09 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55418
--- Comment #1 from Markus Trippelsdorf <markus at trippelsdorf dot de> 2012-11-21 14:08:12 UTC ---
The following trivial patch fixes the issue:
diff --git a/gcc/cp/method.c b/gcc/cp/method.c
index 6dcb63a..3cb4ace 100644
--- a/gcc/cp/method.c
+++ b/gcc/cp/method.c
@@ -1518,7 +1518,7 @@ implicitly_declare_fn (special_function_kind kind, tree
type,
tree name;
HOST_WIDE_INT saved_processing_template_decl;
bool deleted_p;
- bool trivial_p;
+ bool trivial_p = false;
bool constexpr_p;
/* Because we create declarations for implicitly declared functions
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug c++/55418] Valgrind: Conditional jump or move depends on uninitialised value(s) in implicitly_declare_fn() method.c:1623
2012-11-20 21:36 [Bug c++/55418] New: Valgrind: Conditional jump or move depends on uninitialised value(s) in implicitly_declare_fn() method.c:1623 markus at trippelsdorf dot de
2012-11-21 14:09 ` [Bug c++/55418] " markus at trippelsdorf dot de
@ 2012-11-21 15:51 ` hp at gcc dot gnu.org
2012-11-22 10:46 ` paolo.carlini at oracle dot com
` (4 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: hp at gcc dot gnu.org @ 2012-11-21 15:51 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55418
Hans-Peter Nilsson <hp at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |hp at gcc dot gnu.org
--- Comment #2 from Hans-Peter Nilsson <hp at gcc dot gnu.org> 2012-11-21 15:51:08 UTC ---
I haven't (In reply to comment #1)
> The following trivial patch fixes the issue:
I haven't looked at the context so I feel free to say it looks a bit obvious...
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug c++/55418] Valgrind: Conditional jump or move depends on uninitialised value(s) in implicitly_declare_fn() method.c:1623
2012-11-20 21:36 [Bug c++/55418] New: Valgrind: Conditional jump or move depends on uninitialised value(s) in implicitly_declare_fn() method.c:1623 markus at trippelsdorf dot de
2012-11-21 14:09 ` [Bug c++/55418] " markus at trippelsdorf dot de
2012-11-21 15:51 ` hp at gcc dot gnu.org
@ 2012-11-22 10:46 ` paolo.carlini at oracle dot com
2012-11-23 15:35 ` paolo at gcc dot gnu.org
` (3 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: paolo.carlini at oracle dot com @ 2012-11-22 10:46 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55418
--- Comment #3 from Paolo Carlini <paolo.carlini at oracle dot com> 2012-11-22 10:46:31 UTC ---
The issue seems indeed trivial, but note that we are already assigning false to
trivial_p in the conditional, thus I guess we should remove the latter. Maybe
also move the declaration itself right before the conditional, in my opinion it
adds clarity. Please send a patch to the mailing list.
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug c++/55418] Valgrind: Conditional jump or move depends on uninitialised value(s) in implicitly_declare_fn() method.c:1623
2012-11-20 21:36 [Bug c++/55418] New: Valgrind: Conditional jump or move depends on uninitialised value(s) in implicitly_declare_fn() method.c:1623 markus at trippelsdorf dot de
` (2 preceding siblings ...)
2012-11-22 10:46 ` paolo.carlini at oracle dot com
@ 2012-11-23 15:35 ` paolo at gcc dot gnu.org
2012-11-23 15:36 ` paolo.carlini at oracle dot com
` (2 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: paolo at gcc dot gnu.org @ 2012-11-23 15:35 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55418
--- Comment #4 from paolo at gcc dot gnu.org <paolo at gcc dot gnu.org> 2012-11-23 15:34:51 UTC ---
Author: paolo
Date: Fri Nov 23 15:34:45 2012
New Revision: 193758
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=193758
Log:
2012-11-23 Markus Trippelsdorf <markus@trippelsdorf.de>
PR c++/55418
* method.c (implicitly_declare_fn): Properly initialize trivial_p.
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/method.c
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug c++/55418] Valgrind: Conditional jump or move depends on uninitialised value(s) in implicitly_declare_fn() method.c:1623
2012-11-20 21:36 [Bug c++/55418] New: Valgrind: Conditional jump or move depends on uninitialised value(s) in implicitly_declare_fn() method.c:1623 markus at trippelsdorf dot de
` (3 preceding siblings ...)
2012-11-23 15:35 ` paolo at gcc dot gnu.org
@ 2012-11-23 15:36 ` paolo.carlini at oracle dot com
2012-12-05 11:42 ` paolo.carlini at oracle dot com
2013-07-06 23:15 ` paolo.carlini at oracle dot com
6 siblings, 0 replies; 8+ messages in thread
From: paolo.carlini at oracle dot com @ 2012-11-23 15:36 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55418
Paolo Carlini <paolo.carlini at oracle dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |FIXED
Target Milestone|--- |4.8.0
--- Comment #5 from Paolo Carlini <paolo.carlini at oracle dot com> 2012-11-23 15:35:55 UTC ---
Fixed.
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug c++/55418] Valgrind: Conditional jump or move depends on uninitialised value(s) in implicitly_declare_fn() method.c:1623
2012-11-20 21:36 [Bug c++/55418] New: Valgrind: Conditional jump or move depends on uninitialised value(s) in implicitly_declare_fn() method.c:1623 markus at trippelsdorf dot de
` (4 preceding siblings ...)
2012-11-23 15:36 ` paolo.carlini at oracle dot com
@ 2012-12-05 11:42 ` paolo.carlini at oracle dot com
2013-07-06 23:15 ` paolo.carlini at oracle dot com
6 siblings, 0 replies; 8+ messages in thread
From: paolo.carlini at oracle dot com @ 2012-12-05 11:42 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55418
Paolo Carlini <paolo.carlini at oracle dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |dcb314 at hotmail dot com
--- Comment #6 from Paolo Carlini <paolo.carlini at oracle dot com> 2012-12-05 11:42:05 UTC ---
*** Bug 52311 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug c++/55418] Valgrind: Conditional jump or move depends on uninitialised value(s) in implicitly_declare_fn() method.c:1623
2012-11-20 21:36 [Bug c++/55418] New: Valgrind: Conditional jump or move depends on uninitialised value(s) in implicitly_declare_fn() method.c:1623 markus at trippelsdorf dot de
` (5 preceding siblings ...)
2012-12-05 11:42 ` paolo.carlini at oracle dot com
@ 2013-07-06 23:15 ` paolo.carlini at oracle dot com
6 siblings, 0 replies; 8+ messages in thread
From: paolo.carlini at oracle dot com @ 2013-07-06 23:15 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55418
Paolo Carlini <paolo.carlini at oracle dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |hjl.tools at gmail dot com
--- Comment #7 from Paolo Carlini <paolo.carlini at oracle dot com> ---
*** Bug 53224 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2013-07-06 23:15 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-11-20 21:36 [Bug c++/55418] New: Valgrind: Conditional jump or move depends on uninitialised value(s) in implicitly_declare_fn() method.c:1623 markus at trippelsdorf dot de
2012-11-21 14:09 ` [Bug c++/55418] " markus at trippelsdorf dot de
2012-11-21 15:51 ` hp at gcc dot gnu.org
2012-11-22 10:46 ` paolo.carlini at oracle dot com
2012-11-23 15:35 ` paolo at gcc dot gnu.org
2012-11-23 15:36 ` paolo.carlini at oracle dot com
2012-12-05 11:42 ` paolo.carlini at oracle dot com
2013-07-06 23:15 ` paolo.carlini at oracle dot com
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).