Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* [RFA/RFC] Multilibs and gdb.asm
@ 2002-04-05 13:19 Elena Zannoni
  2002-04-05 13:42 ` Daniel Jacobowitz
  2002-04-05 14:30 ` Fernando Nasser
  0 siblings, 2 replies; 8+ messages in thread
From: Elena Zannoni @ 2002-04-05 13:19 UTC (permalink / raw)
  To: gdb-patches


In gdb.asm/asm-source.exp, the testsuite passes multilib options to
the assembler according to the compiler syntax.
Obviously this doesn't work, as already noted by Nick Clifton in:

http://sources.redhat.com/ml/gdb-patches/2002-01/msg00282.html

A solution wasn't reached at the time.

I found it useful to just bail out of the test if some multilibs were
detected. At least it reduced the noise in the testsuite results.

Is this too drastic?

Elena


2002-04-05  Elena Zannoni  <ezannoni@redhat.com>

	* gdb.asm/asm-source.exp: Bail out if multilibs are detected.


Index: asm-source.exp
===================================================================
RCS file: /cvs/uberbaum/gdb/testsuite/gdb.asm/asm-source.exp,v
retrieving revision 1.19
diff -u -p -r1.19 asm-source.exp
--- asm-source.exp	2002/04/05 02:48:23	1.19
+++ asm-source.exp	2002/04/05 21:15:04
@@ -67,10 +67,29 @@ if { "${asm-arch}" == "" } {
     gdb_suppress_entire_file "Assembly source test -- not implemented for this target."
 }
 
+# Watch out, we are invoking the assembler, but the testsuite sets multilib
+# switches according to compiler syntax.  If we pass these options straight
+# to the assembler, they won't always make sense.  If we don't pass them to
+# the assembler, the final link will complain that the object files were
+# built with different defaults.  So no matter what we do, we lose.  We may as
+# well get out of this test sooner rather than later.
+set dest [target_info name]
+if [board_info $dest exists multilib_flags] {
+	set multilib_flags [board_info $dest multilib_flags]
+	if { "${multilib_flags}" != "" } {
+	   gdb_suppress_entire_file "Assembly source test -- multilibs not supported by this test."
+	   return;
+	 }
+}
+
 set testfile "asm-source"


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

* Re: [RFA/RFC] Multilibs and gdb.asm
  2002-04-05 13:19 [RFA/RFC] Multilibs and gdb.asm Elena Zannoni
@ 2002-04-05 13:42 ` Daniel Jacobowitz
  2002-04-05 13:50   ` Andrew Cagney
  2002-04-05 18:15   ` Michael Snyder
  2002-04-05 14:30 ` Fernando Nasser
  1 sibling, 2 replies; 8+ messages in thread
From: Daniel Jacobowitz @ 2002-04-05 13:42 UTC (permalink / raw)
  To: Elena Zannoni; +Cc: gdb-patches

On Fri, Apr 05, 2002 at 04:19:20PM -0500, Elena Zannoni wrote:
> 
> In gdb.asm/asm-source.exp, the testsuite passes multilib options to
> the assembler according to the compiler syntax.
> Obviously this doesn't work, as already noted by Nick Clifton in:
> 
> http://sources.redhat.com/ml/gdb-patches/2002-01/msg00282.html
> 
> A solution wasn't reached at the time.
> 
> I found it useful to just bail out of the test if some multilibs were
> detected. At least it reduced the noise in the testsuite results.
> 
> Is this too drastic?

I've got a silly suggestion.  Is there any reason not to assemble by
invoking the compiler, for this test?  Let it do all the multilib
footwork.

-- 
Daniel Jacobowitz                           Carnegie Mellon University
MontaVista Software                         Debian GNU/Linux Developer


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

* Re: [RFA/RFC] Multilibs and gdb.asm
  2002-04-05 13:42 ` Daniel Jacobowitz
@ 2002-04-05 13:50   ` Andrew Cagney
  2002-04-05 18:14     ` Michael Snyder
  2002-04-05 18:15   ` Michael Snyder
  1 sibling, 1 reply; 8+ messages in thread
From: Andrew Cagney @ 2002-04-05 13:50 UTC (permalink / raw)
  To: Daniel Jacobowitz; +Cc: Elena Zannoni, gdb-patches

> On Fri, Apr 05, 2002 at 04:19:20PM -0500, Elena Zannoni wrote:
> 
>> 
>> In gdb.asm/asm-source.exp, the testsuite passes multilib options to
>> the assembler according to the compiler syntax.
>> Obviously this doesn't work, as already noted by Nick Clifton in:
>> 
>> http://sources.redhat.com/ml/gdb-patches/2002-01/msg00282.html
>> 
>> A solution wasn't reached at the time.
>> 
>> I found it useful to just bail out of the test if some multilibs were
>> detected. At least it reduced the noise in the testsuite results.
>> 
>> Is this too drastic?
> 
> 
> I've got a silly suggestion.  Is there any reason not to assemble by
> invoking the compiler, for this test?  Let it do all the multilib
> footwork.

What compiler?  (There may be an assembler and linker but no compiler)

Andrew


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

* Re: [RFA/RFC] Multilibs and gdb.asm
  2002-04-05 13:19 [RFA/RFC] Multilibs and gdb.asm Elena Zannoni
  2002-04-05 13:42 ` Daniel Jacobowitz
@ 2002-04-05 14:30 ` Fernando Nasser
  2002-04-05 15:05   ` Andrew Cagney
  1 sibling, 1 reply; 8+ messages in thread
From: Fernando Nasser @ 2002-04-05 14:30 UTC (permalink / raw)
  To: Elena Zannoni; +Cc: gdb-patches

This is very unfortunate, but if there is no way around it we
have no other choice.

Go ahead, please.

Fernando


Elena Zannoni wrote:
> 
> In gdb.asm/asm-source.exp, the testsuite passes multilib options to
> the assembler according to the compiler syntax.
> Obviously this doesn't work, as already noted by Nick Clifton in:
> 
> http://sources.redhat.com/ml/gdb-patches/2002-01/msg00282.html
> 
> A solution wasn't reached at the time.
> 
> I found it useful to just bail out of the test if some multilibs were
> detected. At least it reduced the noise in the testsuite results.
> 
> Is this too drastic?
> 
> Elena
> 
> 2002-04-05  Elena Zannoni  <ezannoni@redhat.com>
> 
>         * gdb.asm/asm-source.exp: Bail out if multilibs are detected.
> 
> Index: asm-source.exp
> ===================================================================
> RCS file: /cvs/uberbaum/gdb/testsuite/gdb.asm/asm-source.exp,v
> retrieving revision 1.19
> diff -u -p -r1.19 asm-source.exp
> --- asm-source.exp      2002/04/05 02:48:23     1.19
> +++ asm-source.exp      2002/04/05 21:15:04
> @@ -67,10 +67,29 @@ if { "${asm-arch}" == "" } {
>      gdb_suppress_entire_file "Assembly source test -- not implemented for this target."
>  }
> 
> +# Watch out, we are invoking the assembler, but the testsuite sets multilib
> +# switches according to compiler syntax.  If we pass these options straight
> +# to the assembler, they won't always make sense.  If we don't pass them to
> +# the assembler, the final link will complain that the object files were
> +# built with different defaults.  So no matter what we do, we lose.  We may as
> +# well get out of this test sooner rather than later.
> +set dest [target_info name]
> +if [board_info $dest exists multilib_flags] {
> +       set multilib_flags [board_info $dest multilib_flags]
> +       if { "${multilib_flags}" != "" } {
> +          gdb_suppress_entire_file "Assembly source test -- multilibs not supported by this test."
> +          return;
> +        }
> +}
> +
>  set testfile "asm-source"

-- 
Fernando Nasser
Red Hat Canada Ltd.                     E-Mail:  fnasser@redhat.com
2323 Yonge Street, Suite #300
Toronto, Ontario   M4P 2C9


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

* Re: [RFA/RFC] Multilibs and gdb.asm
  2002-04-05 14:30 ` Fernando Nasser
@ 2002-04-05 15:05   ` Andrew Cagney
  2002-04-07 17:10     ` Elena Zannoni
  0 siblings, 1 reply; 8+ messages in thread
From: Andrew Cagney @ 2002-04-05 15:05 UTC (permalink / raw)
  To: Fernando Nasser, Elena Zannoni; +Cc: gdb-patches

> This is very unfortunate, but if there is no way around it we
> have no other choice.
> 
> Go ahead, please.
> 
> Fernando
> 

Hmm, suggest a bug report as well to track this.  Er, there is a bug 
report tracking it!  See gdb/285.

Add ``Work around PR gdb/285.'' to the changelog/commit message?

enjoy,
Andrew



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

* Re: [RFA/RFC] Multilibs and gdb.asm
  2002-04-05 13:50   ` Andrew Cagney
@ 2002-04-05 18:14     ` Michael Snyder
  0 siblings, 0 replies; 8+ messages in thread
From: Michael Snyder @ 2002-04-05 18:14 UTC (permalink / raw)
  To: Andrew Cagney; +Cc: Daniel Jacobowitz, Elena Zannoni, gdb-patches

Andrew Cagney wrote:
> 
> > On Fri, Apr 05, 2002 at 04:19:20PM -0500, Elena Zannoni wrote:
> >
> >>
> >> In gdb.asm/asm-source.exp, the testsuite passes multilib options to
> >> the assembler according to the compiler syntax.
> >> Obviously this doesn't work, as already noted by Nick Clifton in:
> >>
> >> http://sources.redhat.com/ml/gdb-patches/2002-01/msg00282.html
> >>
> >> A solution wasn't reached at the time.
> >>
> >> I found it useful to just bail out of the test if some multilibs were
> >> detected. At least it reduced the noise in the testsuite results.
> >>
> >> Is this too drastic?
> >
> >
> > I've got a silly suggestion.  Is there any reason not to assemble by
> > invoking the compiler, for this test?  Let it do all the multilib
> > footwork.
> 
> What compiler?  (There may be an assembler and linker but no compiler)

No, Daniel's right.  At some point last year, we changed the test
so that it invokes "gdb_compile" to do the final link.  I think that
was because the compiler would figure out what libraries needed to
be linked in.  I've been vaguely worried about that change...


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

* Re: [RFA/RFC] Multilibs and gdb.asm
  2002-04-05 13:42 ` Daniel Jacobowitz
  2002-04-05 13:50   ` Andrew Cagney
@ 2002-04-05 18:15   ` Michael Snyder
  1 sibling, 0 replies; 8+ messages in thread
From: Michael Snyder @ 2002-04-05 18:15 UTC (permalink / raw)
  To: Daniel Jacobowitz; +Cc: Elena Zannoni, gdb-patches

Daniel Jacobowitz wrote:
> 
> On Fri, Apr 05, 2002 at 04:19:20PM -0500, Elena Zannoni wrote:
> >
> > In gdb.asm/asm-source.exp, the testsuite passes multilib options to
> > the assembler according to the compiler syntax.
> > Obviously this doesn't work, as already noted by Nick Clifton in:
> >
> > http://sources.redhat.com/ml/gdb-patches/2002-01/msg00282.html
> >
> > A solution wasn't reached at the time.
> >
> > I found it useful to just bail out of the test if some multilibs were
> > detected. At least it reduced the noise in the testsuite results.
> >
> > Is this too drastic?
> 
> I've got a silly suggestion.  Is there any reason not to assemble by
> invoking the compiler, for this test?  Let it do all the multilib
> footwork.

Oh, that would be a problem for targets where there is no compiler...


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

* Re: [RFA/RFC] Multilibs and gdb.asm
  2002-04-05 15:05   ` Andrew Cagney
@ 2002-04-07 17:10     ` Elena Zannoni
  0 siblings, 0 replies; 8+ messages in thread
From: Elena Zannoni @ 2002-04-07 17:10 UTC (permalink / raw)
  To: Andrew Cagney; +Cc: Fernando Nasser, Elena Zannoni, gdb-patches

Andrew Cagney writes:
 > > This is very unfortunate, but if there is no way around it we
 > > have no other choice.
 > > 
 > > Go ahead, please.
 > > 
 > > Fernando
 > > 
 > 
 > Hmm, suggest a bug report as well to track this.  Er, there is a bug 
 > report tracking it!  See gdb/285.
 > 
 > Add ``Work around PR gdb/285.'' to the changelog/commit message?
 > 
 > enjoy,
 > Andrew
 > 

Committed.

Elena


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

end of thread, other threads:[~2002-04-08  0:10 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-04-05 13:19 [RFA/RFC] Multilibs and gdb.asm Elena Zannoni
2002-04-05 13:42 ` Daniel Jacobowitz
2002-04-05 13:50   ` Andrew Cagney
2002-04-05 18:14     ` Michael Snyder
2002-04-05 18:15   ` Michael Snyder
2002-04-05 14:30 ` Fernando Nasser
2002-04-05 15:05   ` Andrew Cagney
2002-04-07 17:10     ` Elena Zannoni

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox