Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

App crashing due to memory pressure #79

Closed
naveenkumard opened this issue Nov 30, 2014 · 4 comments
Closed

App crashing due to memory pressure #79

naveenkumard opened this issue Nov 30, 2014 · 4 comments

Comments

@naveenkumard
Copy link

Hi,

When I use the Fast image cache for loading images in a table view, after scrolling for some time the app crashes dud to memory pressure. I thought the main culprit might be my model object (core data) which might be taking too much memory when called from tableview's cell API.

[FICImageCache sharedImageCache] asynchronouslyRetrieveImageForEntity:imageEntity withFormatName:ImageAvatarFormatFriendsList completionBlock:^(id entity, NSString *formatName, UIImage *image)

and I created a small model object called ImageEntity which contains necessary attributes like object ID and image path to respect the FICEntity protocol.

Even though having this small model objects app crashes when I do scrolling in the table view.

Here are the some more points to analyse this issue.

  1. Table view is going to load friends list.
  2. Tableview's cell API is responsible to fetch the image and set to cell's avatar image view.

Any idea why it is taking too much memory?

Any help is highly appreciated.

Thanks.

@rromanchuk
Copy link
Contributor

How are you calling asynchronouslyRetrieveImageForEntity:imageEntity and is this table backed by a NSFetchedResultsController?

@naveenkumard
Copy link
Author

I am calling inside tableview's cell API. When image is returned by completion block, it is set to cell's avatar image view. No the table is backed by NSFetchedResultsController.

@mallorypaine
Copy link
Contributor

Pretty sure any memory pressure is being caused either by the way you are decoding and drawing images or by a leak in your app code. Either way, it's unlikely that FIC is the culprit. If you provide an instruments trace, I could take a look. Closing until there's actionable info...

@naveenkumard
Copy link
Author

Currently, I am not working on that, if possible, I can check and give you more info. Thanks for the reply.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants