iOS memory leak

blockypixels

New member
Joined
Sep 12, 2017
Messages
31
im not sure if this is a bug or my code

My App is working, no warnings, xcode shows memory as steadily increasing, you can see it going up at a constant rate.

If I deliver this App it will crash the phone eventually when the RAM is all gone ? Not good , the white lline was less a problem compared to this, dont want to get the blame for a phone crashing because of my app.

Any ideas ?
 

muruba

New member
CX Code Contributor
3rd Party Module Dev
Tutorial Author
Patreon Silver
Joined
Jul 5, 2017
Messages
230
Is it the same for other targets?
 

MikeHart

Administrator
Joined
Jun 19, 2017
Messages
3,167
Could be a bug could be your code. I am movimg this into general section as so far we dont know if it is a bug.
Do you constantly load and discard images?
 

Martin

Active member
CX Code Contributor
3rd Party Module Dev
Tutorial Author
Joined
Jun 19, 2017
Messages
334
Could you provide an example that causes this issue?
 

blockypixels

New member
Joined
Sep 12, 2017
Messages
31
No actually , I load a bigger font and my graphics used in the app in the OnCreate method, DrawRect is used alot and a databuffer, no sound.

Sorry I took so long to get back here to this thread, I have almost finished my .ipa (archived app) for iOS, I had a tight dead-line to complete the program, its working very well on my iPhone.

Unfortunately I have a confidentiality agreement with the local business that is paying me to make the iphone app so I cant upload a screen shot or upload parts of the source code.

But I will make a stripped back build and test that adding back parts until I recreate the effect.

It creeps up very slowly so it may be nothing , the GC might already be handling it, anyway the app doesnt crash or report a problem.

Actually Cerberus is amazing ! My app looks really good and runs really smoothly !

I will upload screenshots of my other project thats my own later after this one is finished, I have a working console emulator written in Cerberus.
 

MikeHart

Administrator
Joined
Jun 19, 2017
Messages
3,167
Please test with the new release. And we would definitely need a small example showing off the leak.
The memory leak with mojo2 is fixed.
 

blockypixels

New member
Joined
Sep 12, 2017
Messages
31
Ok, im really busy finishing the current app, I want to deliver the finished product next week, I will let him know an update will be a few weeks later.

I will start by building a completely stripped back bare minimal build and add parts of the program back in until I identify the issue precisely using xcode instruments.

Im getting really great results on the Apple targets; Mac and iOS ie really fast graphics and frame rate is very smooth, but windows desktop is only half as fast and android my app is uselessly slow, building time is acceptable, with the new xcode build times from xcode are extremely fast ! and it remembers the build setting better.

I can definitely keep using Cerberus as im only interested in the iOS and Mac targets, it took ages to write a GUI and make a font etc but it really works well in the end, im using a consolata font three times bigger than the original drawtext font.

Will post some source code and output from tests here in a week or two.

Thank you for keeping this compiler with potential going forward.

Thanks.
 
Last edited:
Top Bottom