public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libstdc++/55649] New: libstdcxx gdb python pretty printer for tr1 not working
@ 2012-12-11 16:17 david.simmonds at igmarkets dot com
2012-12-11 16:19 ` [Bug libstdc++/55649] " david.simmonds at igmarkets dot com
` (4 more replies)
0 siblings, 5 replies; 6+ messages in thread
From: david.simmonds at igmarkets dot com @ 2012-12-11 16:17 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55649
Bug #: 55649
Summary: libstdcxx gdb python pretty printer for tr1 not
working
Classification: Unclassified
Product: gcc
Version: 4.7.2
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: libstdc++
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: david.simmonds@igmarkets.com
The Tr1UnorderedMapPrinter pretty printer, and other tr1 pretty printers look
for variables starting with _M_, the actual variable names start with m_
For example, should be m_element_count rather than _M_element_count
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug libstdc++/55649] libstdcxx gdb python pretty printer for tr1 not working
2012-12-11 16:17 [Bug libstdc++/55649] New: libstdcxx gdb python pretty printer for tr1 not working david.simmonds at igmarkets dot com
@ 2012-12-11 16:19 ` david.simmonds at igmarkets dot com
2012-12-11 16:34 ` redi at gcc dot gnu.org
` (3 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: david.simmonds at igmarkets dot com @ 2012-12-11 16:19 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55649
--- Comment #1 from Dave Simmonds <david.simmonds at igmarkets dot com> 2012-12-11 16:19:09 UTC ---
(gdb) print g_epicmap->m_Map
$1 = Traceback (most recent call last):
File "/usr/share/gdb/python/libstdcxx/v6/printers.py", line 536, in to_string
return '%s with %d elements' % (self.typename,
self.val['_M_element_count'])
RuntimeError: There is no member or method named _M_element_count.
Traceback (most recent call last):
File "/usr/share/gdb/python/libstdcxx/v6/printers.py", line 555, in children
data = self.flatten (itertools.imap (self.format_one, Tr1HashtableIterator
(self.val)))
File "/usr/share/gdb/python/libstdcxx/v6/printers.py", line 477, in __init__
self.n_buckets = hash['_M_element_count']
RuntimeError: There is no member or method named _M_element_count.
(gdb) print /r g_epicmap->m_Map
$2 = {
<std::tr1::hashtable<char const*, std::pair<char const* const,
boost::shared_ptr<CEpicRecord> >, std::allocator<std::pair<char const* const,
boost::shared_ptr<CEpicRecord> > >, Internal::extract1st<std::pair<char const*
const, boost::shared_ptr<CEpicRecord> > >, _ConstCharPtrCmp, _ConstCharHash,
Internal::mod_range_hashing, Internal::default_ranged_hash,
Internal::prime_rehash_policy, false, false, true>> = {
<Internal::rehash_base<Internal::prime_rehash_policy,
std::tr1::hashtable<char const*, std::pair<char const* const,
boost::shared_ptr<CEpicRecord> >, std::allocator<std::pair<char const* const,
boost::shared_ptr<CEpicRecord> > >, Internal::extract1st<std::pair<char const*
const, boost::shared_ptr<CEpicRecord> > >, _ConstCharPtrCmp, _ConstCharHash,
Internal::mod_range_hashing, Internal::default_ranged_hash,
Internal::prime_rehash_policy, false, false, true> >> = {<No data fields>},
<Internal::hash_code_base<char const*, std::pair<char const* const,
boost::shared_ptr<CEpicRecord> >, Internal::extract1st<std::pair<char const*
const, boost::shared_ptr<CEpicRecord> > >, _ConstCharPtrCmp, _ConstCharHash,
Internal::mod_range_hashing, Internal::default_ranged_hash, false>> = {
m_extract = {<No data fields>},
m_eq = {<No data fields>},
m_h1 = {<No data fields>},
m_h2 = {<No data fields>}
},
<Internal::map_base<char const*, std::pair<char const* const,
boost::shared_ptr<CEpicRecord> >, Internal::extract1st<std::pair<char const*
const, boost::shared_ptr<CEpicRecord> > >, true, std::tr1::hashtable<char
const*, std::pair<char const* const, boost::shared_ptr<CEpicRecord> >,
std::allocator<std::pair<char const* const, boost::shared_ptr<CEpicRecord> > >,
Internal::extract1st<std::pair<char const* const,
boost::shared_ptr<CEpicRecord> > >, _ConstCharPtrCmp, _ConstCharHash,
Internal::mod_range_hashing, Internal::default_ranged_hash,
Internal::prime_rehash_policy, false, false, true> >> = {<No data fields>},
members of std::tr1::hashtable<char const*, std::pair<char const* const,
boost::shared_ptr<CEpicRecord> >, std::allocator<std::pair<char const* const,
boost::shared_ptr<CEpicRecord> > >, Internal::extract1st<std::pair<char const*
const, boost::shared_ptr<CEpicRecord> > >, _ConstCharPtrCmp, _ConstCharHash,
Internal::mod_range_hashing, Internal::default_ranged_hash,
Internal::prime_rehash_policy, false, false, true>:
m_node_allocator = {
<__gnu_cxx::new_allocator<Internal::hash_node<std::pair<char const*
const, boost::shared_ptr<CEpicRecord> >, false> >> = {<No data fields>}, <No
data fields>},
m_buckets = 0x2aaaaaaac010,
m_bucket_count = 92203,
m_element_count = 69182,
m_rehash_policy = {
m_max_load_factor = 1,
m_growth_factor = 2,
m_next_resize = 92203
}
}, <No data fields>}
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug libstdc++/55649] libstdcxx gdb python pretty printer for tr1 not working
2012-12-11 16:17 [Bug libstdc++/55649] New: libstdcxx gdb python pretty printer for tr1 not working david.simmonds at igmarkets dot com
2012-12-11 16:19 ` [Bug libstdc++/55649] " david.simmonds at igmarkets dot com
@ 2012-12-11 16:34 ` redi at gcc dot gnu.org
2012-12-11 16:49 ` david.simmonds at igmarkets dot com
` (2 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: redi at gcc dot gnu.org @ 2012-12-11 16:34 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55649
--- Comment #2 from Jonathan Wakely <redi at gcc dot gnu.org> 2012-12-11 16:34:09 UTC ---
(In reply to comment #0)
> The Tr1UnorderedMapPrinter pretty printer, and other tr1 pretty printers look
> for variables starting with _M_, the actual variable names start with m_
No they don't:
http://gcc.gnu.org/viewcvs/trunk/libstdc%2B%2B-v3/include/tr1/unordered_map.h?view=markup
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug libstdc++/55649] libstdcxx gdb python pretty printer for tr1 not working
2012-12-11 16:17 [Bug libstdc++/55649] New: libstdcxx gdb python pretty printer for tr1 not working david.simmonds at igmarkets dot com
2012-12-11 16:19 ` [Bug libstdc++/55649] " david.simmonds at igmarkets dot com
2012-12-11 16:34 ` redi at gcc dot gnu.org
@ 2012-12-11 16:49 ` david.simmonds at igmarkets dot com
2012-12-11 16:56 ` david.simmonds at igmarkets dot com
2012-12-11 17:10 ` redi at gcc dot gnu.org
4 siblings, 0 replies; 6+ messages in thread
From: david.simmonds at igmarkets dot com @ 2012-12-11 16:49 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55649
--- Comment #3 from Dave Simmonds <david.simmonds at igmarkets dot com> 2012-12-11 16:49:17 UTC ---
(In reply to comment #2)
> (In reply to comment #0)
> > The Tr1UnorderedMapPrinter pretty printer, and other tr1 pretty printers look
> > for variables starting with _M_, the actual variable names start with m_
>
> No they don't:
> http://gcc.gnu.org/viewcvs/trunk/libstdc%2B%2B-v3/include/tr1/unordered_map.h?view=markup
Thanks for your reply, but the link isn't showing any variables with _M_ or
with m_, so doesn't help. Why do you say they don't? Certainly it's not working
for me as is, and if I create my own pretty printer with _M_ replaced by m_ it
works.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug libstdc++/55649] libstdcxx gdb python pretty printer for tr1 not working
2012-12-11 16:17 [Bug libstdc++/55649] New: libstdcxx gdb python pretty printer for tr1 not working david.simmonds at igmarkets dot com
` (2 preceding siblings ...)
2012-12-11 16:49 ` david.simmonds at igmarkets dot com
@ 2012-12-11 16:56 ` david.simmonds at igmarkets dot com
2012-12-11 17:10 ` redi at gcc dot gnu.org
4 siblings, 0 replies; 6+ messages in thread
From: david.simmonds at igmarkets dot com @ 2012-12-11 16:56 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55649
Dave Simmonds <david.simmonds at igmarkets dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |FIXED
--- Comment #4 from Dave Simmonds <david.simmonds at igmarkets dot com> 2012-12-11 16:56:19 UTC ---
(In reply to comment #3)
> (In reply to comment #2)
> > (In reply to comment #0)
> > > The Tr1UnorderedMapPrinter pretty printer, and other tr1 pretty printers look
> > > for variables starting with _M_, the actual variable names start with m_
> >
> > No they don't:
> > http://gcc.gnu.org/viewcvs/trunk/libstdc%2B%2B-v3/include/tr1/unordered_map.h?view=markup
>
> Thanks for your reply, but the link isn't showing any variables with _M_ or
> with m_, so doesn't help. Why do you say they don't? Certainly it's not working
> for me as is, and if I create my own pretty printer with _M_ replaced by m_ it
> works.
OK, I looked at the include file, I compiled against gcc 4.1.2, which has m_,
4.7.2 has _M_
Problem is that redhat el5 comes with gcc 4.1.2 and a pretty printer with _M_
which doesn't work togther
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug libstdc++/55649] libstdcxx gdb python pretty printer for tr1 not working
2012-12-11 16:17 [Bug libstdc++/55649] New: libstdcxx gdb python pretty printer for tr1 not working david.simmonds at igmarkets dot com
` (3 preceding siblings ...)
2012-12-11 16:56 ` david.simmonds at igmarkets dot com
@ 2012-12-11 17:10 ` redi at gcc dot gnu.org
4 siblings, 0 replies; 6+ messages in thread
From: redi at gcc dot gnu.org @ 2012-12-11 17:10 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55649
Jonathan Wakely <redi at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|FIXED |INVALID
--- Comment #5 from Jonathan Wakely <redi at gcc dot gnu.org> 2012-12-11 17:10:29 UTC ---
(In reply to comment #3)
> Thanks for your reply, but the link isn't showing any variables with _M_ or
> with m_, so doesn't help.
Sorry, I should have used
http://gcc.gnu.org/viewcvs/trunk/libstdc%2B%2B-v3/include/tr1/hashtable_policy.h?view=markup
or
http://gcc.gnu.org/viewcvs/trunk/libstdc%2B%2B-v3/include/tr1/hashtable.h?view=markup
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2012-12-11 17:10 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-12-11 16:17 [Bug libstdc++/55649] New: libstdcxx gdb python pretty printer for tr1 not working david.simmonds at igmarkets dot com
2012-12-11 16:19 ` [Bug libstdc++/55649] " david.simmonds at igmarkets dot com
2012-12-11 16:34 ` redi at gcc dot gnu.org
2012-12-11 16:49 ` david.simmonds at igmarkets dot com
2012-12-11 16:56 ` david.simmonds at igmarkets dot com
2012-12-11 17:10 ` redi 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).