[LLVMdev] Creating DAGs
Gergö Barany
gergo at complang.tuwien.ac.at
Thu Aug 9 03:56:38 PDT 2012
On Wed, Aug 08, 2012 at 11:24:27 -0600, Ben Bergen wrote:
> I apologize if this is an inappropriate question for this mailing
> list.
This is the correct list.
> My question is: Is it possible to create a DAG from an llvm::Module?
> I would like to do this independent of a specific architecture using
> LLVM IR. In particular, I am interested in using a DAG to compute the
> Strahler number (http://en.wikipedia.org/wiki/Strahler_number) of the
> graph to determine the minimum number of register needed to evaluate
> an expression tree.
If you are actually interested in processor registers, I don't think it
makes sense to perform this computation at the LLVM IR level. The backend
changes the code too much to map such results from the IR to the generated
machine code, regardless of the platform. Are you after processor registers?
Then the ScheduleDAG you found is the one to use.
--
Gergö Barany, research assistant gergo at complang.tuwien.ac.at
Institute of Computer Languages http://www.complang.tuwien.ac.at/gergo/
Vienna University of Technology Tel: +43-1-58801-58522
Argentinierstrasse 8/E185, 1040 Wien, Austria Fax: +43-1-58801-18598
More information about the llvm-dev
mailing list