This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
[RFA] Add ix86 target to asm-source.exp test
- From: Michael Snyder <msnyder at cygnus dot com>
- To: gdb-patches at sources dot redhat dot com
- Cc: cagney at redhat dot com, fnasser at redhat dot com
- Date: Tue, 20 Nov 2001 17:51:20 -0800
- Subject: [RFA] Add ix86 target to asm-source.exp test
This is a minimal port of the asm-source test to the i[3456]86 target.
This runs successfully on a Linux x86 machine, but will probably need
some work to make it run on other ix86 platforms (esp. embedded).
The file "i386.inc" is appended at the end of the patch.
Andrew -- since Fernando is stepping down as testsuite maintainer,
and since you've tinkered with asm-source, perhaps you could play
the role of second-pair-of-eyes?
Michael
2001-11-20 Michael Snyder <msnyder@redhat.com>
* gdb.asm/i386.inc: New file.
* gdb.asm/asm-source.exp: Recognize ix86 target.
* gdb.asm/configure.in: Recognize ix86 target.
* gdb.asm/configure: Regenerate.
Index: configure
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.asm/configure,v
retrieving revision 1.1.1.1
diff -c -3 -p -r1.1.1.1 configure
*** configure 1999/04/16 01:34:30 1.1.1.1
--- configure 2001/11/21 01:46:48
*************** test "$host_alias" != "$target_alias" &&
*** 634,639 ****
--- 634,640 ----
archinc=common.inc
case ${target} in
d10v-*-*) archinc=d10v.inc ;;
+ i[3456]86*) archinc=i386.inc ;;
esac
Index: configure.in
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.asm/configure.in,v
retrieving revision 1.1.1.1
diff -c -3 -p -r1.1.1.1 configure.in
*** configure.in 1999/04/16 01:34:30 1.1.1.1
--- configure.in 2001/11/21 01:46:48
*************** dnl In default case we need to link with
*** 16,21 ****
--- 16,22 ----
archinc=common.inc
case ${target} in
d10v-*-*) archinc=d10v.inc ;;
+ i[3456]86*) archinc=i386.inc ;;
esac
AC_LINK_FILES($archinc,arch.inc)
Index: asm-source.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.asm/asm-source.exp,v
retrieving revision 1.5
diff -c -3 -p -r1.5 asm-source.exp
*** asm-source.exp 2001/11/10 01:44:43 1.5
--- asm-source.exp 2001/11/21 01:46:48
*************** set asm-flags ""
*** 37,42 ****
--- 37,45 ----
if [istarget "d10v-*-*"] then {
set asm-arch d10v
}
+ if [istarget "i\[3456\]86-*-*"] then {
+ set asm-arch i386
+ }
if { "${asm-arch}" == "" } {
gdb_suppress_entire_file "Assembly source test -- not implemented for this target."
}
comment "subroutine prologue"
.macro gdbasm_enter
push %ebp
mov %esp,%ebp
.endm
comment "subroutine epilogue"
.macro gdbasm_leave
pop %ebp
ret
.endm
.macro gdbasm_call subr
call \subr
.endm
.macro gdbasm_several_nops
nop
nop
nop
nop
.endm
comment "exit (0)"
.macro gdbasm_exit0
hlt
.endm
comment "crt0 startup"
.macro gdbasm_startup
xor %ebp, %ebp
.endm