[LLVMdev] question on instruction selection

Bob Wilson bob.wilson at apple.com
Tue Jan 26 16:07:40 PST 2010


On Jan 26, 2010, at 3:16 PM, Nuno Lopes wrote:
> 
> For now, I'm just trying to understand what's the main contribution of this 
> paper towards simplifying the retargeting of a compiler. Don't get me wrong; 
> I do not want to bash the paper; I just feel that something is escaping me. 
> The approach proposed seems to be fairly similar to what gcc and LLVM do. 
> What makes me wondering is why their algorithm needs heavy reasoning to do 
> semantic equivalence checking, while gcc & LLVM only need simple pattern 
> matching. That's why I've been scratching my head the whole day :)
> Do you have any insight that can enlighten me, please?

I took a very quick look at the paper.  I think the idea is to declaratively specify the semantics of each IR operation and each machine instruction, and then automatically figure out how to select the IR operations to machine instructions.  GCC and LLVM require that mapping to be specified manually.



More information about the llvm-dev mailing list