January 13th, 2010 — Tech
Apple’s Xcode comes with a neat profiling tool called CPU Sampler. It helps you identifying time consuming code blocks in your software and is really handy if you need to optimize for optimal performance.
Just recently I tried rewriting OpenGL’s routines that handle matrix calculations as part of a lecture at the university. Pretty soon I came to the conclusion, that I had to optimize my code if I wanted to compete with the implementation provided by OpenGL.
This post presents at quick look at CPU Sampler which helped me making well-founded decisions resulting in a faster implementation.
Continue reading →
March 13th, 2008 — Tech
I was wondering what would be the fastest method to iterate over the characters in a string with Java. A small test implements the following things:
- using an Iterable
toCharArray()
charAt()
- calling
charAt() on a CharSequence
You can download the Eclipse project as a tar or zip or browse the code online here; have a look at the StringIteratorTest class first.
Continue reading →
December 2nd, 2007 — Tech
As a follow up to my tests with the Introspector from the Java API, I did some more testing with the following Java Bean to Java Bean mappers:
Furthermore I used my own implementation and an implementation that’s hardcoded by hand.
The Eclipse project with the sample code for this post can be downloaded as tar.gz or zip or can be viewed online here.
Continue reading →
August 9th, 2007 — Tech
Lately, I read a paper about profiling with AspectJ: it investigates how to profile heap usage, object lifetime, wasted time and time spent. I was wondering how difficult it would be to write my own simple profiler; and as we’ll see it’s easy and fun.
If you’d like to check out the sample code that accompanies this post, you can download the Eclipse project as tar.gz or zip; make sure to install the AspectJ Development Tools. You can browse the code online here.
Continue reading →