public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Jan Kratochvil <jkratoch@fedoraproject.org>
To: git-commits@fedoraproject.org
Subject: [rpms/gdb] gdb-17.2-rebase-f44: - archer-jankratochvil-fedora12 commit:
Date: Sat, 27 Jun 2026 23:54:19 GMT	[thread overview]
Message-ID: <178260445922.1.3886248785650818354.rpms-gdb-99fa6c959f83@fedoraproject.org> (raw)

            A new commit has been pushed.

            Repo   : rpms/gdb
            Branch : gdb-17.2-rebase-f44
            Commit : 99fa6c959f83ec29662eed8f6145a12c97676a64
            Author : Jan Kratochvil <jkratoch@fedoraproject.org>
            Date   : 2009-08-11T18:07:06+00:00
            Stats  : +478/-35 in 2 file(s)
            URL    : https://src.fedoraproject.org/rpms/gdb/c/99fa6c959f83ec29662eed8f6145a12c97676a64?branch=gdb-17.2-rebase-f44

            Log:
            - archer-jankratochvil-fedora12 commit:
    93f5e942bdcdcc376ece452c309bedabae71def9
- Fix "can't compute CFA for this frame" (by Tom Tromey, BZ 516627).

---
diff --git a/gdb-archer.patch b/gdb-archer.patch
index 6a010e4..b1b0e1d 100644
--- a/gdb-archer.patch
+++ b/gdb-archer.patch
@@ -2,7 +2,7 @@ http://sourceware.org/gdb/wiki/ProjectArcher
 http://sourceware.org/gdb/wiki/ArcherBranchManagement
 
 GIT snapshot:
-commit 81de3c6abae4f7e3738aa9bcc0ab2f8725cce252
+commit 93f5e942bdcdcc376ece452c309bedabae71def9
 
 branch `archer' - the merge of branches:
 archer-tromey-call-frame-cfa
@@ -3246,7 +3246,7 @@ index 4984f31..4bbbe4e 100644
  This observer is used for internal testing.  Do not use.  
  See testsuite/gdb.gdb/observer.exp.
 diff --git a/gdb/dwarf2-frame.c b/gdb/dwarf2-frame.c
-index 0f6da40..c1c162e 100644
+index 0f6da40..fc70309 100644
 --- a/gdb/dwarf2-frame.c
 +++ b/gdb/dwarf2-frame.c
 @@ -38,6 +38,7 @@
@@ -3271,7 +3271,18 @@ index 0f6da40..c1c162e 100644
  no_get_tls_address (void *baton, CORE_ADDR offset)
  {
    internal_error (__FILE__, __LINE__,
-@@ -360,14 +368,16 @@ execute_stack_op (gdb_byte *exp, ULONGEST len, int addr_size,
+@@ -352,24 +360,29 @@ execute_stack_op (gdb_byte *exp, ULONGEST len, int addr_size,
+ {
+   struct dwarf_expr_context *ctx;
+   CORE_ADDR result;
++  struct cleanup *old_chain;
+ 
+   ctx = new_dwarf_expr_context ();
++  old_chain = make_cleanup_free_dwarf_expr_context (ctx);
++
+   ctx->gdbarch = get_frame_arch (this_frame);
+   ctx->addr_size = addr_size;
+   ctx->baton = this_frame;
    ctx->read_reg = read_reg;
    ctx->read_mem = read_mem;
    ctx->get_frame_base = no_get_frame_base;
@@ -3287,9 +3298,12 @@ index 0f6da40..c1c162e 100644
      result = read_reg (this_frame, result);
 +  /* FIXME */
  
-   free_dwarf_expr_context (ctx);
+-  free_dwarf_expr_context (ctx);
++  do_cleanups (old_chain);
  
-@@ -1247,6 +1257,14 @@ dwarf2_frame_base_sniffer (struct frame_info *this_frame)
+   return result;
+ }
+@@ -1247,6 +1260,14 @@ dwarf2_frame_base_sniffer (struct frame_info *this_frame)
  
    return NULL;
  }
@@ -3297,14 +3311,14 @@ index 0f6da40..c1c162e 100644
 +CORE_ADDR
 +dwarf2_frame_cfa (struct frame_info *this_frame)
 +{
-+  if (! frame_base_is (this_frame, &dwarf2_frame_base))
++  if (! frame_unwinder_is (this_frame, &dwarf2_frame_unwind))
 +    error (_("can't compute CFA for this frame"));
-+  return get_frame_base_address (this_frame);
++  return get_frame_base (this_frame);
 +}
  \f
  const struct objfile_data *dwarf2_frame_objfile_data;
  
-@@ -1536,6 +1554,14 @@ dwarf2_frame_find_fde (CORE_ADDR *pc)
+@@ -1536,6 +1557,14 @@ dwarf2_frame_find_fde (CORE_ADDR *pc)
        CORE_ADDR offset;
        CORE_ADDR seek_pc;
  
@@ -3333,10 +3347,33 @@ index b203661..dd03d59 100644
 +
  #endif /* dwarf2-frame.h */
 diff --git a/gdb/dwarf2expr.c b/gdb/dwarf2expr.c
-index 8dbf976..aec7b92 100644
+index 8dbf976..228eae7 100644
 --- a/gdb/dwarf2expr.c
 +++ b/gdb/dwarf2expr.c
-@@ -109,8 +109,7 @@ dwarf_expr_fetch (struct dwarf_expr_context *ctx, int n)
+@@ -61,6 +61,22 @@ free_dwarf_expr_context (struct dwarf_expr_context *ctx)
+   xfree (ctx);
+ }
+ 
++/* Helper for make_cleanup_free_dwarf_expr_context.  */
++
++static void
++free_dwarf_expr_context_cleanup (void *arg)
++{
++  free_dwarf_expr_context (arg);
++}
++
++/* Return a cleanup that calls free_dwarf_expr_context.  */
++
++struct cleanup *
++make_cleanup_free_dwarf_expr_context (struct dwarf_expr_context *ctx)
++{
++  return make_cleanup (free_dwarf_expr_context_cleanup, ctx);
++}
++
+ /* Expand the memory allocated to CTX's stack to contain at least
+    NEED more elements than are currently used.  */
+ 
+@@ -109,8 +125,7 @@ dwarf_expr_fetch (struct dwarf_expr_context *ctx, int n)
  
  /* Add a new piece to CTX's piece list.  */
  static void
@@ -3346,7 +3383,7 @@ index 8dbf976..aec7b92 100644
  {
    struct dwarf_expr_piece *p;
  
-@@ -125,9 +124,15 @@ add_piece (struct dwarf_expr_context *ctx,
+@@ -125,9 +140,15 @@ add_piece (struct dwarf_expr_context *ctx,
                             * sizeof (struct dwarf_expr_piece));
  
    p = &ctx->pieces[ctx->num_pieces - 1];
@@ -3364,7 +3401,7 @@ index 8dbf976..aec7b92 100644
  }
  
  /* Evaluate the expression at ADDR (LEN bytes long) using the context
-@@ -271,6 +276,21 @@ signed_address_type (struct gdbarch *gdbarch, int addr_size)
+@@ -271,6 +292,21 @@ signed_address_type (struct gdbarch *gdbarch, int addr_size)
      }
  }
  \f
@@ -3386,7 +3423,7 @@ index 8dbf976..aec7b92 100644
  /* The engine for the expression evaluator.  Using the context in CTX,
     evaluate the expression between OP_PTR and OP_END.  */
  
-@@ -279,8 +299,7 @@ execute_stack_op (struct dwarf_expr_context *ctx,
+@@ -279,8 +315,7 @@ execute_stack_op (struct dwarf_expr_context *ctx,
  		  gdb_byte *op_ptr, gdb_byte *op_end)
  {
    enum bfd_endian byte_order = gdbarch_byte_order (ctx->gdbarch);
@@ -3396,7 +3433,7 @@ index 8dbf976..aec7b92 100644
    ctx->initialized = 1;  /* Default is initialized.  */
  
    if (ctx->recursion_depth > ctx->max_recursion_depth)
-@@ -420,20 +439,36 @@ execute_stack_op (struct dwarf_expr_context *ctx,
+@@ -420,20 +455,36 @@ execute_stack_op (struct dwarf_expr_context *ctx,
  		   "used either alone or in conjuction with DW_OP_piece."));
  
  	  result = op - DW_OP_reg0;
@@ -3439,7 +3476,7 @@ index 8dbf976..aec7b92 100644
  	case DW_OP_breg0:
  	case DW_OP_breg1:
  	case DW_OP_breg2:
-@@ -498,11 +533,12 @@ execute_stack_op (struct dwarf_expr_context *ctx,
+@@ -498,11 +549,12 @@ execute_stack_op (struct dwarf_expr_context *ctx,
  	    (ctx->get_frame_base) (ctx->baton, &datastart, &datalen);
  	    dwarf_expr_eval (ctx, datastart, datalen);
  	    result = dwarf_expr_fetch (ctx, 0);
@@ -3454,7 +3491,7 @@ index 8dbf976..aec7b92 100644
  	  }
  	  break;
  	case DW_OP_dup:
-@@ -700,6 +736,10 @@ execute_stack_op (struct dwarf_expr_context *ctx,
+@@ -700,6 +752,10 @@ execute_stack_op (struct dwarf_expr_context *ctx,
  	  }
  	  break;
  
@@ -3465,7 +3502,7 @@ index 8dbf976..aec7b92 100644
  	case DW_OP_GNU_push_tls_address:
  	  /* Variable is at a constant offset in the thread-local
  	  storage block into the objfile for the current thread and
-@@ -738,12 +778,13 @@ execute_stack_op (struct dwarf_expr_context *ctx,
+@@ -738,12 +794,13 @@ execute_stack_op (struct dwarf_expr_context *ctx,
  
              /* Record the piece.  */
              op_ptr = read_uleb128 (op_ptr, op_end, &size);
@@ -3484,7 +3521,7 @@ index 8dbf976..aec7b92 100644
            }
            goto no_push;
  
-@@ -755,6 +796,13 @@ execute_stack_op (struct dwarf_expr_context *ctx,
+@@ -755,6 +812,13 @@ execute_stack_op (struct dwarf_expr_context *ctx,
  	  ctx->initialized = 0;
  	  goto no_push;
  
@@ -3499,7 +3536,7 @@ index 8dbf976..aec7b92 100644
  	  error (_("Unhandled dwarf expression opcode 0x%x"), op);
  	}
 diff --git a/gdb/dwarf2expr.h b/gdb/dwarf2expr.h
-index 7047922..232208d 100644
+index 7047922..597c2de 100644
 --- a/gdb/dwarf2expr.h
 +++ b/gdb/dwarf2expr.h
 @@ -23,6 +23,19 @@
@@ -3621,8 +3658,17 @@ index 7047922..232208d 100644
  
    /* The length of the piece, in bytes.  */
    ULONGEST size;
+@@ -131,6 +159,8 @@ struct dwarf_expr_piece
+ 
+ struct dwarf_expr_context *new_dwarf_expr_context (void);
+ void free_dwarf_expr_context (struct dwarf_expr_context *ctx);
++struct cleanup *
++    make_cleanup_free_dwarf_expr_context (struct dwarf_expr_context *ctx);
+ 
+ void dwarf_expr_push (struct dwarf_expr_context *ctx, CORE_ADDR value);
+ void dwarf_expr_pop (struct dwarf_expr_context *ctx);
 diff --git a/gdb/dwarf2loc.c b/gdb/dwarf2loc.c
-index 071b5ac..07bb8ba 100644
+index 071b5ac..7b2e488 100644
 --- a/gdb/dwarf2loc.c
 +++ b/gdb/dwarf2loc.c
 @@ -36,6 +36,7 @@
@@ -4004,7 +4050,20 @@ index 071b5ac..07bb8ba 100644
  /* Thread-local accesses do require a frame.  */
  static CORE_ADDR
  needs_frame_tls_address (void *baton, CORE_ADDR offset)
-@@ -356,11 +567,12 @@ dwarf2_loc_desc_needs_frame (gdb_byte *data, unsigned short size,
+@@ -346,21 +557,25 @@ dwarf2_loc_desc_needs_frame (gdb_byte *data, unsigned short size,
+   struct needs_frame_baton baton;
+   struct dwarf_expr_context *ctx;
+   int in_reg;
++  struct cleanup *old_chain;
+ 
+   baton.needs_frame = 0;
+ 
+   ctx = new_dwarf_expr_context ();
++  old_chain = make_cleanup_free_dwarf_expr_context (ctx);
++
+   ctx->gdbarch = get_objfile_arch (dwarf2_per_cu_objfile (per_cu));
+   ctx->addr_size = dwarf2_per_cu_addr_size (per_cu);
+   ctx->baton = &baton;
    ctx->read_reg = needs_frame_read_reg;
    ctx->read_mem = needs_frame_read_mem;
    ctx->get_frame_base = needs_frame_frame_base;
@@ -4018,7 +4077,7 @@ index 071b5ac..07bb8ba 100644
  
    if (ctx->num_pieces > 0)
      {
-@@ -369,7 +581,7 @@ dwarf2_loc_desc_needs_frame (gdb_byte *data, unsigned short size,
+@@ -369,11 +584,11 @@ dwarf2_loc_desc_needs_frame (gdb_byte *data, unsigned short size,
        /* If the location has several pieces, and any of them are in
           registers, then we will need a frame to fetch them from.  */
        for (i = 0; i < ctx->num_pieces; i++)
@@ -4027,7 +4086,12 @@ index 071b5ac..07bb8ba 100644
            in_reg = 1;
      }
  
-@@ -601,7 +813,7 @@ static int
+-  free_dwarf_expr_context (ctx);
++  do_cleanups (old_chain);
+ 
+   return baton.needs_frame || in_reg;
+ }
+@@ -601,7 +816,7 @@ static int
  loclist_describe_location (struct symbol *symbol, struct ui_file *stream)
  {
    /* FIXME: Could print the entire list of locations.  */
@@ -4036,7 +4100,7 @@ index 071b5ac..07bb8ba 100644
    return 1;
  }
  
-@@ -617,16 +829,56 @@ loclist_tracepoint_var_ref (struct symbol *symbol, struct gdbarch *gdbarch,
+@@ -617,16 +832,56 @@ loclist_tracepoint_var_ref (struct symbol *symbol, struct gdbarch *gdbarch,
  
    data = find_location_expression (dlbaton, &size, ax->scope);
    if (data == NULL)
@@ -8250,7 +8314,7 @@ index 8c027c9..d201f76 100644
    else
      {
 diff --git a/gdb/frame.c b/gdb/frame.c
-index 67e0607..1eb7f9d 100644
+index 67e0607..49c3013 100644
 --- a/gdb/frame.c
 +++ b/gdb/frame.c
 @@ -1109,6 +1109,14 @@ has_stack_frames (void)
@@ -8268,7 +8332,7 @@ index 67e0607..1eb7f9d 100644
    /* Don't try to read from a dead thread.  */
    if (is_exited (inferior_ptid))
      return 0;
-@@ -1843,6 +1851,17 @@ get_frame_args_address (struct frame_info *fi)
+@@ -1843,6 +1851,15 @@ get_frame_args_address (struct frame_info *fi)
    return fi->base->this_args (fi, &fi->base_cache);
  }
  
@@ -8276,28 +8340,27 @@ index 67e0607..1eb7f9d 100644
 +   otherwise.  */
 +
 +int
-+frame_base_is (struct frame_info *fi, const struct frame_base *base)
++frame_unwinder_is (struct frame_info *fi, const struct frame_unwind *unwinder)
 +{
-+  if (fi->base == NULL)
-+    fi->base = frame_base_find_by_frame (fi);
-+  return fi->base == base;
++  return fi->unwind == unwinder;
 +}
 +
  /* Level of the selected frame: 0 for innermost, 1 for its caller, ...
     or -1 for a NULL frame.  */
  
 diff --git a/gdb/frame.h b/gdb/frame.h
-index febef5c..09bf628 100644
+index febef5c..611c6d3 100644
 --- a/gdb/frame.h
 +++ b/gdb/frame.h
-@@ -696,4 +696,9 @@ extern struct frame_info *deprecated_safe_get_selected_frame (void);
+@@ -696,4 +696,10 @@ extern struct frame_info *deprecated_safe_get_selected_frame (void);
  
  extern struct frame_info *create_new_frame (CORE_ADDR base, CORE_ADDR pc);
  
-+/* Return true if the frame base for frame FI is BASE; false
++/* Return true if the frame unwinder for frame FI is UNWINDER; false
 +   otherwise.  */
 +
-+extern int frame_base_is (struct frame_info *fi, const struct frame_base *base);
++extern int frame_unwinder_is (struct frame_info *fi,
++			      const struct frame_unwind *unwinder);
 +
  #endif /* !defined (FRAME_H)  */
 diff --git a/gdb/gdbinit.in b/gdb/gdbinit.in
@@ -21677,6 +21740,382 @@ index 0000000..6922eed
 +if [test_compiler_info gcc-4-3-*] then { setup_xfail *-*-* }
 +
 +gdb_test "print x" "= 11" "Print imported namespace x"
+diff --git a/gdb/testsuite/gdb.dwarf2/callframecfa.S b/gdb/testsuite/gdb.dwarf2/callframecfa.S
+new file mode 100644
+index 0000000..6d0421a
+--- /dev/null
++++ b/gdb/testsuite/gdb.dwarf2/callframecfa.S
+@@ -0,0 +1,309 @@
++/*
++   Copyright 2009 Free Software Foundation, Inc.
++
++   This program is free software; you can redistribute it and/or modify
++   it under the terms of the GNU General Public License as published by
++   the Free Software Foundation; either version 3 of the License, or
++   (at your option) any later version.
++
++   This program is distributed in the hope that it will be useful,
++   but WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
++   GNU General Public License for more details.
++
++   You should have received a copy of the GNU General Public License
++   along with this program.  If not, see <http://www.gnu.org/licenses/>.
++ */
++
++/* This was compiled from a trivial program just to test the
++   DW_OP_call_frame_cfa operator:
++
++    int func (int arg) {
++      return arg + 23;
++    }
++
++    int main(int argc, char *argv[]) {
++      func (77);
++    }
++*/
++
++	.file	"q.c"
++	.section	.debug_abbrev,"",@progbits
++.Ldebug_abbrev0:
++	.section	.debug_info,"",@progbits
++.Ldebug_info0:
++	.section	.debug_line,"",@progbits
++.Ldebug_line0:
++	.text
++.Ltext0:
++.globl func
++	.type	func, @function
++func:
++.LFB0:
++	.file 1 "q.c"
++	.loc 1 2 0
++	.cfi_startproc
++	pushl	%ebp
++	.cfi_def_cfa_offset 8
++	movl	%esp, %ebp
++	.cfi_offset 5, -8
++	.cfi_def_cfa_register 5
++	.loc 1 3 0
++	movl	8(%ebp), %eax
++	addl	$23, %eax
++	.loc 1 4 0
++	popl	%ebp
++	.cfi_restore 5
++	.cfi_def_cfa 4, 4
++	ret
++	.cfi_endproc
++.LFE0:
++	.size	func, .-func
++.globl _start
++	.type	_start, @function
++_start:
++.LFB1:
++	.loc 1 6 0
++	.cfi_startproc
++	pushl	%ebp
++	.cfi_def_cfa_offset 8
++	movl	%esp, %ebp
++	.cfi_offset 5, -8
++	.cfi_def_cfa_register 5
++	subl	$4, %esp
++	.loc 1 7 0
++	movl	$77, (%esp)
++	call	func
++	.loc 1 8 0
++	leave
++	.cfi_restore 5
++	.cfi_def_cfa 4, 4
++	ret
++	.cfi_endproc
++.LFE1:
++	.size	_start, .-_start
++.Letext0:
++	.section	.debug_info
++	.long	0x9e
++	.value	0x3
++	.long	.Ldebug_abbrev0
++	.byte	0x4
++	.uleb128 0x1
++	.long	.LASF5
++	.byte	0x1
++	.string	"q.c"
++	.long	.LASF6
++	.long	.Ltext0
++	.long	.Letext0
++	.long	.Ldebug_line0
++	.uleb128 0x2
++	.byte	0x1
++	.long	.LASF0
++	.byte	0x1
++	.byte	0x1
++	.byte	0x1
++	.long	0x4f
++	.long	.LFB0
++	.long	.LFE0
++	.byte	0x1
++	.byte	0x9c
++	.long	0x4f
++	.uleb128 0x3
++	.string	"arg"
++	.byte	0x1
++	.byte	0x1
++	.long	0x4f
++	.byte	0x2
++	.byte	0x91
++	.sleb128 0
++	.byte	0x0
++	.uleb128 0x4
++	.byte	0x4
++	.byte	0x5
++	.string	"int"
++	.uleb128 0x2
++	.byte	0x1
++	.long	.LASF1
++	.byte	0x1
++	.byte	0x6
++	.byte	0x1
++	.long	0x4f
++	.long	.LFB1
++	.long	.LFE1
++	.byte	0x1
++	.byte	0x9c
++	.long	0x8e
++	.uleb128 0x5
++	.long	.LASF2
++	.byte	0x1
++	.byte	0x6
++	.long	0x4f
++	.byte	0x2
++	.byte	0x91
++	.sleb128 0
++	.uleb128 0x5
++	.long	.LASF3
++	.byte	0x1
++	.byte	0x6
++	.long	0x8e
++	.byte	0x2
++	.byte	0x91
++	.sleb128 4
++	.byte	0x0
++	.uleb128 0x6
++	.byte	0x4
++	.long	0x94
++	.uleb128 0x6
++	.byte	0x4
++	.long	0x9a
++	.uleb128 0x7
++	.byte	0x1
++	.byte	0x6
++	.long	.LASF4
++	.byte	0x0
++	.section	.debug_abbrev
++	.uleb128 0x1
++	.uleb128 0x11
++	.byte	0x1
++	.uleb128 0x25
++	.uleb128 0xe
++	.uleb128 0x13
++	.uleb128 0xb
++	.uleb128 0x3
++	.uleb128 0x8
++	.uleb128 0x1b
++	.uleb128 0xe
++	.uleb128 0x11
++	.uleb128 0x1
++	.uleb128 0x12
++	.uleb128 0x1
++	.uleb128 0x10
++	.uleb128 0x6
++	.byte	0x0
++	.byte	0x0
++	.uleb128 0x2
++	.uleb128 0x2e
++	.byte	0x1
++	.uleb128 0x3f
++	.uleb128 0xc
++	.uleb128 0x3
++	.uleb128 0xe
++	.uleb128 0x3a
++	.uleb128 0xb
++	.uleb128 0x3b
++	.uleb128 0xb
++	.uleb128 0x27
++	.uleb128 0xc
++	.uleb128 0x49
++	.uleb128 0x13
++	.uleb128 0x11
++	.uleb128 0x1
++	.uleb128 0x12
++	.uleb128 0x1
++	.uleb128 0x40
++	.uleb128 0xa
++	.uleb128 0x1
++	.uleb128 0x13
++	.byte	0x0
++	.byte	0x0
++	.uleb128 0x3
++	.uleb128 0x5
++	.byte	0x0
++	.uleb128 0x3
++	.uleb128 0x8
++	.uleb128 0x3a
++	.uleb128 0xb
++	.uleb128 0x3b
++	.uleb128 0xb
++	.uleb128 0x49
++	.uleb128 0x13
++	.uleb128 0x2
++	.uleb128 0xa
++	.byte	0x0
++	.byte	0x0
++	.uleb128 0x4
++	.uleb128 0x24
++	.byte	0x0
++	.uleb128 0xb
++	.uleb128 0xb
++	.uleb128 0x3e
++	.uleb128 0xb
++	.uleb128 0x3
++	.uleb128 0x8
++	.byte	0x0
++	.byte	0x0
++	.uleb128 0x5
++	.uleb128 0x5
++	.byte	0x0
++	.uleb128 0x3
++	.uleb128 0xe
++	.uleb128 0x3a
++	.uleb128 0xb
++	.uleb128 0x3b
++	.uleb128 0xb
++	.uleb128 0x49
++	.uleb128 0x13
++	.uleb128 0x2
++	.uleb128 0xa
++	.byte	0x0
++	.byte	0x0
++	.uleb128 0x6
++	.uleb128 0xf
++	.byte	0x0
++	.uleb128 0xb
++	.uleb128 0xb
++	.uleb128 0x49
++	.uleb128 0x13
++	.byte	0x0
++	.byte	0x0
++	.uleb128 0x7
++	.uleb128 0x24
++	.byte	0x0
++	.uleb128 0xb
++	.uleb128 0xb
++	.uleb128 0x3e
++	.uleb128 0xb
++	.uleb128 0x3
++	.uleb128 0xe
++	.byte	0x0
++	.byte	0x0
++	.byte	0x0
++	.section	.debug_pubnames,"",@progbits
++	.long	0x20
++	.value	0x2
++	.long	.Ldebug_info0
++	.long	0xa2
++	.long	0x25
++	.string	"func"
++	.long	0x56
++	.string	"main"
++	.long	0x0
++	.section	.debug_aranges,"",@progbits
++	.long	0x1c
++	.value	0x2
++	.long	.Ldebug_info0
++	.byte	0x4
++	.byte	0x0
++	.value	0x0
++	.value	0x0
++	.long	.Ltext0
++	.long	.Letext0-.Ltext0
++	.long	0x0
++	.long	0x0
++	.section	.debug_str,"MS",@progbits,1
++.LASF5:
++	.string	"GNU C 4.5.0 20090810 (experimental) [trunk revision 150633]"
++.LASF2:
++	.string	"argc"
++.LASF6:
++	.string	"/tmp"
++.LASF0:
++	.string	"func"
++.LASF3:
++	.string	"argv"
++.LASF1:
++	.string	"main"
++.LASF4:
++	.string	"char"
++	.ident	"GCC: (GNU) 4.5.0 20090810 (experimental) [trunk revision 150633]"
++	.section	.note.GNU-stack,"",@progbits
+diff --git a/gdb/testsuite/gdb.dwarf2/callframecfa.exp b/gdb/testsuite/gdb.dwarf2/callframecfa.exp
+new file mode 100644
+index 0000000..00d67fc
+--- /dev/null
++++ b/gdb/testsuite/gdb.dwarf2/callframecfa.exp
+@@ -0,0 +1,55 @@
++# Copyright 2009 Free Software Foundation, Inc.
++
++# This program is free software; you can redistribute it and/or modify
++# it under the terms of the GNU General Public License as published by
++# the Free Software Foundation; either version 3 of the License, or
++# (at your option) any later version.
++#
++# This program is distributed in the hope that it will be useful,
++# but WITHOUT ANY WARRANTY; without even the implied warranty of
++# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
++# GNU General Public License for more details.
++#
++# You should have received a copy of the GNU General Public License
++# along with this program.  If not, see <http://www.gnu.org/licenses/>.
++
++# Test DW_OP_call_frame_cfa.
++
++# This test can only be run on targets which support DWARF-2 and use gas.
++# For now pick a sampling of likely targets.
++if {![istarget *-*-linux*]
++    && ![istarget *-*-gnu*]
++    && ![istarget *-*-elf*]
++    && ![istarget *-*-openbsd*]
++    && ![istarget arm-*-eabi*]
++    && ![istarget powerpc-*-eabi*]} {
++    return 0  
++}
++# This test can only be run on x86 targets.
++if {![istarget i?86-*]} {
++    return 0  
++}
++
++set testfile "callframecfa"
++set srcfile ${testfile}.S
++set binfile ${objdir}/${subdir}/${testfile}.x
++
++if  { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable \
++       [list {additional_flags=-nostdlib}]] != "" } {
++    return -1
++}
++
++gdb_exit
++gdb_start
++gdb_reinitialize_dir $srcdir/$subdir
++gdb_load ${binfile}
++
++gdb_test "break *func" "Breakpoint 1.*" "set breakpoint for call-frame-cfa"
++gdb_test "run" "" "run for call-frame-cfa"
++gdb_test "display arg" "arg = 77" "set display for call-frame-cfa"
++
++# We know how many instructions are in the function.  Note that we
++# can't handle the "ret" instruction due to the epilogue unwinder.
++for {set i 1} {$i < 5} {incr i} {
++    gdb_test "si" "arg = 77" "step $i for call-frame-cfa"
++}
 diff --git a/gdb/testsuite/gdb.dwarf2/dw2-stripped.c b/gdb/testsuite/gdb.dwarf2/dw2-stripped.c
 new file mode 100644
 index 0000000..1f02d90

diff --git a/gdb.spec b/gdb.spec
index c1171f2..da9abc2 100644
--- a/gdb.spec
+++ b/gdb.spec
@@ -14,7 +14,7 @@ Version: 6.8.50.20090811
 
 # The release always contains a leading reserved number, start it at 1.
 # `upstream' is not a part of `name' to stay fully rpm dependencies compatible for the testing.
-Release: 1%{?_with_upstream:.upstream}%{?dist}
+Release: 2%{?_with_upstream:.upstream}%{?dist}
 
 License: GPLv3+
 Group: Development/Debuggers
@@ -825,6 +825,10 @@ fi
 %endif
 
 %changelog
+* Tue Aug 11 2009 Jan Kratochvil <jan.kratochvil@redhat.com> - 6.8.50.20090811-2
+- archer-jankratochvil-fedora12 commit: 93f5e942bdcdcc376ece452c309bedabae71def9
+- Fix "can't compute CFA for this frame" (by Tom Tromey, BZ 516627).
+
 * Tue Aug 11 2009 Jan Kratochvil <jan.kratochvil@redhat.com> - 6.8.50.20090811-1
 - Support constant DW_AT_data_member_location by GCC PR debug/40659 (BZ 515377).
 - Fix .spec URL.

             reply	other threads:[~2026-06-27 23:54 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-27 23:54 Jan Kratochvil [this message]
  -- strict thread matches above, loose matches on Subject: below --
2026-06-27 23:54 [rpms/gdb] gdb-17.2-rebase-f44: - archer-jankratochvil-fedora12 commit: Jan Kratochvil
2026-06-27 23:54 Jan Kratochvil
2026-06-27 23:54 Jan Kratochvil
2026-06-27 23:54 Jan Kratochvil

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=178260445922.1.3886248785650818354.rpms-gdb-99fa6c959f83@fedoraproject.org \
    --to=jkratoch@fedoraproject.org \
    --cc=git-commits@fedoraproject.org \
    /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