tags:

views:

582

answers:

1

I encountered a crash in my game, here's the crash log (it's a stress test):

 PID  RPRVT  RSHRD  RSIZE Command
   1   340K   224K   436K launchd
  14   124K   160K   216K update
  15   568K   164K   620K syslogd
  16   792K   612K  1.16M lockdownd
  17  2.22M   664K  3.04M mediaserverd
  18   296K   160K   440K mDNSResponder
  20   540K   568K  1.25M iapd
  21   248K   236K   456K fairplayd
  22   640K   168K  1012K configd
  23  6.42M  6.73M  9.14M SpringBoard
  26   660K   212K  1.01M CommCenter
  27   308K   164K   620K BTServer
  28  19.1M   692K  19.9M TQServer
  29   232K   188K   284K notifyd
1830   368K   596K   672K ptpd
1833   140K   164K   280K afcd
1835   148K   164K   288K afcd
1837   140K   160K   260K notification_pro
1848  3.83M  4.89M  4.76M MobileMusicPlaye
1855  19.7M  7.65M  23.6M MyGame            ****
1856   616K  5.25M  2.27M MobilePhone
1857   292K   240K  1.25M ReportCrash

The RSIZE of MyGame is only 23.6MB, but the "Memory status: 11" indicate that the program recieves a shutdown command from OS due to memory problem.

So if the memory problem is not caused by my program, is there any way to ignore the shutdown command post from OS?

And from the iPhone develop guide, the OS will terminate a bg process which enconters a memory problem. But the SpringBoard is not terminated. So I think there should be a method to turn the memory management off in program.

A: 

You can't ignore the memory warning. The best you can do is try to free up some memory and hope your app doesn't get killed.

See this discussion for some insight.

Rhythmic Fistman
But it cannot explain why the SpriteBoard didn't get terminated.And I have try my best to reduce the memory usage in MyGame, it only takes up 23.6MB when get killed.
Alphones
Springboard doesn't get terminated because Apple wrote it.I seem to recall that 24M is some kind of glass ceiling that you should stay under.
Rhythmic Fistman
I thought someone not Apple made Springboard...but it takes up too much memory. <br>MyGame is a 3d game, and I need memory to load many textures and models. Lower the quality of textures or the model will make it looks bad. And I had done this before, load things only present on screen. It's hard to reduce memory usage now.<br>Is the 24MB private memory? I've heard about this before.
Alphones
check out the link
Rhythmic Fistman