[LLVMdev] Static Profiling - GSoC 2009

Dietmar Ebner ebner at complang.tuwien.ac.at
Thu Apr 2 01:34:05 PDT 2009


On 3/31/09 5:12 PM, Andrei Alvares wrote:
> The proposal is to implement the static branch predictor described
> by Wu et al. (1994) as a LLVM Function Pass.
I'm advising a talented master student (Andreas Neustifter) at the 
Vienna University of Technology who's already doing the same thing. The 
rough goal of his work is to
a) cleanup the internal datastructures (currently it's basically a 
global map)
b) implement the same algorithm you're proposing for static branch 
c) use the algorithm from b) in combination with the spanning tree 
algorithm proposed in [Ball94] to reduce the overhead for precise 
d) utilize profile information in various optimization passes (see below)

he's already posted a rough plan for his endeavors to this mailing list 

> I would
> be happy to hear which of the LLVM analysis you guys think is the
> nicest candidate to be improved with static profiling.
There are certainly some opportunities for "high-level" optimizations, 
e.g., inlining, code layout or unrolling. However, we've been more 
interested in backend optimizations such as spilling and scheduling. I 
have a working patch that maintains profile information during the 
various codegen phases. Andreas will clean this up and contribute it 
together with his work if there is interest.

There's nothing wrong with two people working on similar things, but I 
highly suggest the two of you get together in order to avoid duplicated 
efforts. There is certainly plenty of work left for both of you :-) 
Andreas already started with the implementation, so you wouldn't have to 
start from scratch.


[Ball94] Thomas Ball, James R. Larus:
"Optimally profiling and tracing programs"
ACM TOPLAS, Volume 16, Issue 4, 1994

Dietmar Ebner
CD Laboratory - Compilation Techniques for Embedded Processors
Institut fuer Computersprachen  E: ebner at complang.tuwien.ac.at
Technische Universitaet Wien    T: (+431) 58801-58521
Argentinierstrasse 8 / E1851    F: (+431) 58801-18598
1040 Wien, Austria              W: www.complang.tuwien.ac.at/cd/ebner

More information about the llvm-dev mailing list