• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
Aucun tag

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

GNU Binutils with patches for OS216


Commit MetaInfo

Révision8d357ccaa7453f32482275a89577fe5d4445f383 (tree)
l'heure2003-01-09 07:47:46
AuteurAndrew Cagney <cagney@redh...>
CommiterAndrew Cagney

Message de Log

2003-01-08 Andrew Cagney <cagney@redhat.com>

* gcore.c, i386-linux-tdep.c: Use get_frame_pc, get_next_frame and
get_frame_base.

Change Summary

Modification

--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,8 @@
1+2003-01-08 Andrew Cagney <cagney@redhat.com>
2+
3+ * gcore.c, i386-linux-tdep.c: Use get_frame_pc, get_next_frame and
4+ get_frame_base.
5+
16 2003-01-08 David Carlton <carlton@math.stanford.edu>
27
38 * linespec.c (decode_line_1): Move code into decode_variable.
--- a/gdb/gcore.c
+++ b/gdb/gcore.c
@@ -179,7 +179,7 @@ derive_stack_segment (bfd_vma *bottom, bfd_vma *top)
179179 return 0; /* Can't succeed without current frame. */
180180
181181 /* Save frame pointer of TOS frame. */
182- *top = fi->frame;
182+ *top = get_frame_base (fi);
183183 /* If current stack pointer is more "inner", use that instead. */
184184 if (INNER_THAN (read_sp (), *top))
185185 *top = read_sp ();
@@ -189,7 +189,7 @@ derive_stack_segment (bfd_vma *bottom, bfd_vma *top)
189189 fi = tmp_fi;
190190
191191 /* Save frame pointer of prev-most frame. */
192- *bottom = fi->frame;
192+ *bottom = get_frame_base (fi);
193193
194194 /* Now canonicalize their order, so that 'bottom' is a lower address
195195 (as opposed to a lower stack frame). */
--- a/gdb/i386-linux-tdep.c
+++ b/gdb/i386-linux-tdep.c
@@ -247,16 +247,16 @@ i386_linux_sigcontext_addr (struct frame_info *frame)
247247 {
248248 CORE_ADDR pc;
249249
250- pc = i386_linux_sigtramp_start (frame->pc);
250+ pc = i386_linux_sigtramp_start (get_frame_pc (frame));
251251 if (pc)
252252 {
253253 CORE_ADDR sp;
254254
255- if (frame->next)
255+ if (get_next_frame (frame))
256256 /* If this isn't the top frame, the next frame must be for the
257257 signal handler itself. The sigcontext structure lives on
258258 the stack, right after the signum argument. */
259- return frame->next->frame + 12;
259+ return get_frame_base (get_next_frame (frame)) + 12;
260260
261261 /* This is the top frame. We'll have to find the address of the
262262 sigcontext structure by looking at the stack pointer. Keep
@@ -264,20 +264,21 @@ i386_linux_sigcontext_addr (struct frame_info *frame)
264264 "pop %eax". If the PC is at this instruction, adjust the
265265 returned value accordingly. */
266266 sp = read_register (SP_REGNUM);
267- if (pc == frame->pc)
267+ if (pc == get_frame_pc (frame))
268268 return sp + 4;
269269 return sp;
270270 }
271271
272- pc = i386_linux_rt_sigtramp_start (frame->pc);
272+ pc = i386_linux_rt_sigtramp_start (get_frame_pc (frame));
273273 if (pc)
274274 {
275- if (frame->next)
275+ if (get_next_frame (frame))
276276 /* If this isn't the top frame, the next frame must be for the
277277 signal handler itself. The sigcontext structure is part of
278278 the user context. A pointer to the user context is passed
279279 as the third argument to the signal handler. */
280- return read_memory_integer (frame->next->frame + 16, 4) + 20;
280+ return read_memory_integer (get_frame_base (get_next_frame (frame))
281+ + 16, 4) + 20;
281282
282283 /* This is the top frame. Again, use the stack pointer to find
283284 the address of the sigcontext structure. */