From: Ken Werner <ken@linux.vnet.ibm.com>
To: Tom Tromey <tromey@redhat.com>
Cc: gdb-patches@sourceware.org
Subject: Re: RFA: shrink main_type
Date: Sat, 25 Sep 2010 14:38:00 -0000 [thread overview]
Message-ID: <201009241827.00462.ken@linux.vnet.ibm.com> (raw)
In-Reply-To: <201009151441.43723.ken@linux.vnet.ibm.com>
On Wednesday, September 15, 2010 2:41:43 pm Ken Werner wrote:
> On Tuesday, August 19, 2008 07:55:37 pm Tom Tromey wrote:
> > + /* Flags about this type. These fields appear at this location
> > + because they packs nicely here. See the TYPE_* macros for
> > + documentation about these fields. */
> > +
> > + unsigned int flag_unsigned : 1;
> > + unsigned int flag_nosign : 1;
> > + unsigned int flag_stub : 1;
> > + unsigned int flag_target_stub : 1;
> > + unsigned int flag_static : 1;
> > + unsigned int flag_prototyped : 1;
> > + unsigned int flag_incomplete : 1;
> > + unsigned int flag_varargs : 1;
> > + unsigned int flag_vector : 1;
> > + unsigned int flag_stub_supported : 1;
> > + unsigned int flag_nottext : 1;
> > + unsigned int flag_fixed_instance : 1;
>
> Hi Tom,
>
> This is quite an old change but while debugging gdb I noticed that vector
> types do have a strange bit set into their instance_flags and this seems to
> go back to this patch.
> The snippet above introduces the flag_nottext as a bitfield member of the
> type struct while gdbtypes.c:make_vector_type still sets that bit into the
> instance_flags.
>
> The nottext flag is set for the element types of vectors
> (gdbtypes.c:make_vector_type) and for the builtin_int8/builtin_int8 types.
> The flag is read from the c-valprint.c:c_textual_element_type function
> that determines whether arrays of chars should be printed as strings or
> not. So, I guess that prior to this patch char vectors were printed just
> like integer vectors - plain data. One approach to restore that
> functionality would be to move the nottext flag into to the instance_flags
> of the type. Attached is an untested patch of what I have in mind.
> Comments are welcome.
>
> This also renders my previous attempt to fix the printing of character
> vectors (http://sourceware.org/ml/gdb-patches/2010-06/msg00573.html)
> obsolete.
>
> Regards
> Ken Werner
Ping. : ) Since I screwed up the recipient list plus the fact that this was a
reply to a 2008 post it may be well hidden by the mail reader.
Are there any comments on that?
Thanks
Ken
next prev parent reply other threads:[~2010-09-24 16:27 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-08-17 18:50 Tom Tromey
2008-08-18 13:01 ` Joel Brobecker
2008-08-18 13:20 ` Daniel Jacobowitz
2008-08-18 13:30 ` Joel Brobecker
2008-08-18 15:19 ` Tom Tromey
2008-08-18 19:39 ` Tom Tromey
2008-08-18 22:17 ` Andreas Schwab
2008-08-18 22:32 ` Daniel Jacobowitz
2008-08-19 5:13 ` Joel Brobecker
2008-08-19 17:56 ` Tom Tromey
2008-08-24 10:12 ` Joel Brobecker
2008-08-24 16:41 ` Tom Tromey
2008-08-24 18:03 ` Tom Tromey
2008-08-24 20:35 ` Tom Tromey
2008-08-25 15:50 ` Joel Brobecker
2008-08-25 19:12 ` Tom Tromey
2010-09-15 19:23 ` Ken Werner
2010-09-25 14:38 ` Ken Werner [this message]
2010-09-30 18:56 ` Joel Brobecker
2010-10-01 13:23 ` Ken Werner
2010-10-01 15:34 ` [patch] move the nottext flag to the instance_flags Ken Werner
2010-10-01 16:15 ` Joel Brobecker
2010-10-05 21:50 ` Tom Tromey
2010-10-06 8:45 ` Ken Werner
2008-08-18 15:04 ` RFA: shrink main_type Tom Tromey
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=201009241827.00462.ken@linux.vnet.ibm.com \
--to=ken@linux.vnet.ibm.com \
--cc=gdb-patches@sourceware.org \
--cc=tromey@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox