public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
* [RFC 0/5] xtensa: support dynamic configuration
@ 2017-05-22 21:12 Max Filippov
  2017-05-22 21:12 ` [RFC 3/5] xtensa: support dynconfig on windows Max Filippov
                   ` (5 more replies)
  0 siblings, 6 replies; 15+ messages in thread
From: Max Filippov @ 2017-05-22 21:12 UTC (permalink / raw)
  To: binutils, gdb-patches
  Cc: Sterling Augustine, David Weatherford, Maxim Grigoriev,
	Woody LaRue, Max Filippov

Hello,

this is an RFC series that makes xtensa binutils dynamically configurable,
i.e. on a platform with shared library support single toolchain binary
becomes capable of building code for arbitrary xtensa configuration.
At the same time it fully preserves the traditional way of configuring
using xtensa configuration overlay.

Currently xtensa toolchain needs to be patched and rebuilt for every
new xtensa processor configuration. This has a number of downsides:
- toolchain builders need to change the toolchain source code, and
  because xtensa configuration overlay is not a patch, this change is
  special, embedding it into the toolchain build process gets
  backpressure.
- toolchain built for one configuration is usually not usable for any
  other configuration. It's not possible for a distribution to provide
  reusable prebuilt xtensa toolchain.

This series allows building the toolchain (including target libraries)
without its source code modification. Built toolchain takes configuration
parameters from the shared object specified in the environment variable.
That shared object may be built by the following project:

  https://github.com/jcmvbkbc/xtensa-dynconfig

The same shared object is used for gcc, all binutils and for gdb.
Xtensa core specific information needed to build that shared object is
taken from the configuration overlay.

Both gcc and binutils-gdb get new shared header file
include/xtensa-dynconfig.h that provides definition of configuration
data structure, initialization macros, redefines XCHAL_* macros to
access this structure and declares function for loading configuration
dynamically.

Max Filippov (5):
  xtensa: don't expect XCHAL_* macros to be constant
  xtensa: make configuration dynamic
  xtensa: support dynconfig on windows
  xtensa: make xtensa_modules dynamic
  gdb: xtensa: make tdep and linux-nat dynamically configurable

 bfd/Makefile.am            |   2 +
 bfd/Makefile.in            |   3 +
 bfd/configure              |   4 +-
 bfd/configure.ac           |   4 +-
 bfd/elf32-xtensa.c         |  62 ++++----
 bfd/xtensa-config.c        | 117 ++++++++++++++
 bfd/xtensa-isa.c           |  13 +-
 gas/config/tc-xtensa.c     |  34 +++--
 gas/config/tc-xtensa.h     |  11 +-
 gas/config/xtensa-relax.c  |   2 +-
 gdb/xtensa-linux-nat.c     |  18 ++-
 gdb/xtensa-tdep.c          |  13 +-
 include/xtensa-dynconfig.h | 373 +++++++++++++++++++++++++++++++++++++++++++++
 ld/Makefile.am             |   1 +
 ld/Makefile.in             |   1 +
 ld/emultempl/xtensaelf.em  |   2 +-
 16 files changed, 608 insertions(+), 52 deletions(-)
 create mode 100644 bfd/xtensa-config.c
 create mode 100644 include/xtensa-dynconfig.h

-- 
2.1.4

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

end of thread, other threads:[~2017-06-12 15:49 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-05-22 21:12 [RFC 0/5] xtensa: support dynamic configuration Max Filippov
2017-05-22 21:12 ` [RFC 3/5] xtensa: support dynconfig on windows Max Filippov
2017-06-12 15:45   ` Nick Clifton
2017-05-22 21:12 ` [RFC 1/5] xtensa: don't expect XCHAL_* macros to be constant Max Filippov
2017-05-26 17:36   ` augustine.sterling
2017-05-22 21:12 ` [RFC 2/5] xtensa: make configuration dynamic Max Filippov
2017-05-26 18:10   ` augustine.sterling
2017-05-26 18:15     ` augustine.sterling
2017-06-06 12:53       ` Nick Clifton
2017-06-07 19:13         ` Max Filippov
2017-05-22 21:13 ` [RFC 5/5] gdb: xtensa: make tdep and linux-nat dynamically configurable Max Filippov
2017-05-22 21:13 ` [RFC 4/5] xtensa: make xtensa_modules dynamic Max Filippov
2017-06-12 15:49   ` Nick Clifton
2017-06-06 12:41 ` [RFC 0/5] xtensa: support dynamic configuration Nick Clifton
2017-06-07 19:23   ` Max Filippov

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