windows - Hvorfor fryser Monos xbuild og mcs nogle gange simpelthen når de påberåbes?

Indlæg af Hanne Mølgaard Plasc

Problem



Jeg har oplevet dette både med Mono 2.10.2 og 2.10.5 på Windows 7 x64.


Lejlighedsvis fryser de i nogle minutter, når der påberåbes mcs eller xbuild med nogen parametre (eller ingen). Dette er før den første udgang sker på stdout. I Process Explorer ser jeg mono.exe kører med stort set ingen aktivitet: konstant hukommelsesbrug, ingen CPU-cyklusser det meste af tiden. Jeg ser to tråde:


Den første med startadressen mono-2.0.dll!GC\_push\_all\_stack+0x6650 hænger i tilstand Wait:UserRequest med følgende stakspor:


ntoskrnl.exe!memset+0x64a
ntoskrnl.exe!KeWaitForMultipleObjects+0xd52
ntoskrnl.exe!KeWaitForMutexObject+0x19f
ntoskrnl.exe!\_\_misaligned\_access+0xba4
ntoskrnl.exe!\_\_misaligned\_access+0x1821
ntoskrnl.exe!KeWaitForMultipleObjects+0xf5d
ntoskrnl.exe!KeWaitForMutexObject+0x19f
ntoskrnl.exe!NtWaitForSingleObject+0xde
ntoskrnl.exe!KeSynchronizeExecution+0x3a43
wow64cpu.dll!TurboDispatchJumpAddressEnd+0x6c0
wow64cpu.dll!TurboDispatchJumpAddressEnd+0x4a8
wow64.dll!Wow64SystemServiceEx+0x1ce
wow64.dll!Wow64LdrpInitialize+0x429
ntdll.dll!RtlIsDosDeviceName\_U+0x24c87
ntdll.dll!LdrInitializeThunk+0xe
ntdll.dll!ZwWaitForSingleObject+0x15
kernel32.dll!WaitForSingleObjectEx+0x43
mono-2.0.dll!mono\_sem\_timedwait+0x32
mono-2.0.dll!mono\_sem\_wait+0x21
mono-2.0.dll!mono\_gc\_cleanup+0x1b0
mono-2.0.dll!mono\_thread\_set\_execution\_context+0x14a
mono-2.0.dll!GC\_push\_all\_stack+0x6678
kernel32.dll!BaseThreadInitThunk+0x12
ntdll.dll!RtlInitializeExceptionChain+0x63
ntdll.dll!RtlInitializeExceptionChain+0x36


Den anden med startadresse mono.exe+0x1290 hænger i tilstand Wait:WrLpcReply:


ntoskrnl.exe!memset+0x64a
ntoskrnl.exe!KeWaitForMultipleObjects+0xd52
ntoskrnl.exe!KeWaitForMutexObject+0x19f
ntoskrnl.exe!ExAcquireSharedStarveExclusive+0x30f
ntoskrnl.exe!NtQuerySystemInformation+0x5a7a
ntoskrnl.exe!NtQuerySystemInformation+0x5174
ntoskrnl.exe!NtQuerySystemInformation+0x2f6f
ntoskrnl.exe!KeSynchronizeExecution+0x3a43
ntoskrnl.exe!ZwUnlockFile+0x130
msrpc.sys!Ndr64AsyncClientCall+0x166fb
msrpc.sys!Ndr64AsyncClientCall+0x18638
ntdll.dll!ZwCreateFile+0xa
wow64.dll!Wow64EmulateAtlThunk+0xe697
wow64.dll!Wow64SystemServiceEx+0xd7
wow64cpu.dll!TurboDispatchJumpAddressEnd+0x2d
wow64.dll!Wow64SystemServiceEx+0x1ce
wow64.dll!Wow64LdrpInitialize+0x429
ntdll.dll!RtlUniform+0x6e6
ntdll.dll!RtlCreateTagHeap+0xa7
ntdll.dll!LdrInitializeThunk+0xe
ntdll.dll!NtCreateFile+0x12
kernel32.dll!CreateFileW+0x4a
kernel32.dll!CreateFileA+0x36
mono-2.0.dll!mono\_error\_raise\_exception+0x6f5b
mono-2.0.dll!mono\_error\_raise\_exception+0x472b
mono-2.0.dll!mono\_error\_raise\_exception+0x45fc
mono-2.0.dll!mono\_error\_raise\_exception+0x5fb4
mono-2.0.dll!mono\_config\_for\_assembly+0x16b
mono-2.0.dll!mono\_assembly\_open\_full+0x3d6
mono-2.0.dll!mono\_make\_shadow\_copy+0x7d5
mono-2.0.dll!mono\_make\_shadow\_copy+0x8b9
mono-2.0.dll!mono\_make\_shadow\_copy+0xa29
mono-2.0.dll!mono\_install\_assembly\_postload\_refonly\_search\_hook+0x46
mono-2.0.dll!mono\_assembly\_load\_full\_nosearch+0x11b
mono-2.0.dll!mono\_make\_shadow\_copy+0xd5a
mono-2.0.dll!mono\_thread\_internal\_current+0x13
mono-2.0.dll!mono\_thread\_interruption\_requested+0x4e
mono-2.0.dll!mono\_runtime\_class\_init\_full+0x14b
mono-2.0.dll!mono\_error\_raise\_exception+0x1bc3
mono-2.0.dll!mono\_error\_raise\_exception+0xe5c
mono-2.0.dll!mono\_jit\_compile\_method+0x10c
mono-2.0.dll!mono\_runtime\_invoke+0x42
mono-2.0.dll!mono\_runtime\_class\_init\_full+0x1df
mono-2.0.dll!mono\_codegen+0x303f
mono-2.0.dll!mono\_jit\_compile\_method+0x22
mono-2.0.dll!mono\_create\_static\_rgctx\_trampoline+0x637
mono-2.0.dll!mono\_magic\_trampoline+0x36
mono-2.0.dll!mono\_error\_raise\_exception+0xf28
mono-2.0.dll!mono\_runtime\_class\_init+0x1a
mono-2.0.dll!mono\_jit\_compile\_method+0x10c
mono-2.0.dll!mono\_runtime\_invoke+0x42
mono-2.0.dll!mono\_runtime\_exec\_main+0x1dc
mono-2.0.dll!mono\_main+0x1662
mono.exe+0x1474
mono.exe+0x10bb
mono.exe+0x12a8
kernel32.dll!BaseThreadInitThunk+0x12
ntdll.dll!RtlInitializeExceptionChain+0x63
ntdll.dll!RtlInitializeExceptionChain+0x36


Hver gang imellem vil de have en lille aktivitet, og efter et par minutter vil de fortsætte med deres opgave som om der ikke var sket noget. Gentagelse af samme kommando vil dog medføre samme mængde frysning.


Så snart jeg genstarter min maskine, reagerer de straks igen om et stykke tid.

Bedste reference