This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Support assembler modules with line info only


The attached patch allows gdb to debug assembler modules that have only
line number information, and nothing else (including function names).


Changerlog entry:
2005-07-14  Vladimur Prus <ghost@cs.msu.su>

     gdb/infrun.c (handle_inferior_event): When deciding if we've entered
	    undebuggable function, check for ecs->sal.line != 0, not for
        ecs->stop_func_name != NULL.


Thanks,
Volodya
Index: gdb/infrun.c
===================================================================
--- gdb/infrun.c	(revision 1678)
+++ gdb/infrun.c	(revision 1679)
@@ -2420,11 +2420,12 @@
 	}
     }
 
+  ecs->sal = find_pc_line (stop_pc, 0);
   /* NOTE: tausq/2004-05-24: This if block used to be done before all
      the trampoline processing logic, however, there are some trampolines 
      that have no names, so we should do trampoline handling first.  */
   if (step_over_calls == STEP_OVER_UNDEBUGGABLE
-      && ecs->stop_func_name == NULL)
+      && ecs->sal.line == 0)
     {
       /* The inferior just stepped into, or returned to, an
          undebuggable function (where there is no symbol, not even a
@@ -2461,9 +2462,7 @@
       stop_stepping (ecs);
       return;
     }
-
-  ecs->sal = find_pc_line (stop_pc, 0);
-
+      
   if (ecs->sal.line == 0)
     {
       /* We have no line number information.  That means to stop

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]