NetBSD Problem Report #38235

From martin@duskware.de  Thu Mar 13 09:19:36 2008
Return-Path: <martin@duskware.de>
Received: from mail.netbsd.org (mail.netbsd.org [204.152.190.11])
	by narn.NetBSD.org (Postfix) with ESMTP id B4BFF63B842
	for <gnats-bugs@gnats.netbsd.org>; Thu, 13 Mar 2008 09:19:36 +0000 (UTC)
Message-Id: <20080313081654.5DA6463B842@narn.NetBSD.org>
Date: Thu, 13 Mar 2008 08:16:54 +0000 (UTC)
From: acloete@dlemma.org
Reply-To: acloete@dlemma.org
To: netbsd-bugs-owner@NetBSD.org
Subject: lang/moscow_ml timing fails with: "Uncaught exception: Time"
X-Send-Pr-Version: www-1.0

>Number:         38235
>Category:       pkg
>Synopsis:       lang/moscow_ml timing fails with: "Uncaught exception: Time"
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Mar 13 09:20:00 +0000 2008
>Originator:     Alistair Cloete
>Release:        4.0
>Organization:
>Environment:
NetBSD fuji.dlemma.org 4.0 NetBSD 4.0 (GENERIC) #0: Sun Dec 16 00:20:10 PST 2007  builds@wb34:/home/builds/ab/netbsd-4-0-RELEASE/i386/200712160005Z-obj/home/builds/ab/netbsd-4-0-RELEASE/src/sys/arch/i386/compile/GENERIC i386

>Description:
Moscow ML's supplied timing function Mosml.time sporadically
causes 'Time' exceptions. These cause failures in Moscow ML's own
test suite and prevent HOL 4 (http://hol.sf.net/) from building.

Moscow ML expects getrusage(2) to return monotonically increasing
values for ru_utime and ru_stime. When these values decrease,
a 'Time' exception is raised. The getrusage(2) man page does
not specify whether this is expected or accidental behaviour
on NetBSD. (This may be related to PR bin/10201.)
>How-To-Repeat:
$ pkg_info -e moscow_ml
moscow_ml-2.00nb1

$ cat >time.sml <<'EOT'
load "Mosml";

let fun loop2 m = if m=0 then 7 else
(  let fun loop1 n = if n=0 then 7 else loop1 (n-1)
    in Mosml.time loop1 5000000 end;
   loop2 (m-1)
)
in loop2 50 end;

quit();
EOT

$ mosml time.sml
Moscow ML version 2.00 (June 2000)
Enter `quit();' to quit.
[opening file "time.sml"]
> val it = () : unit
User: 0.220  System: 0.001  GC: 0.000  Real: 0.221
User: 0.147  System: 0.001  GC: 0.000  Real: 0.148
User: 0.145  System: 0.000  GC: 0.000  Real: 0.145
! Uncaught exception: 
! Time
[closing file "time.sml"]

>Fix:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2007 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.