From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12079 invoked by alias); 28 Nov 2007 08:21:31 -0000 Received: (qmail 12069 invoked by uid 22791); 28 Nov 2007 08:21:30 -0000 X-Spam-Status: No, hits=-1.4 required=5.0 tests=AWL,BAYES_00,DK_POLICY_SIGNSOME X-Spam-Check-By: sourceware.org Received: from agminet01.oracle.com (HELO agminet01.oracle.com) (141.146.126.228) by sourceware.org (qpsmtpd/0.31) with ESMTP; Wed, 28 Nov 2007 08:21:24 +0000 Received: from rgmgw2.us.oracle.com (rgmgw2.us.oracle.com [138.1.186.111]) by agminet01.oracle.com (Switch-3.2.4/Switch-3.1.7) with ESMTP id lAS8KjkR008793; Wed, 28 Nov 2007 02:20:45 -0600 Received: from dhcp-beijing-cdc-10-182-121-96.cn.oracle.com (dhcp-beijing-cdc-10-182-121-96.cn.oracle.com [10.182.121.96]) by rgmgw2.us.oracle.com (Switch-3.2.4/Switch-3.2.4) with ESMTP id lAS8KhqN024071; Wed, 28 Nov 2007 01:20:44 -0700 Subject: Re: [SCM] master: Add a test testMemoryBufferCapacity() to TestByteBuffer.java From: Zhao Shujing Reply-To: pearly.zhao@oracle.com To: Andrew Cagney Cc: frysk@sourceware.org In-Reply-To: <474C2D7A.8020109@redhat.com> References: <20071122090733.7335.qmail@sourceware.org> <4745B7E4.4090408@redhat.com> <1195791150.22218.13.camel@linux-pzhao.site> <47476AEF.4080900@redhat.com> <1196045768.3728.6.camel@linux-pzhao.site> <474C2D7A.8020109@redhat.com> Content-Type: text/plain Organization: Oracle Date: Wed, 28 Nov 2007 08:21:00 -0000 Message-Id: <1196238270.19305.2.camel@linux-pzhao.site> Mime-Version: 1.0 X-Mailer: Evolution 2.6.0 Content-Transfer-Encoding: 7bit X-Brightmail-Tracker: AAAAAQAAAAI= X-Brightmail-Tracker: AAAAAA== X-Whitelist: TRUE X-Whitelist: TRUE X-IsSubscribed: yes Mailing-List: contact frysk-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: frysk-owner@sourceware.org X-SW-Source: 2007-q4/txt/msg00185.txt.bz2 It's been updated and the test is passing now. On Tue, 2007-11-27 at 09:45 -0500, Andrew Cagney wrote: > Zhao Shujing wrote: > > Sorry, this test is added for bug 1538. I think .capacity() can use for > > test if highWater mark is the top location when map memory to > > ByteBuffer. > > > True; however did you see: > > > + = new ExecOffspring(new ExecCommand (new String[] { > > + "/bin/rm", > > + tmpFile.toString() > > > > > > I'm not sure that ExecOffspring is what you need here as it doesn't put > > the task into an attached/stopped state; I suspect: > > Task = new DaemonBlockedAtEntry("funit-slave").getMainTask().getISA(); > > be simpler? > and: > > > + Task task = child.findTaskUsingRefresh(true); > > + if (task.getISA() == ISA.IA32) > > + assertEquals("Memory Buffer Capacity: ", 0xffffffffL, > > + task.getMemory().capacity()); > > + if (task.getISA() == ISA.X8664) > > + assertEquals("Memory Buffer Capacity: ", > > 0xffffffffffffffffL, > > + task.getMemory().capacity()); > > } > > > > > > There is also the PPC; the attribute is dependent on the ISA's word > > size, though, is something like: > > switch (task.getISA().wordSize()) > > case 4: assert ... ; break; > > case 8: assert ... ; break; > > default: fail("unknown word size"); > > } > > simplier? > > > > is the test passing or still being skipped? > can we address these? > > Andrew >