Quick Links: Download Gideros Studio | Gideros Documentation | Gideros community chat | DONATE
Memory consumption — Gideros Forum

Memory consumption

MysiaGamesMysiaGames Member
edited April 2013 in General questions
My game was reject from iTunes because the program doesn't run for a memory problem consumption. I 've tested on my iPad and worls fine, but maybe on iPhones have problems. I load at the beginning many retina graphics and 9Mb of sounds. I don't know exactly what amount of memory is available on iPhones or iPads.

When I print on my ingame: print (math.floor(collectgarbage("count"))) , i got 8122. Well, i don't know what is the limit.
Does anyone some hint and number about how to manage memory problem consumptions on Gideros?

Comments

  • tkhnomantkhnoman Member
    edited April 2013
    8122 is still acceptable.
    It might be a problem at the processing time, not memory.
    (If you are sure that there is no memory leak at all)

    Apple devices will close down an app that loads longer than 6 secs, without any "view change" or something like that.
    So at the first load, make sure you give a timer-space between the loading,
    For example, you load the graphics, then at the end of the line, put a timer to load the sounds (and a loading screen would be nice).

    This might help, but might not. It's just my experience.
  • It can be possible the time loading entrance, I programmed to wait 4.5 secs, but maybe it could take more. However, i haven't any problem when install the game on my iPad2 (iOs 5.1.1). The iTunes resolution say:

    "We found that your app crashed on an iPad 3rd Gen running iOS 6.1.3, which is not in compliance with the App Store Review Guidelines."

    I have the next log error. I hope someone could see more help there:
    Exception Type:  EXC_CRASH (SIGABRT)
    Exception Codes: 0x0000000000000000, 0x0000000000000000
    Crashed Thread:  0
     
    Last Exception Backtrace:
    (0x3350129e 0x3b3a597a 0x335011c0 0x3537189a 0x3551670c 0x353b3cc6 0xd53b6 0x35369ad4 0x3536965e 0x35361846 0x35309c34 0x353096c8 0x35309116 0x36ffd59e 0x334d667e 0x334d5ee4 0x334d4cb2 0x33447eb8 0x33447d44 0x35360480 0x3535d2fc 0xd516a 0xd511c)
     
    Thread 0 name:  Dispatch queue: com.apple.main-thread
    Thread 0 Crashed:
    0   libsystem_kernel.dylib        	0x3b8a3350 __pthread_kill + 8
    1   libsystem_c.dylib             	0x3b81a11e pthread_kill + 54
    2   libsystem_c.dylib             	0x3b85696e abort + 90
    3   libc++abi.dylib               	0x3adf4d4a abort_message + 70
    4   libc++abi.dylib               	0x3adf1ff4 default_terminate() + 20
    5   libobjc.A.dylib               	0x3b3a5a74 _objc_terminate() + 144
    6   libc++abi.dylib               	0x3adf2078 safe_handler_caller(void (*)()) + 76
    7   libc++abi.dylib               	0x3adf2110 std::terminate() + 16
    8   libc++abi.dylib               	0x3adf3594 __cxa_rethrow + 84
    9   libobjc.A.dylib               	0x3b3a59cc objc_exception_rethrow + 8
    10  CoreFoundation                	0x33447f1c CFRunLoopRunSpecific + 452
    11  CoreFoundation                	0x33447d44 CFRunLoopRunInMode + 100
    12  UIKit                         	0x35360480 -[UIApplication _run] + 664
    13  UIKit                         	0x3535d2fc UIApplicationMain + 1116
    14  jewelbits                     	0x000d516a 0xd3000 + 8554
    15  jewelbits                     	0x000d511c 0xd3000 + 8476
     
    Thread 1 name:  Dispatch queue: com.apple.libdispatch-manager
    Thread 1:
    0   libsystem_kernel.dylib        	0x3b893648 kevent64 + 24
    1   libdispatch.dylib             	0x3b7c3974 _dispatch_mgr_invoke + 792
    2   libdispatch.dylib             	0x3b7c3654 _dispatch_mgr_thread$VARIANT$mp + 32
     
    Thread 2 name:  WebThread
    Thread 2:
    0   libsystem_kernel.dylib        	0x3b892eb4 mach_msg_trap + 20
    1   libsystem_kernel.dylib        	0x3b893048 mach_msg + 36
    2   CoreFoundation                	0x334d6040 __CFRunLoopServiceMachPort + 124
    3   CoreFoundation                	0x334d4d9e __CFRunLoopRun + 878
    4   CoreFoundation                	0x33447eb8 CFRunLoopRunSpecific + 352
    5   CoreFoundation                	0x33447d44 CFRunLoopRunInMode + 100
    6   WebCore                       	0x39437500 RunWebThread(void*) + 440
    7   libsystem_c.dylib             	0x3b7fc30e _pthread_start + 306
    8   libsystem_c.dylib             	0x3b7fc1d4 thread_start + 4
     
    Thread 3:
    0   libsystem_kernel.dylib        	0x3b892eb4 mach_msg_trap + 20
    1   libsystem_kernel.dylib        	0x3b893048 mach_msg + 36
    2   CoreFoundation                	0x334d6040 __CFRunLoopServiceMachPort + 124
    3   CoreFoundation                	0x334d4d9e __CFRunLoopRun + 878
    4   CoreFoundation                	0x33447eb8 CFRunLoopRunSpecific + 352
    5   CoreFoundation                	0x334a69b6 CFRunLoopRun + 94
    6   CoreMotion                    	0x33ac2bca CLMotionCore::runMotionThread(void*) + 950
    7   libsystem_c.dylib             	0x3b7fc30e _pthread_start + 306
    8   libsystem_c.dylib             	0x3b7fc1d4 thread_start + 4
     
    Thread 4 name:  Dispatch queue: com.apple.CoreLocation.ConnectionClient.0x1f864300.events
    Thread 4:
    0   libsystem_kernel.dylib        	0x3b892f1c semaphore_timedwait_trap + 8
    1   libdispatch.dylib             	0x3b7c1f6c _dispatch_semaphore_wait_slow + 116
    2   CoreLocation                  	0x3399fe14 CLClientInvokeCallback(__CLClient*, CLClientEvent, objc_object*) + 340
    3   CoreLocation                  	0x339a3478 ___CLClientCreateConnection_block_invoke_0 + 384
    4   CoreLocation                  	0x339d9ed8 __setEventHandler_block_invoke_0 + 344
    5   libxpc.dylib                  	0x3b8e8862 _xpc_connection_mach_event + 718
    6   libdispatch.dylib             	0x3b7c4524 _dispatch_mach_msg_invoke$VARIANT$mp + 120
    7   libdispatch.dylib             	0x3b7c0e8e _dispatch_queue_drain$VARIANT$mp + 78
    8   libdispatch.dylib             	0x3b7c47b2 _dispatch_mach_invoke$VARIANT$mp + 158
    9   libdispatch.dylib             	0x3b7c0e8e _dispatch_queue_drain$VARIANT$mp + 78
    10  libdispatch.dylib             	0x3b7c0dbc _dispatch_queue_invoke$VARIANT$mp + 36
    11  libdispatch.dylib             	0x3b7c0e8e _dispatch_queue_drain$VARIANT$mp + 78
    12  libdispatch.dylib             	0x3b7c0dbc _dispatch_queue_invoke$VARIANT$mp + 36
    13  libdispatch.dylib             	0x3b7c191a _dispatch_root_queue_drain + 182
    14  libdispatch.dylib             	0x3b7c1abc _dispatch_worker_thread2 + 80
    15  libsystem_c.dylib             	0x3b7f1a0e _pthread_wqthread + 358
    16  libsystem_c.dylib             	0x3b7f18a0 start_wqthread + 4
     
    Thread 5 name:  AURemoteIO::IOThread
    Thread 5:
    0   libsystem_kernel.dylib        	0x3b892eb4 mach_msg_trap + 20
    1   libsystem_kernel.dylib        	0x3b893048 mach_msg + 36
    2   AudioToolbox                  	0x32fca91c AURemoteIO::IOThread::Run() + 104
    3   AudioToolbox                  	0x32fccc84 AURemoteIO::IOThread::Entry(void*) + 4
    4   AudioToolbox                  	0x32f0a882 CAPThread::Entry(CAPThread*) + 294
    5   libsystem_c.dylib             	0x3b7fc30e _pthread_start + 306
    6   libsystem_c.dylib             	0x3b7fc1d4 thread_start + 4
     
    Thread 6:
    0   libsystem_kernel.dylib        	0x3b8a36a4 __semwait_signal + 24
    1   libsystem_c.dylib             	0x3b8013ce nanosleep + 138
    2   libsystem_c.dylib             	0x3b80133a usleep + 46
    3   jewelbits                     	0x001a8b20 0xd3000 + 875296
    4   libsystem_c.dylib             	0x3b7fc30e _pthread_start + 306
    5   libsystem_c.dylib             	0x3b7fc1d4 thread_start + 4
     
    Thread 7:
    0   libsystem_kernel.dylib        	0x3b8a308c __psynch_cvwait + 24
    1   libsystem_c.dylib             	0x3b7f4d2a _pthread_cond_wait + 642
    2   libsystem_c.dylib             	0x3b7fef14 pthread_cond_wait + 36
    3   jewelbits                     	0x0019fa36 0xd3000 + 838198
    4   jewelbits                     	0x0019f044 0xd3000 + 835652
    5   libsystem_c.dylib             	0x3b7fc30e _pthread_start + 306
    6   libsystem_c.dylib             	0x3b7fc1d4 thread_start + 4
     
    Thread 0 crashed with ARM Thread State (32-bit):
        r0: 0x00000000    r1: 0x00000000      r2: 0x00000000      r3: 0x3d399534
        r4: 0x00000006    r5: 0x3d399b88      r6: 0x1f86b0e4      r7: 0x2fd2da24
        r8: 0x1f86b0c0    r9: 0x00000888     r10: 0x00000000     r11: 0x35799e97
        ip: 0x00000148    sp: 0x2fd2da18      lr: 0x3b81a123      pc: 0x3b8a3350
      cpsr: 0x00000010
Sign In or Register to comment.