Date: Sun, 4 Jul 2004 21:19:02 GMT From: Marcel Moolenaar <marcel@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 56463 for review Message-ID: <200407042119.i64LJ22c059320@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=56463 Change 56463 by marcel@marcel_nfs on 2004/07/04 21:18:24 o Remove some left-over cruft from ia64. o Add minimal support for sparc64. Affected files ... .. //depot/projects/gdb/sys/ia64/ia64/gdb_machdep.c#9 edit .. //depot/projects/gdb/sys/sparc64/sparc64/gdb_machdep.c#5 edit Differences ... ==== //depot/projects/gdb/sys/ia64/ia64/gdb_machdep.c#9 (text+ko) ==== @@ -102,10 +102,6 @@ case 370: return (&kdb_thrctx->pcb_special.unat); case 374: return (&kdb_thrctx->pcb_special.fpsr); case 399: return (&kdb_thrctx->pcb_preserved.lc); - /* Synthesized registers. */ - return (&synth); - synth = kdb_thrctx->pcb_special.bspstore; - return (&synth); } return (NULL); } ==== //depot/projects/gdb/sys/sparc64/sparc64/gdb_machdep.c#5 (text+ko) ==== @@ -33,8 +33,9 @@ #include <sys/kernel.h> #include <sys/signal.h> -#include <machine/frame.h> +#include <machine/asm.h> #include <machine/gdb_machdep.h> +#include <machine/pcb.h> #include <machine/reg.h> #include <gdb/gdb.h> @@ -42,36 +43,21 @@ void * gdb_cpu_getreg(int regnum, size_t *regsz) { - struct trapframe *tf = kdb_frame; + static uint64_t synth; *regsz = gdb_cpu_regsz(regnum); switch (regnum) { - case 0: return (&tf->tf_global[0]); - case 1: return (&tf->tf_global[1]); - case 2: return (&tf->tf_global[2]); - case 3: return (&tf->tf_global[3]); - case 4: return (&tf->tf_global[4]); - case 5: return (&tf->tf_global[5]); - case 6: return (&tf->tf_global[6]); - case 7: return (&tf->tf_global[7]); + /* 0-7: g0-g7 */ /* 8-15: o0-o7 */ + case 14: + synth = kdb_thrctx->pcb_sp - CCFSZ; + return (&synth); /* 16-23: l0-l7 */ - case 24: return (&tf->tf_out[0]); - case 25: return (&tf->tf_out[1]); - case 26: return (&tf->tf_out[2]); - case 27: return (&tf->tf_out[3]); - case 28: return (&tf->tf_out[4]); - case 29: return (&tf->tf_out[5]); - case 30: return (&tf->tf_out[6]); - case 31: return (&tf->tf_out[7]); + /* 24-31: i0-i7 */ + case 30: return (&kdb_thrctx->pcb_sp); + case 31: return (&kdb_thrctx->pcb_pc); /* 32-63: f0-f31 */ /* 64-79: f32-f62 (16 double FP) */ - case 80: return (&tf->tf_tpc); - case 81: return (&tf->tf_tnpc); - case 82: return (&tf->tf_tstate); - case 83: return (&tf->tf_fsr); - case 84: return (&tf->tf_fprs); - case 85: return (&tf->tf_y); } return (NULL); }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200407042119.i64LJ22c059320>