Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Andrew Cagney <ac131313@cygnus.com>
To: Stephane Carrez <Stephane.Carrez@worldnet.fr>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [RFA]: Fix gdb.base/remote for embedded targets (HC11)
Date: Wed, 06 Jun 2001 09:07:00 -0000	[thread overview]
Message-ID: <3B1E4253.4030801@cygnus.com> (raw)
In-Reply-To: <3B07AFCF.211DC3BF@worldnet.fr>

> Hi!
> 
> The gdb.base/remote test fails for 68HC11/68HC12:
> 
>   - The gdb.base/remote.c defines a data table that is too large to link for
>     68HC11 targets (it requires 48K of data).  
> 
>   - For HC11/HC12, the data section is installed by the crt0.  The data section
>     has its image in ROM and it is copied to RAM by the startup code.  With a
>     48K data table, it requires 96K of memory (48K rom, 48K ram).
> 
>     After the load, the data table is not initialized.  It is initialized when
>     we reached the 'main'.
> 
> The following patch improves the gdb.base/remote test:
> 
>   - The remote.c data table is reduced to 1K for 68HC11 (only), and the
>     test verifies only the 1K load for 68HC11 (other platforms still use 48K).
> 
>   - It checks for a new 'gdb,noloaddata' configuration variable and
>     runs to the main before verifying the load.
> 
> Can you approve this patch?
> 
> Thanks,
> 	Stephane
> 
> 2001-05-20  Stephane Carrez  <Stephane.Carrez@worldnet.fr>
> 
> * gdb.base/remote.c (RANDOM_DATA_SIZE): New define, defaults to 48K 
> 	and defined to 1K for m68hc11.
> 	(random_data): Reduce table to 1K for embedded platforms (68hc11).
> 	* gdb.base/remote.exp (remote_data_size): New variable to tell the size
> 	of the data table; don't test past this size; check for gdb,noloaddata
> 	and run to the main if it is set (data section installed by crt0).


This problem definitly needs to be fixed.  remote.c is currently very 
16bit unfriendly.  A few thoughts - can your change be simplified slightly:

o 
Always run-to-main?
	I don't think it would do any
	harm to always do this

o 
can GDB extract the array size from the target?
	See sizeof.exp:get_sizeof()

o 
as for remote.c:RANDOM_DATA_SIZE
	I can't think of another way of
	doing this.  Anyone?

	Andrew




       reply	other threads:[~2001-06-06  9:07 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <3B07AFCF.211DC3BF@worldnet.fr>
2001-06-06  9:07 ` Andrew Cagney [this message]
2001-07-17 11:36   ` Stephane Carrez
2001-07-17 11:53     ` Fernando Nasser

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3B1E4253.4030801@cygnus.com \
    --to=ac131313@cygnus.com \
    --cc=Stephane.Carrez@worldnet.fr \
    --cc=gdb-patches@sources.redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox