public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH, V3 0/2] Fix write_symbols for supporting multiple debug formats
@ 2021-05-12 22:13 Indu Bhagat
  2021-05-12 22:13 ` [PATCH,V3 1/2] opts: change write_symbols to support bitmasks Indu Bhagat
  2021-05-12 22:13 ` [PATCH,V3 2/2] dwarf: new dwarf_debuginfo_p predicate Indu Bhagat
  0 siblings, 2 replies; 7+ messages in thread
From: Indu Bhagat @ 2021-05-12 22:13 UTC (permalink / raw)
  To: gcc-patches

[Changes across versions]

  [What's new in V2]
  - (Addressed Richard's comments)
  - For patch 1/2 [opts: change write_symbols to support bitmasks], use
  debug_set_names more uniformly. Reworded the diagnostics in c-family/c-opts.c
  and c-family/c-pch.c as there can be multiple debug formats. Updated the
  testsuite files accordingly. 
  - Included more backend files for patch 2/2 [dwarf: new dwarf_debuginfo_p
  predicate]
  - Regression tested on x86_64.

  [What's new in V3]
  - (Addressed Richard's comments)
  - Include flags.h in relevant files. Tested build (make all-gcc) for triplets
  with c6x/mips/powerpc and darwin/cygwin.

[End of changes across versions]

Hello,

Over the last year, we have discussed and agreed that in order to support
multiple debug formats, we keep DWARF as defacto internal format and any new 
debug format to be supported feeds off DWARF dies. This requirement
specification has worked well for addition for CTF/BTF overall. 

There are some existing issues that need to discussed and fixed in this regard,
though. One of these is the definition and handling of write_symbols.

The current issue is that write_symbols is defined as 

   enum debug_info_type write_symbols = NO_DEBUG;

This means any new combination of debug formats needs to be explicitly
enumerated, like CTF_AND_DWARF2_DEBUG, VMS_AND_DWARF2_DEBUG etc. So the issue
is, to support say, -gctf -gbtf -g or possibly other combination of debug
formats to work together, each one needs to spelled out explicitly; which will
make the handling ugly.

This patch set updates write_symbols to use bitmasks.

Regression tested on x86_64, apart from simple (make all-gcc) builds for select
target triplets to cover c6x/mips/powerpc and cygwin/darwin.

Thanks,
Indu Bhagat (2):
  opts: change write_symbols to support bitmasks
  dwarf: new dwarf_debuginfo_p predicate

 gcc/c-family/c-lex.c               |   4 +-
 gcc/c-family/c-opts.c              |   7 ++-
 gcc/c-family/c-pch.c               |  12 ++--
 gcc/common.opt                     |   2 +-
 gcc/config/c6x/c6x.c               |   4 +-
 gcc/config/darwin.c                |   3 +-
 gcc/config/i386/cygming.h          |   2 +-
 gcc/config/i386/darwin.h           |   4 +-
 gcc/config/mips/mips.c             |   3 +-
 gcc/config/rs6000/rs6000.c         |   4 +-
 gcc/dbxout.c                       |   1 +
 gcc/dwarf2cfi.c                    |   9 ++-
 gcc/except.c                       |   1 +
 gcc/final.c                        |  15 ++---
 gcc/flag-types.h                   |  29 ++++++---
 gcc/flags.h                        |  21 ++++++-
 gcc/objc/objc-act.c                |   2 +-
 gcc/opts.c                         | 117 +++++++++++++++++++++++++++++++++----
 gcc/targhooks.c                    |   2 +-
 gcc/testsuite/gcc.dg/pch/valid-1.c |   2 +-
 gcc/testsuite/lib/dg-pch.exp       |   4 +-
 gcc/toplev.c                       |  15 ++---
 22 files changed, 197 insertions(+), 66 deletions(-)

-- 
1.8.3.1


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2021-05-21  0:01 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-12 22:13 [PATCH, V3 0/2] Fix write_symbols for supporting multiple debug formats Indu Bhagat
2021-05-12 22:13 ` [PATCH,V3 1/2] opts: change write_symbols to support bitmasks Indu Bhagat
2021-05-20  9:40   ` Richard Biener
2021-05-21  0:01     ` Indu Bhagat
2021-05-12 22:13 ` [PATCH,V3 2/2] dwarf: new dwarf_debuginfo_p predicate Indu Bhagat
2021-05-20  9:40   ` Richard Biener
2021-05-21  0:01     ` Indu Bhagat

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).