Showing posts with label GSoC 2012. Show all posts
Showing posts with label GSoC 2012. Show all posts

Tuesday, May 22, 2012

Initial Work

Hi, I am Max Brister, a student working on JIT compilation in GNU Octave for google summer of code. My project proposal can be found on melange. In this blog I plan to explore implementation details, mark my progress, and present intermediary results.

I have already implemented a simple proof of concept which shows some promise. The simple script
a = 1;
b = 1;
tic;
for i=1:10000
  for j=1:10000
    a = a + b;
  endfor
endfor
toc;
executes on my computer in 0.178s using my jit branch, and in 253.124s using Octave 3.6.1. A speedup of 1422 is not bad.

There is still quite a ways to go before the code is ready for users though. I need to take another look at type inference, ensure error cases are handled correctly, and the current implementation requires the inner loop bounds to be constant for type inference.

You can view my current progress by checking out my code from
hg clone http://inversethought.com/hg/octave-max
The specific revision this post refers to is cba58541954c.

*edit*
I realized that I should mention that a speedup of 1422x is really a best cast speedup. Code which is already vectorized will see a much smaller speedup (if any). This is because Octave already efficiently implements vectorization.