[M3devel] RandomTest runtime error FileWr.Error not in Raises list
Jay K
jay.krell at cornell.edu
Mon Aug 31 09:55:00 CEST 2009
Easy to trigger problems here, also on NT, like with:
VAR r: Random.T; stdout := NEW(AutoFlushWr.T).init(Stdio.stdout);
PROCEDURE Main () =
BEGIN
WHILE TRUE DO
Wr.PutText(stdout, "foofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoo\n");
END;
foofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoo
FileWr.Seek:wr.seekable=FALSE,n=53300,wr.hi=57396
***
*** runtime error:
*** Exception "FileWr.Error" not in RAISES list
*** file "..\src\rw\FileWr.m3", line 85
***
***
*** runtime error:
*** Thread client error: Attempt to lock mutex already locked by self
*** file "..\src\thread\WIN32\ThreadWin32.m3", line 119
***
Stack trace:
FP PC Procedure
--------- --------- -------------------------------
0x12fcfc 0x41c2d6 Seek + 0x125 in ..\src\rw\FileWr.m3
0x12fd58 0x40e6b1 Seek + 0x165 in ..\src\rw\AutoFlushWr.m3
0x12fd9c 0x407c9a PutStringDefault + 0x281 in ..\src\rw\Wr.m3
0x12fe50 0x407460 FastPutText + 0x105 in ..\src\rw\Wr.m3
0x12fe78 0x407328 PutText + 0x4e in ..\src\rw\Wr.m3
0x12febc 0x4010c6 Main + 0x76 in ..\src\RandomTest.m3
0x12fee0 0x405795 RandomTest_M3 + 0xb5 in ..\src\RandomTest.m3
Must be some race condition between flushing and other writers?
- Jay
From: jay.krell at cornell.edu
To: m3devel at elegosoft.com
Subject: RandomTest runtime error FileWr.Error not in Raises list
Date: Sun, 30 Aug 2009 11:00:00 +0000
I think this is two or three problems.
- missing raises
- why does it raise
- why does it hang
Often but not always:
jay at xlin2:/dev2/release_branch_cm3_5_8/m3-libs/libm3/tests/random$ pwd
/dev2/release_branch_cm3_5_8/m3-libs/libm3/tests/random
jay at xlin2:/dev2/release_branch_cm3_5_8/m3-libs/libm3/tests/random$ ./LINUXLIBC6
/RandomTest -perm
under gdb:
***
*** runtime error:
*** Exception "FileWr.Error" not in RAISES list
*** file "../src/rw/FileWr.m3", line 81
***
Program received signal SIGABRT, Aborted.
[Switching to Thread -1210370368 (LWP 21415)]
0xb7f25410 in ?? ()
(gdb) bt
#0 0xb7f25410 in ?? ()
#1 0xbfc4f14c in ?? ()
#2 0x00000006 in ?? ()
#3 0x000053a7 in ?? ()
#4 0xb7ddc811 in raise () from /lib/tls/i686/cmov/libc.so.6
#5 0xb7dddfb9 in abort () from /lib/tls/i686/cmov/libc.so.6
#6 0x0808bb12 in RTOS__Crash () at ../src/runtime/POSIX/RTOS.m3:20
#7 0x08085d83 in RTProcess__Crash (M3_Bd56fi_msg=0x0)
at ../src/runtime/common/RTProcess.m3:65
#8 0x08083a8e in RTError__EndError (M3_AicXUJ_crash=1 '\001')
at ../src/runtime/common/RTError.m3:118
#9 0x08083752 in RTError__MsgS (M3_AJWxb1_file=0x80c437c, M3_AcxOUs_line=81,
M3_Bd56fi_msgA=0x80cc350, M3_Bd56fi_msgB=0xb7d7eba0,
M3_Bd56fi_msgC=0x80cc378) at ../src/runtime/common/RTError.m3:40
#10 0x08083ef6 in RTException__Crash (M3_Cblw37_a=0xbfc4f460,
M3_AicXUJ_raises=1 '\001', M3_AJWxb1_rte=0x80c8400)
at ../src/runtime/common/RTException.m3:79
#11 0x08083c5f in RTException__DefaultBackstop (M3_Cblw37_a=0xbfc4f460,
M3_AicXUJ_raises=0 '\0') at ../src/runtime/common/RTException.m3:41
#12 0x08083b59 in RTException__InvokeBackstop (M3_Cblw37_a=0xbfc4f460,
M3_AicXUJ_raises=0 '\0') at ../src/runtime/common/RTException.m3:25
#13 0x0808c5a8 in RTException__Raise (M3_Cblw37_act=0xbfc4f460)
at ../src/runtime/ex_frame/RTExFrame.m3:29
#14 0x08083cb6 in RTException__DefaultBackstop (M3_Cblw37_a=0xbfc4f460,
---Type <return> to continue, or q <return> to quit---
M3_AicXUJ_raises=1 '\001') at ../src/runtime/common/RTException.m3:47
#15 0x08083b59 in RTException__InvokeBackstop (M3_Cblw37_a=0xbfc4f460,
M3_AicXUJ_raises=1 '\001') at ../src/runtime/common/RTException.m3:25
#16 0x0808c689 in RTException__Raise (M3_Cblw37_act=0xbfc4f460)
at ../src/runtime/ex_frame/RTExFrame.m3:51
#17 0x08073e99 in RTHooks__Raise (M3_AJWxb1_ex=0x80c42a0, M3_AJWxb1_arg=0x0,
M3_AJWxb1_module=0x80c43e0, M3_AcxOUs_line=81)
at ../src/runtime/common/RTHooks.m3:79
#18 0x0806a9c4 in FileWr__Seek (M3_EJV0jI_wr=0xb7d73234, M3_Cwb5VA_n=4198)
at ../src/rw/FileWr.m3:81
#19 0x080559ea in AutoFlushWr__Seek (M3_Aauo9c_wr=0xb7d790a4,
M3_Cwb5VA_n=4198) at ../src/rw/AutoFlushWr.m3:106
#20 0x080544bf in WrClass__PutStringDefault (M3_BxxOH1_wr=0xb7d790a4,
M3_CKMnXU_a=0xbfc4f7f4) at ../src/rw/Wr.m3:193
#21 0x080539de in UnsafeWr__FastPutText (M3_BxxOH1_wr=0xb7d790a4,
M3_Bd56fi_t=0xb7d7eb84) at ../src/rw/Wr.m3:105
#22 0x08053837 in Wr__PutText (M3_BxxOH1_wr=0xb7d790a4,
M3_Bd56fi_t=0xb7d7eb84) at ../src/rw/Wr.m3:93
#23 0x0804f561 in RandomTest__TestPerm () at ../src/RandomTest.m3:387
#24 0x0804bedf in RandomTest__Main () at ../src/RandomTest.m3:64
#25 0x08050235 in RandomTest_M3 (M3_AcxOUs_mode=1) at ../src/RandomTest.m3:458
#26 0x08082bf8 in RTLinker__RunMainBody (M3_DjPxE3_m=0x80be120)
at ../src/runtime/common/RTLinker.m3:399
#27 0x08081fb2 in RTLinker__AddUnitI (M3_DjPxE3_m=0x80be120)
---Type <return> to continue, or q <return> to quit---
at ../src/runtime/common/RTLinker.m3:113
#28 0x08082040 in RTLinker__AddUnit (M3_DjPxE5_b=0x8050165)
at ../src/runtime/common/RTLinker.m3:122
#29 0x0804baee in main (argc=2, argv=0xbfc4fe94, envp=0xbfc4fea0)
at _m3main.mc:4
(gdb)
This test hangs on OpenBSD/x86.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://m3lists.elegosoft.com/pipermail/m3devel/attachments/20090831/4529c2f7/attachment-0002.html>
More information about the M3devel
mailing list