Monday, July 20, 2009

Stability

Being the first release of a major rewrite, I was expecting for some bugs to show up. However, after coordinating testing with a fellow corp member, it appears that stability took quite a massive hit. One example is when you add a lot of characters all at once. When you're going over 8, each additional one causes an exponential increase in time to setup. The only way to alleviate this problem seems to be to simply restart the app.

Another issue is the result of me going single threaded. While it certainly helps in preventing the locking up of resources, it also defeats the multi-core design of Intel Macs. There are relatively high spikes with each character update and I'm not happy about them.

Sunday, July 12, 2009

Shark


Shark is a performance tool that allows you to track CPU usage of your app. In particular, it shows what percentage of time methods in a task usually take. I was unfamiliar with this tool until WWDC. After giving it a shot, I found it incredibly easy to use and reading and interpreting the data isn't too difficult either.

One problem that I was having was the recalculation of skill training times based on the idea that if you add learning skills to the plan, you have to recalculate the training times of all subsequent planned skills. After dragging in a complex skill, such as Caldari Titan, I found the delay pretty unbearable. After running it through Shark, I got the result pictured. 88% adding new items is calculating the attribute values going to be used to determine the training times. 85% (or 97% of the calculations) was spent strictly on fetching managed objects from Core Data. I'm doing far too many repetitive fetches and it's taking quite a toll on the performance. However, Shark has allowed me to pinpoint the source of the problem and now I'm back to the drawing board to find a better algorithm.

Wednesday, July 8, 2009

Almost Done


  • Downloading XML files and parsing into Core Data. Check
  • The front end character sheet. Check.
  • Working with multiple characters. Incomplete/Unknown.
  • Skill Planner Graph. Check.
  • Adding/Moving skills in skill Planner. In Progress.
  • Sparkle Framework: Incomplete.

Gutting out the inside and doing a near total rewrite is taking quite a bit of time (60+ hours so far) but I think it'll be well worth it in terms of helping progress this app.