Q:

UICollectionview poor scrolling with CALayer and CATextlayer

i have a collection view with lets say around 50 objects, each object has one of three images based on its category (never mind it), also each object (that becomes a cell) has two CATextLayer objects  and a logo (each cell has a unique logo).
i have created a reusable cell that contains all of the above parameters - the category image is assigned to the cell contentView.layer, the logo is a calayer (which i create when the cell is first created and then just change it value - rather than adding a calayer each time cellforitematindexpath is called) and by the same technique change the catextlayer which differs from cell to cell (based on the datasource object info).
everything works well but the scrolling is very slow on an iPhone 4, i guess thats because that for every cell that gets called i go fetch the logo (which is on a directory). the category based images are instantiated as a layer when view load (so i don't need to fetch them when a cell is called) -  thats faster but what can i do with the logos ? i cannot initialize 50 images and have them eat all of my memory. 
i have a solution that can cause fast smooth scrolling - initialize the first objects that the user sees in the collection view, and load the cell parameters only when there is no dragging or decelerating - and than use uicollectionview.visiblecells to which cells i need to load.
but i don't want that - i want the user to scroll and see all of the cell parameters
instead of a activityIndicator.
do u have some other approach to this?
btw
i used to use UIKIt for all of that but i moved into Core Animation because i got the impression it will be faster.
tnx.

A:

See WWDC 2012 videos iOS App Performance: Responsiveness and iOS App Performance: Graphics and Animations for some tutorials on how to use Instruments to identify the problem. 
If you haven't done so already, I'd move to making the image retrieval process asynchronous. Also, if your images are large/i.e. being resized, you might want to save/use the resized/thumbnail rendition, which can improve performance. That former video even talks about the idea of replacing a complicated set of labels on a busy UICollectionView with image snapshots.
But, as David said, until you run it through time profiler, we're just guessing. To paraphrase the workflow Apple uses in those WWDC videos, you have to use instruments to quantify/identify the precise problem, form a hypothesis, quickly test that hypothesis before investing too much time in the solution, and if the hypothesis stands up to scrutiny, only then dive into implementing solutions.

