[LLVMdev] Re: LLVM to SUIF-MACH VM binary (Chris Lattner, John Cortes)

John Cortes jcortes at cs.ucr.edu
Thu Jan 20 02:38:39 PST 2005



Nikolaos Kavvadias wrote:
> Dear friends,
> 
> I have been using the SUIF Machine infrastructure for sometime. Some 
> optimizations are available without using a target machine, i.e. at the 
> SUIFvm level. At this level you have "infinite" registers. Other 
> optimizations, including analyses as for profiling require the use of a 
> target library, a complete backend. It is very sad, that they have 
> discontinued their MIPS backend years ago, and only Alpha, and backends 
> for the ugly x86. In terms of research, the most necessary backends are 
> the following (personal opinion).
> 
> 1. MIPS R3000, R4400, R10000
> 2. SPARC V7 to V9 (very close to no. 1)
> 3. PowerPC
> 4. ARM7, ARM9, ARM11
> 5. Alphas, but since the Alpha has very low sales in Europe, and talking 
> from my point of view it is not that necessary.
> 
> If a backend is to be used you have to do at least the following:
> do_gen ... with option -target_lib <my_target>
> do_raga ... this does the register allocation
> do_fin ... this finalizes code
> 
> Anyway usually i print out of the MachSUIF IR the information I need in 
> the form of data-dependence graphs. There is no such tool in their 
> 02.07.15 distribution so i have written a small pass to do the job. 
> Interfacing to the SUIF IR (kind of object file format) is somewhat 
> complex. It would need some work to convert between LLVM IR and SUIF IR 
> in their internal format.

Yeah, i figured it was a hassle.  I tried including the SUIFvm header files and 
got more errors than I bargained for.  Looks like it hasn't been updated to be 
portable.  I need some help in getting these suifvm references into the code I'm 
writing.  Could you have any specific information on the suifvm or suif ir so I 
could write it by hand?  The documentation available on the mach-suif website 
doesn't seem to be enough.


> 
> At their SUIFvm (virtual machine instruction set) level you have some 
> optimizations:
> 
> 1. Passes in their distribution
> Constant propagation
> SSA-to-CFG and CFG-to-SSA
> C backend (this is very buggy, e.g. functions returning void or struct 
> types are not properly reproduced)
> Peephole optim.
> Libraries to use for data-flow analysis (dfa), control-flow analysis 
> (cfa) based on Muchnick's book
> 
> 2. A few of the available external passes (including mine)
> DAG extraction tool (at http://www.geocities.com/kaveirious/) named as 
> 'bbpart'
> Passes at EPFL (best is their unused code for local-CSE and their 
> if-conversion pass)
> 
> CONCLUSIONS: MachineSUIF requires several addons that the user oughts to 
> write in order to get his work done. LLVM seems much more COMPLETE and 
> much more ACTIVE. MachSUIF is pretty much DEAD since late 2002-mid 2003.
> 
> LLVM can become the first widely used RISC-like VM. It has much potential.
> 
> Regards
> 
> Nikolaos Kavvadias
> Aristotle University of Thessaloniki
> Electronics Lab
> Department of Physics
> Thessaloniki, Greece
> 
> 

- John




More information about the llvm-dev mailing list