0.5.3 to 0.9.2 adding to collection inefficiency
I upgraded from 0.5.3 to 0.9.2 of backbone.js and I noticed a significant decrease in speed on my application. The application handles many large collections and adds a large number of models at certain points. There is anywhere between 0 to 600 models added at a time. In the 0.5.3 version the sortedIndex function was the most used taking 12% of the CPU. in the 0.9.2 version the code became significantly slower and the sortBy function was taking 70% of the CPU.
I suspect that they are adding all the models then sorting it rather than adding each model to where it should be to keep the collection sorted. Is there a flag I can use to make it use the old method or any other way of speeding it up. I realise that I could implement my own collection class specific for my large data sets but I would prefer to stick with backbone collections right now.
Here is the collection comparator
comparator: function(model) {
return model.get("timestamp");
}
Thanks in advance