Wenzhi Tao
2008-Dec-25 02:11 UTC
[LLVMdev] Questions on Parallelism and Data Dependence Analysis
Hi, I have two questions about llvm, and expect your reply very much. 1. Is there any plan of llvm to support Thread-Level Parallelism by using OpenMP, MPI, pthread or llvm-defined directives? If automatic parallelism exploring is very hard, what is the key problem? We can't get the precise data dependence information at compile-time? 2. Can I use the functions provided by llvm to get the real data dependence(Read After Write) info on basic block level directly? In other words, can I get the task graph(node: task viewed as basic block or more coarse grain, edge: real data dependence) from sequential program using llvm to explore task-level parallelism by some proposed task scheduling algorithm? thanks. 2008-12-25 Wenzhi Tao -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20081225/bc998558/attachment.html>
Eli Friedman
2008-Dec-25 03:48 UTC
[LLVMdev] Questions on Parallelism and Data Dependence Analysis
On Wed, Dec 24, 2008 at 6:11 PM, Wenzhi Tao <linus_wind at zju.edu.cn> wrote:> Hi, I have two questions about llvm, and expect your reply very much. > > 1. Is there any plan of llvm to support Thread-Level Parallelism by using > OpenMP, MPI, pthread or llvm-defined directives? > If automatic parallelism exploring is very hard, what is the key > problem? We can't get the precise data dependence > information at compile-time?AFAIK, OpenMP, MPI, and pthreads should all work just fine with LLVM. Automatically parallelizing code is a fundamentally difficult problem for many reasons which I won't go into as it's only tangentially relevant to LLVM.> 2. Can I use the functions provided by llvm to get the real data > dependence(Read After Write) info on basic block level directly? > In other words, can I get the task graph(node: task viewed as basic block > or more coarse grain, edge: real data dependence) > from sequential program using llvm to explore task-level parallelism by > some proposed task scheduling algorithm?I don't think there's anything quite like that. There is MemoryDependenceAnalysis; that returns the dependencies for an individual instruction. -Eli
Devang Patel
2009-Jan-05 16:38 UTC
[LLVMdev] Questions on Parallelism and Data Dependence Analysis
On Dec 24, 2008, at 6:11 PM, Wenzhi Tao wrote:> 2. Can I use the functions provided by llvm to get the real data > dependence(Read After Write) info on basic block level directly? > In other words, can I get the task graph(node: task viewed as > basic block or more coarse grain, edge: real data dependence) > from sequential program using llvm to explore task-level > parallelism by some proposed task scheduling algorithm? >It is possible. Wojciech Matyjewicz has done this. See relevant thread (with attached patch) http://lists.cs.uiuc.edu/pipermail/llvmdev/2008-August/016616.html LLVM will benefit if data dependence analysis support is integrated in llvm mainline sources. - Devang