public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* [patch] add target Score to Binutils
@ 2006-08-29 11:08 ligang
  2006-09-11 14:45 ` Nick Clifton
  0 siblings, 1 reply; 7+ messages in thread
From: ligang @ 2006-08-29 11:08 UTC (permalink / raw)
  To: binutils

[-- Attachment #1: Type: text/plain, Size: 5634 bytes --]

Hello Maintainers,

Here is a patch to add target Score to GNU Binutils.
I volunteer to become the Score port maintainer.

ChangeLog:
1. GAS part 
1.1 binutils-2.16.1/config.sub
        score|score-*)
                basic_machine=score-linux
                os=-elf
                ;;

1.2 add files to binutils-2.16.1/gas/config
    tc-score.c
    tc-score.h
    score-datadep.h
    score-inst.h
 
1.3 gas/Makefile.in
1.3.1 CPU_TYPES = score \
1.3.2 TARGET_CPU_CFILES = config/tc-score.c \
1.3.3 TARGET_CPU_HFILES = config/tc-score.h \
1.3.4
DEPTC_score_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h  \
  $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
  $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-score.h 
\
  $(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h  \
  $(INCDIR)/elf/score.h $(INCDIR)/elf/reloc-macros.h \
  dwarf2dbg.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h
  $(srcdir)/config/score-inst.h $(srcdir)/config/score-datadep.h
 
1.4 gas/configure.tgt
1.4.1 
      score*)           cpu_type=score endian=big ;;
      score*l)          cpu_type=score endian=little ;;
1.4.2   score-*-elf)                          fmt=elf bfd_gas=yes ;;

2. BFD part
2.1 
2.1.1 add files to binutils-2.16.1/bfd
      elf32-score.c
      cpu-score.c
2.1.2 add files to binutils-2.16.1/include/elf
      score.h

2.2 bfd/configure
    bfd_elf32_bigscore_vec)     tb="$tb elf32-score.lo elf32.lo $elf" ;;
    bfd_elf32_littlescore_vec)  tb="$tb elf32-score.lo elf32.lo $elf" ;; 
 
2.3 bfd/Makefile.in
2.3.1 ALL_MACHINES = cpu-score.lo \
2.3.2 ALL_MACHINES_CFILES = cpu-score.c \
2.3.3 BFD32_BACKENDS = elf32-score.lo \
2.3.4 BFD32_BACKENDS_CFILES = elf32-score.c \
2.3.5 SOURCE_HFILES = elf32-score.h
2.3.6 cpu-score.lo: cpu-score.c $(INCDIR)/filenames.h
2.3.7 
elf32-score.lo: elf32-score.c $(INCDIR)/filenames.h \
  elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
  $(INCDIR)/elf/external.h $(INCDIR)/elf/score.h 
$(INCDIR)/elf/reloc-macros.h \
  elf32-score.h elf32-target.h

2.4 bfd/config.bfd
    score*-*-elf*)
      targ_defvec=bfd_elf32_bigscore_vec
      targ_selvecs=bfd_elf32_littlescore_vec
      ;;
 
2.5 bfd/targets.c
2.5.1 extern const bfd_target bfd_elf32_bigscore_vec;
2.5.2 extern const bfd_target bfd_elf32_littlescore_vec;
2.5.3 &bfd_elf32_bigscore_vec,
2.5.4 &bfd_elf32_littlescore_vec, 
 
2.6 bfd/archures.c
2.6.1 .  bfd_arch_score,     {* Sunplus score *} 
2.6.2 extern const bfd_arch_info_type bfd_score_arch;
2.6.3 static const bfd_arch_info_type * const bfd_archures_list[] = 
&bfd_score_arch,

2.7 bfd/bfd-in2.h
/* Score relocations.  */
  /* low 16 bit for ldst.  */
  BFD_RELOC_SCORE_DUMMY1,
  BFD_RELOC_GPREL15,
  BFD_RELOC_SCORE_DUMMY2,
  /* This is a 24-bit reloc with the right 1 bits assumed to be 0.  */
  BFD_RELOC_SCORE_JMP,
  /* This is a 19-bit reloc with the right 1 bits assumed to be 0.  */ 
  BFD_RELOC_SCORE_BRANCH,
  /* This is a 11-bit reloc with the right 1 bits assumed to be 0.  */ 
  BFD_RELOC_SCORE16_JMP,
  /* This is a 8-bit reloc with the right 1 bits assumed to be 0.  */
  BFD_RELOC_SCORE16_BRANCH,

2.8 binutils-2.16.1/include/elf/common.h
   #define EM_SCORE        135     /* Sunplus Score */


3. LD part
3.1 add files to binutils-2.16.1/ld/emultempl
    scoreelf.em
    add files to binutils-2.16.1/ld/emulparams
    scoreelf.sh

3.2 ld/configure.tgt
    score-*-elf)                targ_emul=scoreelf ;;

3.3 ld/Makefile.in
3.3.1 ALL_EMULATIONS = escoreelf.o \
3.3.2
escoreelf.c: $(srcdir)/emulparams/scoreelf.sh \
  $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/scoreelf.em \
  $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
        ${GENSCRIPTS} scoreelf "$(tdir_scoreelf)"
 
 
4. Opcodes part
4.1 add files to binutils-2.16.1/opcodes
   score-dis.c score-opc.h 

4.2 opcodes/configure
        bfd_score_arch)         ta="$ta score-dis.lo" ;;

4.3 opcodes/Makefile.in
4.3.1 HFILES = score-opc.h \
4.3.2 CFILES = score-dis.c \
4.3.3 ALL_MACHINES = score-dis.lo \
4.3.4 
score-dis.lo: score-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
  $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h score-opc.h \
  $(INCDIR)/bfdlink.h opintl.h $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h 
\
  $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/elf/score.h 
\
  $(INCDIR)/elf/reloc-macros.h

4.4 opcodes/disassemble.c
4.4.1 #define ARCH_score
4.4.2
#ifdef ARCH_score
    case bfd_arch_score:
      if (bfd_big_endian (abfd))
        disassemble = print_insn_big_score;
      else
        disassemble = print_insn_little_score;
     break;
#endif 
 
4.5 include/dis-asm.h
extern int print_insn_big_score         (bfd_vma, disassemble_info *);
extern int print_insn_little_score      (bfd_vma, disassemble_info *);


5. Binutils part
5.1 binutils/Makefile.in
    readelf.o : $(INCDIR)/elf/score.h

5.2 binutils/readelf.c
    add score specific code


6. Testsuite part
6.1 gas/testsuite/gas/elf/elf.exp
    加上如下代码
    if {[istarget "score-*-*"]} then {
        set target_machine -score
    }
    并且在 gas/testsuite/gas/elf/ 下添加文件 section2.e-score
6.2 ld/testsuite/ld-srec/srec.exp 
     在两个地方加上 setup_xfail "score-*-*"
6.3 ld/testsuite/ld-elf/merge.d
     加上 "score-*-*"
6.4 ld/testsuite/ld-elfcomm/elfcomm.exp
    加上如下代码
    if { [istarget score-*-*] } {
    untested $test1w1
    untested $test1w2
    untested $test1c1
    untested $test1c2
    return
    }




Best regards
                     Ligang

[-- Attachment #2: Score_Binutils_patch.tar.bz2 --]
[-- Type: application/octet-stream, Size: 150096 bytes --]

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

* Re: [patch] add target Score to Binutils
  2006-08-29 11:08 [patch] add target Score to Binutils ligang
@ 2006-09-11 14:45 ` Nick Clifton
  0 siblings, 0 replies; 7+ messages in thread
From: Nick Clifton @ 2006-09-11 14:45 UTC (permalink / raw)
  To: ligang; +Cc: binutils

[-- Attachment #1: Type: text/plain, Size: 290 bytes --]

Hi Ligang,

> Here is a patch to add target Score to GNU Binutils.

Before we can consider accepting your patch, we need to have a copyright 
assignment on file with the FSF.  I am attaching the email form that 
needs to be filled out that will start this process running.

Cheers
   Nick


[-- Attachment #2: future --]
[-- Type: text/plain, Size: 1005 bytes --]

---------------------------------------------------------------------------

request-assign.future:

Please email the following information to fsf-records@gnu.org, and we
will send you the assignment form for your past and future changes.
Please use your full name as the subject line of the message.


[What is the name of the program or package you're contributing to?]


[Did you copy any files or text written by someone else in these changes?
Even if that material is free software, we need to know about it.]


[Do you have an employer who might have a basis to claim to own
your changes?  Do you attend a school which might make such a claim?]


[For the copyright registration, what country are you a citizen of?]


[What year were you born?]


[Please write your email address here.]


[Please write your snail address here.]





[Which files have you changed so far, and which new files have you written
so far?]





---------------------------------------------------------------------------

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

* Re: [patch] add target Score to Binutils
  2006-09-26 14:18     ` Nick Clifton
@ 2006-09-27 22:32       ` ligang
  0 siblings, 0 replies; 7+ messages in thread
From: ligang @ 2006-09-27 22:32 UTC (permalink / raw)
  To: Nick Clifton, binutils; +Cc: bjgnu

Hi Nick,

Thank you so much.
I am looking forward to the write access to the repository.
Thanks your job again.

Best regards
                     Ligang

binutils-owner@sourceware.org wrote on 2006-09-26 22:02:27:

> Hi Ligang,
> 
> > I wanna know when you will check Score patch in to binutils mainline 
> > source.
> 
> It *is* checked in.  It was checked in on the 17th of September.
> 
> > Do you agree to grant me the maintainer of target Score?
> 
> Yes in principle, although I would like to see the quality of some 
> future patches before granting you write access to the repository.  But 
> you are right, I have not updated the MAINTAINERS file, so I will do 
> that now.
> 
> Cheers
>    Nick
> 
> binutils/ChangeLog
> 2006-09-26  Nick Clifton  <nickc@redhat.com>
> 
>    * MAINTAINERS: Add Mei Ligang as maintainer of the Score port.
> 

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

* Re: [patch] add target Score to Binutils
  2006-09-26  8:14   ` ligang
@ 2006-09-26 14:18     ` Nick Clifton
  2006-09-27 22:32       ` ligang
  0 siblings, 1 reply; 7+ messages in thread
From: Nick Clifton @ 2006-09-26 14:18 UTC (permalink / raw)
  To: ligang; +Cc: binutils, gjgnu

Hi Ligang,

> I wanna know when you will check Score patch in to binutils mainline 
> source.

It *is* checked in.  It was checked in on the 17th of September.

> Do you agree to grant me the maintainer of target Score?

Yes in principle, although I would like to see the quality of some 
future patches before granting you write access to the repository.  But 
you are right, I have not updated the MAINTAINERS file, so I will do 
that now.

Cheers
   Nick

binutils/ChangeLog
2006-09-26  Nick Clifton  <nickc@redhat.com>

	* MAINTAINERS: Add Mei Ligang as maintainer of the Score port.

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

* Re: [patch] add target Score to Binutils
  2006-09-25 16:14 ` Nick Clifton
@ 2006-09-26  8:14   ` ligang
  2006-09-26 14:18     ` Nick Clifton
  0 siblings, 1 reply; 7+ messages in thread
From: ligang @ 2006-09-26  8:14 UTC (permalink / raw)
  To: Nick Clifton, binutils; +Cc: gjgnu

Hi Nick,

Do you have any comment on Score patch? 
I wanna know when you will check Score patch in to binutils mainline 
source.
Do you agree to grant me the maintainer of target Score?

Thanks your time.
         Ligang

Nick Clifton <nickc@redhat.com> wrote on 2006-09-26 00:07:01:

> Hi Ligang,
> 
> >> One other thing - your submission included a suggested change to the 
top 
> >> level config.sub file.  This file is not part of the binutils project 

> >> and you will need to submit a separate patch to have it changed. This 

> >> patch should be sent to config-patches@gnu.org.
> > 
> > I have sent the change of config.sub to config-patches@gnu.org.
> > What is the next step to enter binutils main tree? 
> 
> Once the patch is accepted by the config maintainer he/she will check it 

> in to the mainline sources for you.

> Cheers
>    Nick
> 
> 

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

* Re: [patch] add target Score to Binutils
  2006-09-19 11:48 ligang
@ 2006-09-25 16:14 ` Nick Clifton
  2006-09-26  8:14   ` ligang
  0 siblings, 1 reply; 7+ messages in thread
From: Nick Clifton @ 2006-09-25 16:14 UTC (permalink / raw)
  To: ligang; +Cc: binutils

Hi Ligang,

>> One other thing - your submission included a suggested change to the top 
>> level config.sub file.  This file is not part of the binutils project 
>> and you will need to submit a separate patch to have it changed.  This 
>> patch should be sent to config-patches@gnu.org.
> 
> I have sent the change of config.sub to config-patches@gnu.org.
> What is the next step to enter binutils main tree? 

Once the patch is accepted by the config maintainer he/she will check it 
in to the mainline sources for you.

Cheers
   Nick


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

* [patch] add target Score to Binutils
@ 2006-09-04 10:51 梅丽刚
  0 siblings, 0 replies; 7+ messages in thread
From: 梅丽刚 @ 2006-09-04 10:51 UTC (permalink / raw)
  To: binutils

[-- Attachment #1: Type: text/plain, Size: 5446 bytes --]

Hello Maintainers,

Here is a patch to add target Score to GNU Binutils.
I volunteer to become the Score port maintainer.
Please handle it.

ChangeLog:
1. GAS part 
1.1 BINUTILS_DIR/config.sub
        score|score-*)
                basic_machine=score-linux
                os=-elf
                ;;

1.2 add files to BINUTILS_DIR/gas/config
    tc-score.c
    tc-score.h
    score-datadep.h
    score-inst.h
 
1.3 gas/Makefile.in
1.3.1 CPU_TYPES = score \
1.3.2 TARGET_CPU_CFILES = config/tc-score.c \
1.3.3 TARGET_CPU_HFILES = config/tc-score.h \
1.3.4
DEPTC_score_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h  \
  $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
  $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-score.h 
\
  $(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h  \
  $(INCDIR)/elf/score.h $(INCDIR)/elf/reloc-macros.h \
  dwarf2dbg.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h
  $(srcdir)/config/score-inst.h $(srcdir)/config/score-datadep.h
 
1.4 gas/configure.tgt
1.4.1 
      score*)           cpu_type=score endian=big ;;
      score*l)          cpu_type=score endian=little ;;
1.4.2   score-*-elf)                          fmt=elf bfd_gas=yes ;;

2. BFD part
2.1 
2.1.1 add files to BINUTILS_DIR/bfd
      elf32-score.c
      cpu-score.c
2.1.2 add files to BINUTILS_DIR/include/elf
      score.h

2.2 bfd/configure
    bfd_elf32_bigscore_vec)     tb="$tb elf32-score.lo elf32.lo $elf" ;;
    bfd_elf32_littlescore_vec)  tb="$tb elf32-score.lo elf32.lo $elf" ;; 
 
2.3 bfd/Makefile.in
2.3.1 ALL_MACHINES = cpu-score.lo \
2.3.2 ALL_MACHINES_CFILES = cpu-score.c \
2.3.3 BFD32_BACKENDS = elf32-score.lo \
2.3.4 BFD32_BACKENDS_CFILES = elf32-score.c \
2.3.5 SOURCE_HFILES = elf32-score.h
2.3.6 cpu-score.lo: cpu-score.c $(INCDIR)/filenames.h
2.3.7 
elf32-score.lo: elf32-score.c $(INCDIR)/filenames.h \
  elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
  $(INCDIR)/elf/external.h $(INCDIR)/elf/score.h 
$(INCDIR)/elf/reloc-macros.h \
  elf32-score.h elf32-target.h

2.4 bfd/config.bfd
2.4.1 score*)          targ_archs=bfd_score_arch ;;
2.4.2    score*-*-elf*)
           targ_defvec=bfd_elf32_bigscore_vec
           targ_selvecs=bfd_elf32_littlescore_vec
           ;;
 
2.5 bfd/targets.c
2.5.1 extern const bfd_target bfd_elf32_bigscore_vec;
2.5.2 extern const bfd_target bfd_elf32_littlescore_vec;
2.5.3 &bfd_elf32_bigscore_vec,
2.5.4 &bfd_elf32_littlescore_vec, 
 
2.6 bfd/archures.c
2.6.1 .  bfd_arch_score,     {* Sunplus score *} 
2.6.2 extern const bfd_arch_info_type bfd_score_arch;
2.6.3 static const bfd_arch_info_type * const bfd_archures_list[] = 
&bfd_score_arch,

2.7 bfd/bfd-in2.h
/* Score relocations.  */
  /* low 16 bit for ldst.  */
  BFD_RELOC_SCORE_DUMMY1,
  BFD_RELOC_GPREL15,
  BFD_RELOC_SCORE_DUMMY2,
  /* This is a 24-bit reloc with the right 1 bits assumed to be 0.  */
  BFD_RELOC_SCORE_JMP,
  /* This is a 19-bit reloc with the right 1 bits assumed to be 0.  */ 
  BFD_RELOC_SCORE_BRANCH,
  /* This is a 11-bit reloc with the right 1 bits assumed to be 0.  */ 
  BFD_RELOC_SCORE16_JMP,
  /* This is a 8-bit reloc with the right 1 bits assumed to be 0.  */
  BFD_RELOC_SCORE16_BRANCH,

2.8 BINUTILS_DIR/include/elf/common.h
   #define EM_SCORE        135     /* Sunplus Score */


3. LD part
3.1 add files to BINUTILS_DIR/ld/emultempl
    scoreelf.em
    add files to BINUTILS_DIR/ld/emulparams
    scoreelf.sh

3.2 ld/configure.tgt
    score-*-elf)                targ_emul=scoreelf ;;

3.3 ld/Makefile.in
3.3.1 ALL_EMULATIONS = escoreelf.o \
3.3.2
escoreelf.c: $(srcdir)/emulparams/scoreelf.sh \
  $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/scoreelf.em \
  $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
        ${GENSCRIPTS} scoreelf "$(tdir_scoreelf)"
 
 
4. Opcodes part
4.1 add files to BINUTILS_DIR/opcodes
   score-dis.c score-opc.h 

4.2 opcodes/configure
        bfd_score_arch)         ta="$ta score-dis.lo" ;;

4.3 opcodes/Makefile.in
4.3.1 HFILES = score-opc.h \
4.3.2 CFILES = score-dis.c \
4.3.3 ALL_MACHINES = score-dis.lo \
4.3.4 
score-dis.lo: score-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
  $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h score-opc.h \
  $(INCDIR)/bfdlink.h opintl.h $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h 
\
  $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/elf/score.h 
\
  $(INCDIR)/elf/reloc-macros.h

4.4 opcodes/disassemble.c
4.4.1 #define ARCH_score
4.4.2
#ifdef ARCH_score
    case bfd_arch_score:
      if (bfd_big_endian (abfd))
        disassemble = print_insn_big_score;
      else
        disassemble = print_insn_little_score;
     break;
#endif 
 
4.5 include/dis-asm.h
extern int print_insn_big_score         (bfd_vma, disassemble_info *);
extern int print_insn_little_score      (bfd_vma, disassemble_info *);


5. Binutils part
5.1 binutils/Makefile.in
    readelf.o : $(INCDIR)/elf/score.h

5.2 binutils/readelf.c
    add score specific code


6. Testsuite part
6.1 gas/testsuite/gas/elf/elf.exp
    if {[istarget "score-*-*"]} then {
        set target_machine -score
    }
    add file section2.e-score to gas/testsuite/gas/elf/
6.2 ld/testsuite/ld-srec/srec.exp 
    setup_xfail "score-*-*"
6.3 ld/testsuite/ld-elf/merge.d
     "score-*-*"
6.4 ld/testsuite/ld-elfcomm/elfcomm.exp
    if { [istarget score-*-*] } {
    untested $test1w1
    untested $test1w2
    untested $test1c1
    untested $test1c2
    return
    }


Best regards
                     Ligang

[-- Attachment #2: Score_Binutils_patch.tar.bz2 --]
[-- Type: application/octet-stream, Size: 150096 bytes --]

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

end of thread, other threads:[~2006-09-27  9:46 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-08-29 11:08 [patch] add target Score to Binutils ligang
2006-09-11 14:45 ` Nick Clifton
2006-09-04 10:51 梅丽刚
2006-09-19 11:48 ligang
2006-09-25 16:14 ` Nick Clifton
2006-09-26  8:14   ` ligang
2006-09-26 14:18     ` Nick Clifton
2006-09-27 22:32       ` ligang

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