This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[patch] tic4x/c4x configuration files


Hello,

gcc has support for the TMS320C4x DSP, named 'c4x'. binutils has also support for this DSP, but under the target name 'tic4x'. The tic4x name has been selected recently to be the new official name for this target, because 1) it is more descriptive and 2) it is compatble with other targets from texas instruments (examples are tic30, tic54x, tic80). Thus, the files/target in binutils uses tic4x-something. Since the gcc version is older, the files and target is named c4x-something.

To maintain compability, a top-level configuration patch has been committed which makes is possible to use both 'tic4x' and 'c4x' as target names to binutils for this particular target. Unfortunately, this will break the compability with gcc as soon as the gcc maintainers import config.sub from the central master repository (subversion:/cvsroot/config).

The attached patch will fix the configuration of gcc and make it possible to use both 'tic4x' and 'c4x' as target names for gcc, similar to the feature of binutils. The users can then choose to use the old 'c4x' target or the new 'tic4x' target in both binutils and gcc. The patch contains three files:

1) config.sub. Either use this patch or import the latest from the master config repositry in subversions, please.

2) configure.in. I have currently committed this patch (i.e. this file) to binutils as well, so we'll see whom beats whom to it. (BTW How does binutils and gcc keep this file synchroized with each others? configure.in is not a part of the master config repository as I can see, but they are evidently being synched.) Anyhow, this file must at least be patched in the gcc repository to make compilation work.

3) gcc/config.gcc.

PS! IMHO It is a bit cruical that this patch makes the 3.3 release of gcc, please.


Svein


ChangeLog:
2002-09-28 Svein E. Seldal <Svein.Seldal@solidas.com>

* config.sub: Added the tic4x target
* configure.in: Added the tic4x target

gcc/ChangeLog:
2002-09-28 Svein E. Seldal <Svein.Seldal@solidas.com>

* config.gcc: Recogize tic4x as valid target-alias for c4x.
Index: config.sub
===================================================================
RCS file: /cvsroot/gcc/gcc/config.sub,v
retrieving revision 1.69
diff -c -3 -p -r1.69 config.sub
*** config.sub	20 Aug 2002 21:53:23 -0000	1.69
--- config.sub	28 Sep 2002 14:49:10 -0000
*************** case $basic_machine in
*** 229,235 ****
  	| alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \
  	| alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \
  	| arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr \
! 	| c4x | clipper \
  	| d10v | d30v | dlx | dsp16xx \
  	| fr30 | frv \
  	| h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
--- 229,235 ----
  	| alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \
  	| alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \
  	| arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr \
! 	| clipper \
  	| d10v | d30v | dlx | dsp16xx \
  	| fr30 | frv \
  	| h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
*************** case $basic_machine in
*** 294,300 ****
  	| arm-*  | armbe-* | armle-* | armeb-* | armv*-* \
  	| avr-* \
  	| bs2000-* \
! 	| c[123]* | c30-* | [cjt]90-* | c54x-* \
  	| clipper-* | cydra-* \
  	| d10v-* | d30v-* | dlx-* \
  	| elxsi-* \
--- 294,300 ----
  	| arm-*  | armbe-* | armle-* | armeb-* | armv*-* \
  	| avr-* \
  	| bs2000-* \
! 	| c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* \
  	| clipper-* | cydra-* \
  	| d10v-* | d30v-* | dlx-* \
  	| elxsi-* \
*************** case $basic_machine in
*** 329,335 ****
  	| shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
  	| sparc-* | sparc64-* | sparc86x-* | sparclet-* | sparclite-* \
  	| sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \
! 	| tahoe-* | thumb-* | tic30-* | tic54x-* | tic80-* | tron-* \
  	| v850-* | v850e-* | vax-* \
  	| we32k-* \
  	| x86-* | x86_64-* | xps100-* | xscale-* | xstormy16-* \
--- 329,335 ----
  	| shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
  	| sparc-* | sparc64-* | sparc86x-* | sparclet-* | sparclite-* \
  	| sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \
! 	| tahoe-* | thumb-* | tic30-* | tic4x-* | tic54x-* | tic80-* | tron-* \
  	| v850-* | v850e-* | vax-* \
  	| we32k-* \
  	| x86-* | x86_64-* | xps100-* | xscale-* | xstormy16-* \
*************** case $basic_machine in
*** 913,918 ****
--- 913,922 ----
  		basic_machine=t90-cray
  		os=-unicos
  		;;
+ 	tic4x | c4x*)
+ 		basic_machine=tic4x-unknown
+ 		os=-coff
+ 		;;
  	tic54x | c54x*)
  		basic_machine=tic54x-unknown
  		os=-coff
*************** case $basic_machine in
*** 1046,1055 ****
  		;;
  	pmac | pmac-mpw)
  		basic_machine=powerpc-apple
- 		;;
- 	c4x*)
- 		basic_machine=c4x-none
- 		os=-coff
  		;;
  	*-unknown)
  		# Make sure to match an already-canonicalized machine name.
--- 1050,1055 ----
Index: configure.in
===================================================================
RCS file: /cvsroot/gcc/gcc/configure.in,v
retrieving revision 1.184
diff -c -3 -p -r1.184 configure.in
*** configure.in	28 Sep 2002 12:19:19 -0000	1.184
--- configure.in	28 Sep 2002 14:49:11 -0000
*************** case "${target}" in
*** 361,367 ****
    avr-*-*)
      noconfigdirs="$noconfigdirs target-libiberty ${libstdcxx_version} ${libgcj}"
      ;;
!   c4x-*-*)
      noconfigdirs="$noconfigdirs ${libstdcxx_version} target-libgloss ${libgcj}"
      ;;
    c54x*-*-* | tic54x-*-*)
--- 361,367 ----
    avr-*-*)
      noconfigdirs="$noconfigdirs target-libiberty ${libstdcxx_version} ${libgcj}"
      ;;
!   c4x-*-* | tic4x-*-*)
      noconfigdirs="$noconfigdirs ${libstdcxx_version} target-libgloss ${libgcj}"
      ;;
    c54x*-*-* | tic54x-*-*)
Index: gcc/config.gcc
===================================================================
RCS file: /cvsroot/gcc/gcc/gcc/config.gcc,v
retrieving revision 1.250
diff -c -3 -p -r1.250 config.gcc
*** gcc/config.gcc	26 Sep 2002 10:42:04 -0000	1.250
--- gcc/config.gcc	28 Sep 2002 14:49:12 -0000
*************** sparc*-*-*)
*** 283,288 ****
--- 283,291 ----
  sh[123456789l]*-*-*)
  	cpu_type=sh
  	;;
+ tic4x-*-*)
+         cpu_type=c4x
+         ;;
  esac
  
  tm_file=${cpu_type}/${cpu_type}.h
*************** arm-*-pe*)
*** 673,679 ****
  	;;
  avr-*-*)
  	;;
! c4x-*-rtems*)
  	xm_defines=POSIX
  	tmake_file="c4x/t-c4x t-rtems"
  	tm_file="c4x/c4x.h c4x/rtems.h rtems.h"
--- 676,682 ----
  	;;
  avr-*-*)
  	;;
! c4x-*-rtems* | tic4x-*-rtems*)
  	xm_defines=POSIX
  	tmake_file="c4x/t-c4x t-rtems"
  	tm_file="c4x/c4x.h c4x/rtems.h rtems.h"
*************** c4x-*-rtems*)
*** 683,689 ****
  	c_target_objs="c4x-c.o"
  	cxx_target_objs="c4x-c.o"
  	;;
! c4x-*)
  	tmake_file=c4x/t-c4x
  	c_target_objs="c4x-c.o"
  	cxx_target_objs="c4x-c.o"
--- 686,692 ----
  	c_target_objs="c4x-c.o"
  	cxx_target_objs="c4x-c.o"
  	;;
! c4x-* | tic4x-*)
  	tmake_file=c4x/t-c4x
  	c_target_objs="c4x-c.o"
  	cxx_target_objs="c4x-c.o"

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]