Hi Nicolas,
Ok here are the details about the crash. What I am trying to do is to read an
1.5 mb XML file and put parts of its contents into a database in many queries
(thousands of them). The program crashes with the following messages in VS
output:
---
'neko.exe': Loaded 'C:\Experiment\neko\bin\neko.exe', Symbols loaded.
'neko.exe': Loaded 'C:\WINDOWS\system32\ntdll.dll'
'neko.exe': Loaded 'C:\WINDOWS\system32\kernel32.dll'
'neko.exe': Loaded 'C:\Experiment\neko\bin\neko.dll', Symbols loaded.
'neko.exe': Loaded 'C:\Program Files\Motion-Twin\neko\gc.dll', Binary was not
built with debug information.
'neko.exe': Loaded 'C:\WINDOWS\system32\user32.dll'
'neko.exe': Loaded 'C:\WINDOWS\system32\gdi32.dll'
'neko.exe': Loaded 'C:\WINDOWS\system32\msvcr71.dll'
'neko.exe': Loaded
'C:\WINDOWS\WinSxS\x86_Microsoft.VC90.DebugCRT_1fc8b3b9a1e18e3b_9.0.30729.1_x-ww_f863c71f\msvcr90d.dll',
Symbols loaded.
'neko.exe': Loaded 'C:\WINDOWS\system32\imm32.dll'
'neko.exe': Loaded 'C:\WINDOWS\system32\advapi32.dll'
'neko.exe': Loaded 'C:\WINDOWS\system32\rpcrt4.dll'
'neko.exe': Loaded 'C:\WINDOWS\system32\secur32.dll'
'neko.exe': Loaded 'C:\Experiment\neko\bin\std.ndll', Symbols loaded.
'neko.exe': Loaded 'C:\WINDOWS\system32\ws2_32.dll'
'neko.exe': Loaded 'C:\WINDOWS\system32\msvcrt.dll'
'neko.exe': Loaded 'C:\WINDOWS\system32\ws2help.dll'
'neko.exe': Loaded 'C:\Program
Files\Motion-Twin\haxe\lib\aspell\1,0,0,0\ndll\Windows\aspell.ndll'
'neko.exe': Loaded 'C:\Experiment\neko\bin\regexp.ndll', Symbols loaded.
'neko.exe': Loaded 'C:\Experiment\neko\bin\mysql5.ndll', Symbols loaded.
'neko.exe': Loaded 'C:\WINDOWS\system32\mswsock.dll'
'neko.exe': Loaded 'C:\WINDOWS\system32\dnsapi.dll'
'neko.exe': Loaded 'C:\WINDOWS\system32\winrnr.dll'
'neko.exe': Loaded 'C:\WINDOWS\system32\wldap32.dll'
'neko.exe': Loaded 'C:\WINDOWS\system32\wshbth.dll'
'neko.exe': Loaded 'C:\WINDOWS\system32\setupapi.dll'
'neko.exe': Loaded 'C:\WINDOWS\system32\rasadhlp.dll'
'neko.exe': Loaded 'C:\WINDOWS\system32\hnetcfg.dll'
'neko.exe': Loaded 'C:\WINDOWS\system32\wshtcpip.dll'
HEAP[neko.exe]: Invalid Address specified to RtlValidateHeap( 02540000,
03027088 )
Windows has triggered a breakpoint in neko.exe.
This may be due to a corruption of the heap, which indicates a bug in neko.exe
or any of the DLLs it has loaded.
This may also be due to the user pressing F12 while neko.exe has focus.
The output window may have more diagnostic information.
----
The call stack looks like the following:
ntdll.dll!7c90120e()
[Frames below may be incorrect and/or missing, no symbols loaded for
ntdll.dll]
ntdll.dll!7c96c201()
ntdll.dll!7c96c63e()
ntdll.dll!7c9603b0()
> neko.dll!builtin_call(_value * f=0x009f4810, _value * ctx=0x026ec290,
> _value * args=0x1007901c) Line 479 + 0x19 bytes C
009fa4a7()
neko.dll!neko_val_callEx(_value * vthis=0x00000000, _value *
f=0x00b70000, _value * * args=0x02f91344, int nargs=6, _value * *
exc=0x00000000) Line 115 + 0x21 bytes C
neko.dll!neko_val_callN(_value * f=0x00b70000, _value * *
args=0x02f91344, int nargs=6) Line 133 + 0x15 bytes C
neko.dll!builtin_call(_value * f=0x00b70000, _value * ctx=0x00e66d30,
_value * args=0x02f91340) Line 479 + 0x19 bytes C
009fa4a7()
neko.dll!neko_interp(_neko_vm * vm=0x00a51f00, void * _m=0x00a54fc0,
int acc=268932716, int * pc=0x00c20000) Line 1125 + 0x1a bytes C
neko.dll!neko_vm_execute(_neko_vm * vm=0x00a51f00, void *
_m=0x00a54fc0) Line 233 + 0x1b bytes C
neko.dll!loader_loadmodule(_value * mname=0x009f5640, _value *
vthis=0x009f3fe0) Line 399 + 0xf bytes C
neko.dll!neko_val_callEx(_value * vthis=0x009f3fe0, _value *
f=0x009f48b8, _value * * args=0x0012fd14, int nargs=2, _value * *
exc=0x0012fd08) Line 76 + 0x17 bytes C
neko.exe!execute_file(_neko_vm * vm=0x00a51f00, char * file=0x003e3b48,
_value * mload=0x009f3fe0) Line 176 + 0x45 bytes C
neko.exe!main(int argc=7, char * * argv=0x003e3b08) Line 248 + 0x14
bytes C
neko.exe!__tmainCRTStartup() Line 266 + 0x19 bytes C
neko.exe!mainCRTStartup() Line 182 C
kernel32.dll!7c817067()
Any pointers where to look further? These VM internals seem cryptic for me...
The line 479 in neko.dll is
ret = val_callN(f,val_array_ptr(args),val_array_size(args));
where f is shown as VAT_JITFUN. Probably something about JIT.. How to disable
it at least? And best to fix :)
Mike
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Michael Pliskin
Sent: Tuesday, December 09, 2008 9:33 PM
To: Neko intermediate language mailing list
Subject: RE: [Neko] Neko debug and MS VC 2008
Hi Nicolas,
Thanks a lot for the tip, works now! Debugging some mysterious crash in neko,
will post some findings soon (probably).
Mike
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Nicolas Cannasse
Sent: Tuesday, December 09, 2008 9:14 PM
To: Neko intermediate language mailing list
Subject: Re: [Neko] Neko debug and MS VC 2008
Michael Pliskin a e'crit :
> Hi all,
>
>
>
> What's the current status on compiling neko under VC2008? I've just
> tried, got neko.exe as well as some libraries (mysql, zlib) built easily
> but neko.dll and std.ndll fail with __ftol2 already defined. If I switch
> to release they only ask for msvcrt60.lib which I can find, but how do I
> build the debug ones?
You can comment __ftol2, remove msvcrt60.lib, and remove MSVCRT from the
Ignored Libraries, and it should work.
The reason for these is explained here :
http://ncannasse.fr/blog/binaries_backward_compatibility
Best,
Nicolas
--
Neko : One VM to run them all
(http://nekovm.org)
--
Neko : One VM to run them all
(http://nekovm.org)
--
Neko : One VM to run them all
(http://nekovm.org)