Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Carl Love via Gdb-patches <gdb-patches@sourceware.org>
To: Pedro Alves <pedro@palves.net>, Kevin Buettner <kevinb@redhat.com>
Cc: gdb-patches@sourceware.org
Subject: RE: [PATCH V3] PowerPC: fix for gdb.base/eh_return.exp
Date: Thu, 09 Jun 2022 08:24:37 -0700	[thread overview]
Message-ID: <bf59a8ef27c95a7f067cea1e0f813e2edc4e8c64.camel@us.ibm.com> (raw)
In-Reply-To: <d913587c-c521-23f9-6354-2a3bc209b1fb@palves.net>

On Wed, 2022-06-08 at 19:32 +0100, Pedro Alves wrote:
> On 2022-06-02 17:52, Carl Love wrote:
> > Kevin:
> > 
> > On Wed, 2022-05-11 at 15:48 -0700, Kevin Buettner wrote:
> > > On Wed, 11 May 2022 14:52:32 -0700
> > > Carl Love <cel@us.ibm.com> wrote:
> > > 
> > > > +    # Disable the Traceback Table generation, using the
> > > > PowerPC
> > > > specific
> > > > +    # gcc option, so the test gdb_test_multiple "disassemble
> > > > eh2"
> > > > will match
> > > 
> > > What happens when some compiler other than gcc is used to run the
> > > test?
> > 
> > I updated the patch to set the compiler options for gcc and
> > XLC.  The
> > test was run on AIX and passes with the patch.  Note that AIX
> > actually
> > uses gcc to compile gdb.  We tried compiling gdb with the xlc
> > compiler.
> > We ran into other gdb compilation errors that we were not able to
> > resolve.  We were able to verify that the xlc options to disable
> > the
> > Traceback Buffer were right but that was it.  
> 
> The compiler used to build gdb does not have to be the same used to
> run tests.  You can build gdb with gcc as usual, and then run tests
> with some other compiler, like:
> 
>  $ make check RUNTESTFLAGS="CC_FOR_TARGET=foo CXX_FOR_TARGET=foo++"

I asked the AIX person about using gdb compiled with gdb but compiling
the test case with xlc.  Here is his reply:

   I used gcc to compile gdb as it’s not easy to compile gdb with xlc.
   To use the xlc for compiling test programs I have modified the site.exp 
   file with the Option “CC_FOR_TARGET” & “CXX_FOR_TARGET” to point to xlc 
   binary path along with proper CFLAGS & CXXFLAGS.
    
   I confirmed that for compiling the eh_return.c xlc compiler is being used.
    
   Here is the compilation output.
    
   builtin_spawn -ignore SIGHUP /opt/IBM/xlc/16.1.0/bin/xlc -q64 -g -O0 -w  
   -qdbgfmt=dwarf -c -g -o /.../gdb/testsuite/outputs/gdb.base/eh_return/eh_return0.o 
   /.../gdb/testsuite/gdb.base/eh_return.c

   But since test program eh_return.c was written with gcc in mind it wasn’t able
   to compile and giving the undefined error.  gdb compile failed, 
    ld: 0711-317 ERROR: Undefined symbol: .__builtin_eh_return.

So unfortunately, he wasn't able to actually run the gdb test but was
able to verify the compilation of the test.  

                  Carl Love



  parent reply	other threads:[~2022-06-09 15:25 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-05 20:07 [PATCH] " Carl Love via Gdb-patches
2022-05-06 18:08 ` Kevin Buettner via Gdb-patches
2022-05-06 21:16   ` Pedro Alves
2022-05-06 22:45     ` will schmidt via Gdb-patches
2022-05-09 19:17       ` [PATCH V2] " Carl Love via Gdb-patches
2022-05-09 20:57         ` will schmidt via Gdb-patches
2022-05-10 11:43           ` Pedro Alves
2022-05-11 21:52             ` Carl Love via Gdb-patches
2022-05-11 21:52           ` [PATCH V3] " Carl Love via Gdb-patches
2022-05-11 22:48             ` Kevin Buettner via Gdb-patches
2022-05-12 16:00               ` Carl Love via Gdb-patches
2022-06-02 16:52               ` Carl Love via Gdb-patches
2022-06-08 18:32                 ` Pedro Alves
2022-06-08 18:51                   ` Carl Love via Gdb-patches
2022-06-09 15:24                   ` Carl Love via Gdb-patches [this message]
2022-06-02 17:00             ` [PATCH V4] " Carl Love via Gdb-patches
2022-06-07 17:54               ` will schmidt via Gdb-patches
2022-06-08 15:33                 ` [PATCH V5] " Carl Love via Gdb-patches
2022-06-08 15:36                   ` Carl Love via Gdb-patches
2022-06-08 16:29                     ` will schmidt via Gdb-patches
2022-07-13 17:07                     ` [Ping] " Carl Love via Gdb-patches
2022-07-15 13:41                     ` Ulrich Weigand via Gdb-patches

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=bf59a8ef27c95a7f067cea1e0f813e2edc4e8c64.camel@us.ibm.com \
    --to=gdb-patches@sourceware.org \
    --cc=cel@us.ibm.com \
    --cc=kevinb@redhat.com \
    --cc=pedro@palves.net \
    /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