From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16275 invoked by alias); 29 Sep 2009 03:45:18 -0000 Received: (qmail 16264 invoked by uid 22791); 29 Sep 2009 03:45:17 -0000 X-SWARE-Spam-Status: No, hits=-2.5 required=5.0 tests=AWL,BAYES_00,SPF_PASS X-Spam-Check-By: sourceware.org Received: from mail-ew0-f216.google.com (HELO mail-ew0-f216.google.com) (209.85.219.216) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 29 Sep 2009 03:45:10 +0000 Received: by ewy12 with SMTP id 12so4980705ewy.0 for ; Mon, 28 Sep 2009 20:45:07 -0700 (PDT) Received: by 10.211.159.13 with SMTP id l13mr4450157ebo.82.1254195907819; Mon, 28 Sep 2009 20:45:07 -0700 (PDT) Received: from ?192.168.2.99? (cpc2-cmbg8-0-0-cust61.cmbg.cable.ntl.com [82.6.108.62]) by mx.google.com with ESMTPS id 7sm1096918eyg.1.2009.09.28.20.45.06 (version=SSLv3 cipher=RC4-MD5); Mon, 28 Sep 2009 20:45:07 -0700 (PDT) Message-ID: <4AC18628.9060202@gmail.com> Date: Tue, 29 Sep 2009 03:45:00 -0000 From: Dave Korn User-Agent: Thunderbird 2.0.0.17 (Windows/20080914) MIME-Version: 1.0 To: cgen@sourceware.org Subject: [patch] One more cpu-vs-prefix fix. Content-Type: multipart/mixed; boundary="------------010207070305080403000300" Mailing-List: contact cgen-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cgen-owner@sourceware.org X-SW-Source: 2009-q3/txt/msg00107.txt.bz2 This is a multi-part message in MIME format. --------------010207070305080403000300 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-length: 1205 Hiya! I found one more place that looks to me like it should be using @prefix@ instead of @cpu@, since that's how all the rest of the code generates the "XXX_init_idesc_table" name. I haven't tested this much yet except that it fixes a discrepancy between the prototype generated in the decode.h and the function call in the mloop.c files for the private port I'm working on. I think that sh64 is the only target where there actually is any difference between @prefix@ and @cpu@ in practice, so I tried regenerating it and it seemed to compile ok, or at any rate without any missing or duplicated symbols. I couldn't get the tests to run, they all fail with an error that suggests the testsuite is attempting to run target binaries on the host machine: > spawn /sgun/tools/obj.sh64/ld/ld-new andb.cgs.o -m shelf32 -o andb.cgs.x > andb.cgs.x > spawn andb.cgs.x > andb.cgs.x: andb.cgs.x: cannot execute binary file > FAIL: sh5 andb.cgs (execution) > Testing andi.cgs on machine sh5. So whatever that is, I'd guess it's not related. Here's a changelog entry, if you want the patch: cgen/ChangeLog: * sim-model.scm (@cpu@_prepare_run): Use @prefix@, not @cpu@. cheers, DaveK --------------010207070305080403000300 Content-Type: text/x-c; name="init-idesc-table-prefix.diff" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="init-idesc-table-prefix.diff" Content-length: 375 Index: cgen/sim-model.scm =================================================================== --- cgen/sim-model.scm (revision 171) +++ cgen/sim-model.scm (working copy) @@ -305,7 +305,7 @@ static void @cpu@_prepare_run (SIM_CPU *cpu) { if (CPU_IDESC (cpu) == NULL) - @cpu@_init_idesc_table (cpu); + @prefix@_init_idesc_table (cpu); } static const CGEN_INSN * --------------010207070305080403000300--