+2021-04-06 Tom de Vries <tdevries@suse.de>
+
+ PR breakpoints/25884
+ * infcmd.c (prepare_one_step): Using inline frame info to narrow
+ stepping range.
+
2021-04-06 Tom de Vries <tdevries@suse.de>
PR tui/27680
&tp->control.step_range_start,
&tp->control.step_range_end);
+ /* There's a problem in gcc (PR gcc/98780) that causes missing line
+ table entries, which results in a too large stepping range.
+ Use inlined_subroutine info to make the range more narrow. */
+ if (inline_skipped_frames (tp) > 0)
+ {
+ symbol *sym = inline_skipped_symbol (tp);
+ if (SYMBOL_CLASS (sym) == LOC_BLOCK)
+ {
+ const block *block = SYMBOL_BLOCK_VALUE (sym);
+ if (BLOCK_END (block) < tp->control.step_range_end)
+ tp->control.step_range_end = BLOCK_END (block);
+ }
+ }
+
tp->control.may_range_step = 1;
/* If we have no line info, switch to stepi mode. */
+2021-04-06 Tom de Vries <tdevries@suse.de>
+
+ PR breakpoints/25884
+ * gdb.opt/inline-cmds.exp: Remove kfail.
+
2021-04-06 Tom de Vries <tdevries@suse.de>
PR testsuite/27691
gdb_continue_to_breakpoint "consecutive func1"
gdb_test "next" ".*func1 .*first call.*" "next to first func1"
-set msg "next to second func1"
-gdb_test_multiple "next" $msg {
- -re ".*func1 .*second call.*$gdb_prompt $" {
- pass $msg
- }
- -re ".*marker .*$gdb_prompt $" {
- # This assembles to two consecutive call instructions.
- # Both appear to be at the same line, because they're
- # in the body of the same inlined function. This is
- # reasonable for the line table. GDB should take the
- # containing block and/or function into account when
- # deciding how far to step. The single line table entry
- # is actually two consecutive instances of the same line.
- kfail gdb/25884 $msg
- }
-}
+gdb_test "next" ".*func1 .*second call.*" "next to second func1"
# It is easier when the two inlined functions are not on the same line.
set line4 [gdb_get_line_number "set breakpoint 4 here"]