diff mbox

[6/6] : Remove xml files from gdbserver

Message ID 7AE33E6A-ED51-4285-9049-6D2B6A42F866@arm.com
State New
Headers show

Commit Message

Alan Hayward Jan. 16, 2018, 9:54 a.m. UTC
This patch removes the xml files from being built into gdbserver,

Alan.

2018-01-16  Alan Hayward  <alan.hayward@arm.com>

	* gdb/gdbserver/Makefile.in: Don't include xml.
	* gdb/gdbserver/configure: Remove all the xml files.
	* gdb/gdbserver/configure.ac: Don't include xml.
	* gdb/gdbserver/configure.srv: Likewise.

Comments

Yao Qi Jan. 19, 2018, 10:11 p.m. UTC | #1
On Tue, Jan 16, 2018 at 9:54 AM, Alan Hayward <Alan.Hayward@arm.com> wrote:
> This patch removes the xml files from being built into gdbserver,
>

I really want to do that, but we can't do it now, because, we expect GDBserver
can generate xml contents from new style target features, rather than copy these
xml features into gdbserver.  GDBserver using old style target description still
has to copy xml contents to itself.
Alan Hayward Jan. 22, 2018, 1:23 p.m. UTC | #2
> On 19 Jan 2018, at 22:11, Yao Qi <qiyaoltc@gmail.com> wrote:
> 
> On Tue, Jan 16, 2018 at 9:54 AM, Alan Hayward <Alan.Hayward@arm.com> wrote:
>> This patch removes the xml files from being built into gdbserver,
>> 
> 
> I really want to do that, but we can't do it now, because, we expect GDBserver
> can generate xml contents from new style target features, rather than copy these
> xml features into gdbserver.  GDBserver using old style target description still
> has to copy xml contents to itself.
> 

Ok, happy to remove this patch from the series.


Alan.
Yao Qi Jan. 22, 2018, 2:52 p.m. UTC | #3
Alan Hayward <Alan.Hayward@arm.com> writes:

> Ok, happy to remove this patch from the series.

Part of this patch is still needed, as we can remove srv_xmlfiles for
the arches which can generate xml contents from target descriptions,
like x86, aarch64 and tic6x.
diff mbox

Patch

diff --git a/gdb/gdbserver/Makefile.in b/gdb/gdbserver/Makefile.in
index 8ae124875dd08f31e8424b18281cb1454ed40edb..3158f8df86ab63b5642b0f38befc4b6bb71cf7dd 100644
--- a/gdb/gdbserver/Makefile.in
+++ b/gdb/gdbserver/Makefile.in
@@ -276,19 +276,13 @@  OBS = \
 	waitstatus.o \
 	xml-utils.o \
 	$(DEPFILES) \
-	$(LIBOBJS) \
-	$(XML_BUILTIN)
+	$(LIBOBJS)

 GDBREPLAY_OBS = gdbreplay.o version.o
 GDBSERVER_LIBS = @GDBSERVER_LIBS@
 XM_CLIBS = @LIBS@
 CDEPS = $(srcdir)/proc-service.list

-# XML files to compile in to gdbserver, if any.
-XML_DIR = $(srcdir)/../features
-XML_FILES = @srv_xmlfiles@
-XML_BUILTIN = @srv_xmlbuiltin@
-
 IPA_DEPFILES = @IPA_DEPFILES@
 extra_libraries = @extra_libraries@

@@ -498,15 +492,6 @@  version-generated.c: Makefile $(srcdir)/../version.in $(srcdir)/../../bfd/versio
 	$(SHELL) $(srcdir)/../common/create-version.sh $(srcdir)/.. \
 	    $(host_alias) $(target_alias) $@

-xml-builtin-generated.c: stamp-xml; @true
-stamp-xml: $(XML_DIR)/feature_to_c.sh Makefile $(XML_FILES)
-	rm -f xml-builtin.tmp
-	$(SHELL) $(XML_DIR)/feature_to_c.sh xml-builtin.tmp $(XML_FILES)
-	$(SHELL) $(srcdir)/../../move-if-change xml-builtin.tmp xml-builtin-generated.c
-	echo stamp > stamp-xml
-
-.PRECIOUS: xml-builtin.c
-
 # GNU Make has an annoying habit of putting *all* the Makefile variables
 # into the environment, unless you include this target as a circumvention.
 # Rumor is that this will be fixed (and this target can be removed)
diff --git a/gdb/gdbserver/configure b/gdb/gdbserver/configure
index ca51321c8469282a54dbc1adc8cf52ced64dc290..a49db164fed523238b2f944caf9187593b03e405 100755
--- a/gdb/gdbserver/configure
+++ b/gdb/gdbserver/configure
@@ -593,8 +593,6 @@  LIBOBJS
 GNULIB_STDINT_H
 extra_libraries
 IPA_DEPFILES
-srv_xmlfiles
-srv_xmlbuiltin
 GDBSERVER_LIBS
 GDBSERVER_DEPFILES
 RDYNAMIC
@@ -8275,19 +8273,6 @@  $as_echo "#define USE_LIBTHREAD_DB_DIRECTLY 1" >>confdefs.h

 fi

-if test "$srv_xmlfiles" != ""; then
-  srv_xmlbuiltin="xml-builtin.o"
-
-$as_echo "#define USE_XML 1" >>confdefs.h
-
-
-  tmp_xmlfiles=$srv_xmlfiles
-  srv_xmlfiles=""
-  for f in $tmp_xmlfiles; do
-    srv_xmlfiles="$srv_xmlfiles \$(XML_DIR)/$f"
-  done
-fi
-
 GDBSERVER_DEPFILES="$srv_regobj $srv_tgtobj $srv_hostio_err_objs $srv_thread_depfiles $srv_host_obs $srv_selftest_objs"
 GDBSERVER_LIBS="$srv_libs"

diff --git a/gdb/gdbserver/configure.ac b/gdb/gdbserver/configure.ac
index 7ea3654f63a5fbbb4419c926df1e15ea1222ae14..39c4dff4f0af017cf78dc31b525232e9088765d8 100644
--- a/gdb/gdbserver/configure.ac
+++ b/gdb/gdbserver/configure.ac
@@ -400,17 +400,6 @@  if test "$srv_libs" != "" -a "$srv_libs" != "-ldl"; then
   AC_DEFINE(USE_LIBTHREAD_DB_DIRECTLY, 1, [Define if we should use libthread_db directly.])
 fi

-if test "$srv_xmlfiles" != ""; then
-  srv_xmlbuiltin="xml-builtin.o"
-  AC_DEFINE(USE_XML, 1, [Define if an XML target description is available.])
-
-  tmp_xmlfiles=$srv_xmlfiles
-  srv_xmlfiles=""
-  for f in $tmp_xmlfiles; do
-    srv_xmlfiles="$srv_xmlfiles \$(XML_DIR)/$f"
-  done
-fi
-
 GDBSERVER_DEPFILES="$srv_regobj $srv_tgtobj $srv_hostio_err_objs $srv_thread_depfiles $srv_host_obs $srv_selftest_objs"
 GDBSERVER_LIBS="$srv_libs"

@@ -489,8 +478,6 @@  fi

 AC_SUBST(GDBSERVER_DEPFILES)
 AC_SUBST(GDBSERVER_LIBS)
-AC_SUBST(srv_xmlbuiltin)
-AC_SUBST(srv_xmlfiles)
 AC_SUBST(IPA_DEPFILES)
 AC_SUBST(extra_libraries)

diff --git a/gdb/gdbserver/configure.srv b/gdb/gdbserver/configure.srv
index 087fd31426bc738fdae91dde4bd4d575d8b26224..00f27e4ee4c9b68972d17b64143a1ebe5a0bdcc9 100644
--- a/gdb/gdbserver/configure.srv
+++ b/gdb/gdbserver/configure.srv
@@ -8,8 +8,6 @@ 
 #			for this target.
 #   srv_hostio_err	The object implementing the hostio_last_error
 #			target method.
-#   srv_xmlfiles	All XML files which should be available for
-#			gdbserver in this configuration.
 #   ipa_obj		Any other target-specific modules appropriate
 #			for this target's in-process agent.
 #
@@ -34,14 +32,6 @@  fi

 ipa_ppc_linux_regobj="powerpc-32l-ipa.o powerpc-altivec32l-ipa.o powerpc-cell32l-ipa.o powerpc-vsx32l-ipa.o powerpc-isa205-32l-ipa.o powerpc-isa205-altivec32l-ipa.o powerpc-isa205-vsx32l-ipa.o powerpc-e500l-ipa.o powerpc-64l-ipa.o powerpc-altivec64l-ipa.o powerpc-cell64l-ipa.o powerpc-vsx64l-ipa.o powerpc-isa205-64l-ipa.o powerpc-isa205-altivec64l-ipa.o powerpc-isa205-vsx64l-ipa.o"

-srv_i386_32bit_xmlfiles="i386/32bit-core.xml i386/32bit-sse.xml i386/32bit-avx.xml i386/32bit-avx512.xml i386/32bit-mpx.xml i386/32bit-pkeys.xml"
-srv_i386_64bit_xmlfiles="i386/64bit-core.xml i386/64bit-segments.xml i386/64bit-sse.xml i386/64bit-avx.xml i386/64bit-avx512.xml i386/x32-core.xml i386/64bit-mpx.xml i386/64bit-pkeys.xml"
-srv_i386_xmlfiles="i386/i386.xml $srv_i386_32bit_xmlfiles"
-srv_amd64_xmlfiles="i386/amd64.xml $srv_i386_64bit_xmlfiles"
-srv_i386_linux_xmlfiles="i386/32bit-linux.xml $srv_i386_32bit_xmlfiles"
-srv_amd64_linux_xmlfiles="i386/64bit-linux.xml $srv_i386_64bit_xmlfiles"
-
-
 # Linux object files.  This is so we don't have to repeat
 # these files over and over again.
 srv_linux_obj="linux-low.o linux-osdata.o linux-procfs.o linux-ptrace.o linux-waitpid.o linux-personality.o linux-namespaces.o fork-child.o fork-inferior.o"
@@ -63,11 +53,6 @@  case "${target}" in
 			srv_tgtobj="$srv_tgtobj arch/aarch64.o"
 			srv_tgtobj="$srv_tgtobj linux-aarch64-tdesc.o"
 			srv_tgtobj="${srv_tgtobj} $srv_linux_obj"
-			srv_xmlfiles="aarch64.xml"
-			srv_xmlfiles="${srv_xmlfiles} aarch64-core.xml"
-			srv_xmlfiles="${srv_xmlfiles} aarch64-fpu.xml"
-			srv_xmlfiles="${srv_xmlfiles} arm/arm-core.xml arm/arm-vfpv3.xml"
-			srv_xmlfiles="${srv_xmlfiles} arm/arm-with-neon.xml"
 			srv_linux_regsets=yes
 			srv_linux_thread_db=yes
 			ipa_obj="linux-aarch64-ipa.o"
@@ -83,14 +68,6 @@  case "${target}" in
 			srv_tgtobj="${srv_tgtobj} arch/arm.o"
 			srv_tgtobj="${srv_tgtobj} arch/arm-linux.o"
 			srv_tgtobj="${srv_tgtobj} arch/arm-get-next-pcs.o"
-			srv_xmlfiles="arm/arm-with-iwmmxt.xml"
-			srv_xmlfiles="${srv_xmlfiles} arm/arm-with-vfpv2.xml"
-			srv_xmlfiles="${srv_xmlfiles} arm/arm-with-vfpv3.xml"
-			srv_xmlfiles="${srv_xmlfiles} arm/arm-with-neon.xml"
-			srv_xmlfiles="${srv_xmlfiles} arm/arm-core.xml"
-			srv_xmlfiles="${srv_xmlfiles} arm/xscale-iwmmxt.xml"
-			srv_xmlfiles="${srv_xmlfiles} arm/arm-vfpv2.xml"
-			srv_xmlfiles="${srv_xmlfiles} arm/arm-vfpv3.xml"
 			srv_linux_usrregs=yes
 			srv_linux_regsets=yes
 			srv_linux_thread_db=yes
@@ -121,13 +98,10 @@  case "${target}" in
   i[34567]86-*-cygwin*)	srv_regobj=""
 			srv_tgtobj="x86-low.o x86-dregs.o win32-low.o win32-i386-low.o"
 			srv_tgtobj="${srv_tgtobj} arch/i386.o"
-			srv_xmlfiles="$srv_i386_xmlfiles"
 			;;
   i[34567]86-*-linux*)	srv_regobj="$srv_i386_linux_regobj"
-			srv_xmlfiles="$srv_i386_linux_xmlfiles"
 			if test "$gdb_cv_i386_is_x86_64" = yes ; then
 			    srv_regobj="$srv_regobj $srv_amd64_linux_regobj"
-			    srv_xmlfiles="${srv_xmlfiles} $srv_amd64_linux_xmlfiles"
 			    srv_tgtobj="amd64-linux-siginfo.o"
 			fi
 			srv_tgtobj="${srv_tgtobj} arch/i386.o"
@@ -145,9 +119,6 @@  case "${target}" in
   i[34567]86-*-lynxos*)	srv_regobj=""
 			srv_tgtobj="lynx-low.o lynx-i386-low.o fork-child.o fork-inferior.o"
 			srv_tgtobj="${srv_tgtobj} arch/i386.o"
-			srv_xmlfiles="i386/i386.xml"
-			srv_xmlfiles="${srv_xmlfiles} i386/32bit-core.xml"
-			srv_xmlfiles="${srv_xmlfiles} i386/32bit-sse.xml"
 			srv_lynxos=yes
 			;;
   i[34567]86-*-mingw32ce*)
@@ -155,7 +126,6 @@  case "${target}" in
 			srv_tgtobj="x86-low.o x86-dregs.o win32-low.o win32-i386-low.o"
 			srv_tgtobj="${srv_tgtobj} arch/i386.o"
 			srv_tgtobj="${srv_tgtobj} wincecompat.o"
-			srv_xmlfiles="$srv_i386_xmlfiles"
 			# hostio_last_error implementation is in win32-low.c
 			srv_hostio_err_objs=""
 			srv_mingw=yes
@@ -164,12 +134,10 @@  case "${target}" in
   i[34567]86-*-mingw*)	srv_regobj=""
 			srv_tgtobj="x86-low.o x86-dregs.o win32-low.o win32-i386-low.o"
 			srv_tgtobj="${srv_tgtobj} arch/i386.o"
-			srv_xmlfiles="$srv_i386_xmlfiles"
 			srv_mingw=yes
 			;;
   i[34567]86-*-nto*)	srv_regobj=""
 			srv_tgtobj="nto-low.o nto-x86-low.o arch/i386.o"
-			srv_xmlfiles="$srv_i386_xmlfiles"
 			srv_qnx="yes"
 			;;
   ia64-*-linux*)	srv_regobj=reg-ia64.o
@@ -207,26 +175,12 @@  case "${target}" in
 			srv_regobj="${srv_regobj} mips64-dsp-linux.o"
 			srv_tgtobj="$srv_linux_obj linux-mips-low.o"
 			srv_tgtobj="${srv_tgtobj} mips-linux-watch.o"
-			srv_xmlfiles="mips-linux.xml"
-			srv_xmlfiles="${srv_xmlfiles} mips-dsp-linux.xml"
-			srv_xmlfiles="${srv_xmlfiles} mips-cpu.xml"
-			srv_xmlfiles="${srv_xmlfiles} mips-cp0.xml"
-			srv_xmlfiles="${srv_xmlfiles} mips-fpu.xml"
-			srv_xmlfiles="${srv_xmlfiles} mips-dsp.xml"
-			srv_xmlfiles="${srv_xmlfiles} mips64-linux.xml"
-			srv_xmlfiles="${srv_xmlfiles} mips64-dsp-linux.xml"
-			srv_xmlfiles="${srv_xmlfiles} mips64-cpu.xml"
-			srv_xmlfiles="${srv_xmlfiles} mips64-cp0.xml"
-			srv_xmlfiles="${srv_xmlfiles} mips64-fpu.xml"
-			srv_xmlfiles="${srv_xmlfiles} mips64-dsp.xml"
 			srv_linux_regsets=yes
 			srv_linux_usrregs=yes
 			srv_linux_thread_db=yes
 			;;
   nios2*-*-linux*)	srv_regobj="nios2-linux.o"
 			srv_tgtobj="$srv_linux_obj linux-nios2-low.o"
-			srv_xmlfiles="nios2-linux.xml"
-			srv_xmlfiles="${srv_xmlfiles} nios2-cpu.xml"
 			srv_linux_regsets=yes
 			srv_linux_usrregs=yes
 			srv_linux_thread_db=yes
@@ -247,30 +201,6 @@  case "${target}" in
 			srv_regobj="${srv_regobj} powerpc-isa205-altivec64l.o"
 			srv_regobj="${srv_regobj} powerpc-isa205-vsx64l.o"
 			srv_tgtobj="$srv_linux_obj linux-ppc-low.o ppc-linux.o"
-			srv_xmlfiles="rs6000/powerpc-32l.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/powerpc-altivec32l.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/powerpc-cell32l.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/powerpc-vsx32l.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/powerpc-isa205-32l.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/powerpc-isa205-altivec32l.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/powerpc-isa205-vsx32l.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/power-altivec.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/power-vsx.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/power-core.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/power-linux.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/power-fpu.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/power-fpu-isa205.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/powerpc-e500l.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/power-spe.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/powerpc-64l.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/powerpc-altivec64l.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/powerpc-cell64l.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/powerpc-vsx64l.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/powerpc-isa205-64l.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/powerpc-isa205-altivec64l.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/powerpc-isa205-vsx64l.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/power64-core.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/power64-linux.xml"
 			srv_linux_usrregs=yes
 			srv_linux_regsets=yes
 			srv_linux_thread_db=yes
@@ -278,9 +208,6 @@  case "${target}" in
 			;;
   powerpc-*-lynxos*)	srv_regobj="powerpc-32.o"
 			srv_tgtobj="lynx-low.o lynx-ppc-low.o"
-			srv_xmlfiles="rs6000/powerpc-32.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/power-core.xml"
-			srv_xmlfiles="${srv_xmlfiles} rs6000/power-fpu.xml"
 			srv_lynxos=yes
 			;;
   s390*-*-linux*)	srv_regobj="s390-linux32.o"
@@ -301,32 +228,6 @@  case "${target}" in
 			srv_regobj="${srv_regobj} s390x-tevx-linux64.o"
 			srv_regobj="${srv_regobj} s390x-gs-linux64.o"
 			srv_tgtobj="$srv_linux_obj linux-s390-low.o"
-			srv_xmlfiles="s390-linux32.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390-linux32v1.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390-linux32v2.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390-linux64.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390-linux64v1.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390-linux64v2.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390-te-linux64.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390-vx-linux64.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390-tevx-linux64.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390-gs-linux64.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390x-linux64.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390x-linux64v1.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390x-linux64v2.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390x-te-linux64.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390x-vx-linux64.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390x-tevx-linux64.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390x-gs-linux64.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390-core32.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390-core64.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390x-core64.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390-acr.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390-fpr.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390-tdb.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390-vx.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390-gs.xml"
-			srv_xmlfiles="${srv_xmlfiles} s390-gsbc.xml"
 			srv_linux_usrregs=yes
 			srv_linux_regsets=yes
 			srv_linux_thread_db=yes
@@ -370,9 +271,6 @@  case "${target}" in
                         else
 			  srv_regobj=""
                         fi
-			srv_xmlfiles="${srv_xmlfiles} tic6x-core.xml"
-			srv_xmlfiles="${srv_xmlfiles} tic6x-gp.xml"
-			srv_xmlfiles="${srv_xmlfiles} tic6x-c6xp.xml"
 			srv_tgtobj="$srv_linux_obj linux-tic6x-low.o"
 			srv_tgtobj="${srv_tgtobj} arch/tic6x.o"
 			srv_linux_regsets=yes
@@ -386,7 +284,6 @@  case "${target}" in
 			srv_tgtobj="${srv_tgtobj} linux-btrace.o x86-linux.o"
 			srv_tgtobj="${srv_tgtobj} x86-linux-dregs.o"
 			srv_tgtobj="${srv_tgtobj} amd64-linux-siginfo.o"
-			srv_xmlfiles="$srv_i386_linux_xmlfiles $srv_amd64_linux_xmlfiles"
 			srv_linux_usrregs=yes # This is for i386 progs.
 			srv_linux_regsets=yes
 			srv_linux_thread_db=yes
@@ -397,13 +294,11 @@  case "${target}" in
   x86_64-*-mingw*)	srv_regobj=""
 			srv_tgtobj="x86-low.o x86-dregs.o i387-fp.o win32-low.o win32-i386-low.o"
 			srv_tgtobj="${srv_tgtobj} arch/amd64.o"
-			srv_xmlfiles="$srv_i386_xmlfiles $srv_amd64_xmlfiles"
 			srv_mingw=yes
 			;;
   x86_64-*-cygwin*)	srv_regobj=""
 			srv_tgtobj="x86-low.o x86-dregs.o i387-fp.o win32-low.o win32-i386-low.o"
 			srv_tgtobj="${srv_tgtobj} arch/amd64.o"
-			srv_xmlfiles="$srv_i386_xmlfiles"
 			;;

   xtensa*-*-linux*)	srv_regobj=reg-xtensa.o