[PATCH] [OPENMP] Codegen for 'copyin' clause in 'parallel' directive.
Alexey Bataev
a.bataev at hotmail.com
Wed Apr 15 00:23:23 PDT 2015
Hi rjmccall, hfinkel, fraggamuffin, ejstotzer,
Emits the following code for the clause at the beginning of the outlined function for implicit threads:
```
if (<not a master thread>) {
...
<thread local copy of var> = <master thread local copy of var>;
...
}
<sync point>;
```
Checking for a non-master thread is performed by comparing of the address of the thread local variable with the address of the master's variable. Master thread always uses original variables, so you always know the address of the variable in the master thread.
http://reviews.llvm.org/D9026
Files:
include/clang/AST/DataRecursiveASTVisitor.h
include/clang/AST/OpenMPClause.h
include/clang/AST/RecursiveASTVisitor.h
lib/AST/Stmt.cpp
lib/AST/StmtProfile.cpp
lib/Basic/OpenMPKinds.cpp
lib/CodeGen/CGStmtOpenMP.cpp
lib/CodeGen/CodeGenFunction.h
lib/Sema/SemaOpenMP.cpp
lib/Serialization/ASTReaderStmt.cpp
lib/Serialization/ASTWriterStmt.cpp
test/OpenMP/parallel_copyin_codegen.cpp
test/OpenMP/parallel_copyin_messages.cpp
test/OpenMP/parallel_for_copyin_messages.cpp
test/OpenMP/parallel_for_simd_copyin_messages.cpp
test/OpenMP/parallel_sections_copyin_messages.cpp
tools/libclang/CIndex.cpp
EMAIL PREFERENCES
http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D9026.23754.patch
Type: text/x-patch
Size: 45095 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20150415/f7d2bc6f/attachment.bin>
More information about the cfe-commits
mailing list