From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29540 invoked by alias); 15 Jan 2003 04:28:04 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 29533 invoked from network); 15 Jan 2003 04:28:04 -0000 Received: from unknown (HELO crack.them.org) (65.125.64.184) by 209.249.29.67 with SMTP; 15 Jan 2003 04:28:04 -0000 Received: from nevyn.them.org ([66.93.61.169] ident=mail) by crack.them.org with asmtp (Exim 3.12 #1 (Debian)) id 18Yh2J-0001wh-00; Wed, 15 Jan 2003 00:28:27 -0600 Received: from drow by nevyn.them.org with local (Exim 3.36 #1 (Debian)) id 18YfA2-0005bZ-00; Tue, 14 Jan 2003 23:28:18 -0500 Date: Wed, 15 Jan 2003 04:28:00 -0000 From: Daniel Jacobowitz To: Alan Modra Cc: gdb@sources.redhat.com Subject: z8k simulator broken Message-ID: <20030115042818.GA17532@nevyn.them.org> Mail-Followup-To: Alan Modra , gdb@sources.redhat.com Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.1i X-SW-Source: 2003-01/txt/msg00254.txt.bz2 Did you ever get a chance to look at the z8k sim problem? It seems that the problem is that it uses the idx to generate the names of functions, but your changes to "Generate idx as gas needs it" broke that. Here's what I'm using; it builds, but I haven't really tested the simulator yet. Someone tell me again why I'm doing this? -- Daniel Jacobowitz MontaVista Software Debian GNU/Linux Developer Index: writecode.c =================================================================== RCS file: /cvs/src/src/sim/z8k/writecode.c,v retrieving revision 1.3 diff -u -p -r1.3 writecode.c --- writecode.c 6 Jun 2002 15:50:50 -0000 1.3 +++ writecode.c 15 Jan 2003 04:27:10 -0000 @@ -187,7 +187,7 @@ lookup_inst (what) } if (nibl_matched) { - z8k_inv_list[what] = ptr->idx; + z8k_inv_list[what] = ptr - z8k_table; break; /* while */ } ptr++; @@ -1550,7 +1550,7 @@ mangle (p, shortcut, value) } else { - emit ("int _%d(context,pc,iwords0)\n", p->idx); + emit ("int _%d(context,pc,iwords0)\n", p - z8k_table); emit ("int iwords0;\n"); } emit ("sim_state_type *context;\n"); @@ -1668,7 +1668,7 @@ build_list (i) if (!p) return; - add_to_list (&list[p->idx], i); + add_to_list (&list[p - z8k_table], i); } int @@ -1807,7 +1807,7 @@ main (ac, av) #endif if (p != NULL) { - printf ("%d", p->idx); + printf ("%d", p - z8k_table); } else printf ("400");