зеркало из https://github.com/mono/mail-archives.git
130 строки
5.4 KiB
HTML
130 строки
5.4 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
|
|
<HTML>
|
|
<HEAD>
|
|
<TITLE> [mono-android] GC.Collect can crash
|
|
</TITLE>
|
|
<LINK REL="Index" HREF="index.html" >
|
|
<LINK REL="made" HREF="mailto:monodroid%40lists.ximian.com?Subject=%5Bmono-android%5D%20GC.Collect%20can%20crash&In-Reply-To=">
|
|
<META NAME="robots" CONTENT="index,nofollow">
|
|
<META http-equiv="Content-Type" content="text/html; charset=us-ascii">
|
|
<LINK REL="Previous" HREF="007469.html">
|
|
<LINK REL="Next" HREF="007480.html">
|
|
</HEAD>
|
|
<BODY BGCOLOR="#ffffff">
|
|
<H1>[mono-android] GC.Collect can crash</H1>
|
|
<B>warren burch</B>
|
|
<A HREF="mailto:monodroid%40lists.ximian.com?Subject=%5Bmono-android%5D%20GC.Collect%20can%20crash&In-Reply-To="
|
|
TITLE="[mono-android] GC.Collect can crash">warrenburch at gmail.com
|
|
</A><BR>
|
|
<I>Sat Dec 3 13:11:24 EST 2011</I>
|
|
<P><UL>
|
|
<LI>Previous message: <A HREF="007469.html">[mono-android] Mono for Android not closing properly?
|
|
</A></li>
|
|
<LI>Next message: <A HREF="007480.html">[mono-android] GC.Collect can crash
|
|
</A></li>
|
|
<LI> <B>Messages sorted by:</B>
|
|
<a href="date.html#7472">[ date ]</a>
|
|
<a href="thread.html#7472">[ thread ]</a>
|
|
<a href="subject.html#7472">[ subject ]</a>
|
|
<a href="author.html#7472">[ author ]</a>
|
|
</LI>
|
|
</UL>
|
|
<HR>
|
|
<!--beginarticle-->
|
|
<PRE>I am seeing occasional crashes in GC.Collect (called on the screen just
|
|
before my main game loop per level). I know some people are religious about
|
|
not calling GC.Collect but done strategically it can be useful. Here's what
|
|
I am seeing
|
|
|
|
12-03 10:03:29.951: DEBUG/AudioHardwareMot(6321): AudioStreamOutMot::standby
|
|
called
|
|
12-03 10:03:29.951: DEBUG/AudioHardwareMot(6321): Output 0x123e0 entering
|
|
standby
|
|
12-03 10:03:29.959: DEBUG/AudioHardwareMot(6321): Closing Output device
|
|
12-03 10:03:30.380: DEBUG/dalvikvm(27716): GC_EXTERNAL_ALLOC freed 153
|
|
objects / 87720 bytes in 30ms
|
|
*12-03 10:03:31.568: INFO/mono(27716): Stacktrace:
|
|
12-03 10:03:31.568: INFO/mono(27716): at System.GC.Collect () <0x0000b>
|
|
12-03 10:03:31.568: INFO/mono(27716): at GameLibrary.Utils.GarbageCollect
|
|
() <0x0000f>
|
|
12-03 10:03:31.568: INFO/mono(27716): at Exterminator.JobOrderScreen.Draw
|
|
(Microsoft.Xna.Framework.GameTime) <0x003cf>
|
|
12-03 10:03:31.568: INFO/mono(27716): at GameLibrary.ScreenManager.Draw
|
|
(Microsoft.Xna.Framework.GameTime) <0x00087>
|
|
12-03 10:03:31.568: INFO/mono(27716): at Microsoft.Xna.Framework.Game.Draw
|
|
(Microsoft.Xna.Framework.GameTime) <0x0014f>
|
|
12-03 10:03:31.568: INFO/mono(27716): at
|
|
Microsoft.Xna.Framework.Game.DoDraw (Microsoft.Xna.Framework.GameTime)
|
|
<0x0002f>
|
|
12-03 10:03:31.568: INFO/mono(27716): at
|
|
Microsoft.Xna.Framework.AndroidGameWindow.OnRenderFrame
|
|
(OpenTK.FrameEventArgs) <0x0012f>
|
|
12-03 10:03:31.568: INFO/mono(27716): at
|
|
OpenTK.Platform.Android.AndroidGameView.RunIteration () <0x00427>
|
|
12-03 10:03:31.568: INFO/mono(27716): at
|
|
OpenTK.Platform.Android.RepeatTimerTask.Run () <0x00023>
|
|
12-03 10:03:31.568: INFO/mono(27716): at Java.Util.TimerTask.n_Run
|
|
(intptr,intptr) <0x00033>
|
|
12-03 10:03:31.568: INFO/mono(27716): at (wrapper dynamic-method)
|
|
object.a51b8273-131b-4022-baad-ee1b4ea51e2a (intptr,intptr) <0x0002b>
|
|
12-03 10:03:31.568: INFO/mono(27716): at (wrapper native-to-managed)
|
|
object.a51b8273-131b-4022-baad-ee1b4ea51e2a (intptr,intptr)
|
|
<0xffffffff>*12-03 10:03:59.974: VERBOSE/DeviceStorageMonitorService(6328):
|
|
freeMemory=6630920192
|
|
12-03 10:03:59.974: VERBOSE/DeviceStorageMonitorService(6328): Threshold
|
|
Percentage=10
|
|
12-03 10:03:59.974: VERBOSE/DeviceStorageMonitorService(6328): mTotalMemory
|
|
= 70264913
|
|
12-03 10:03:59.974: INFO/DeviceStorageMonitorService(6328): Posting Message
|
|
again
|
|
12-03 10:04:15.802: DEBUG/dalvikvm(6420): GC_FOR_MALLOC freed 12828 objects
|
|
/ 524384 bytes in 124ms
|
|
12-03 10:04:39.294: DEBUG/PollingManager(6428): wake lock acquired
|
|
|
|
There should be no reason GC.Collect ever crashes, whether this is good
|
|
practice or not. I also cannot handle this exception and ignore (which of
|
|
course would be very scary but I have tried :) )
|
|
|
|
Is there a fix in the works for this problem?
|
|
|
|
Cheers
|
|
Warren
|
|
|
|
--
|
|
View this message in context: <A HREF="http://mono-for-android.1047100.n5.nabble.com/GC-Collect-can-crash-tp5044972p5044972.html">http://mono-for-android.1047100.n5.nabble.com/GC-Collect-can-crash-tp5044972p5044972.html</A>
|
|
Sent from the Mono for Android mailing list archive at Nabble.com.
|
|
-------------- next part --------------
|
|
An HTML attachment was scrubbed...
|
|
URL: <A HREF="http://lists.ximian.com/pipermail/monodroid/attachments/20111203/c0ef7335/attachment.html">http://lists.ximian.com/pipermail/monodroid/attachments/20111203/c0ef7335/attachment.html</A>
|
|
</PRE>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<!--endarticle-->
|
|
<HR>
|
|
<P><UL>
|
|
<!--threads-->
|
|
<LI>Previous message: <A HREF="007469.html">[mono-android] Mono for Android not closing properly?
|
|
</A></li>
|
|
<LI>Next message: <A HREF="007480.html">[mono-android] GC.Collect can crash
|
|
</A></li>
|
|
<LI> <B>Messages sorted by:</B>
|
|
<a href="date.html#7472">[ date ]</a>
|
|
<a href="thread.html#7472">[ thread ]</a>
|
|
<a href="subject.html#7472">[ subject ]</a>
|
|
<a href="author.html#7472">[ author ]</a>
|
|
</LI>
|
|
</UL>
|
|
|
|
<hr>
|
|
<a href="http://lists.ximian.com/mailman/listinfo/monodroid">More information about the Monodroid
|
|
mailing list</a><br>
|
|
</body></html>
|