convert llvm ir to selection Dag

Hi,

Can anyone please tell me how can I scalarize or de-vectorize the llvm vector ir.

In this (http://old.nabble.com/Re%3A-Thoughts-about-the-llvm-architecture—p29617203.html) thread

I found LegalizeTypes will do this while generating machine code from llvm ir…

How do I convert llvm ir to selection Dag. And scalarize the vector ir and again get back llvm ir…

Thanks & Regards,

Pachauri

You can't... the SelectionDAG is part of CodeGen. If you really need
to scalarize IR, you'll need to write a pass yourself; that said, it
should be pretty straightforward to write.

-Eli

I'm not aware of any existing support for that. Once the LLVM IR is converted to a SelectionDAG, we don't ever convert it back to LLVM IR.