summaryrefslogtreecommitdiffstats
path: root/clang/test/OpenMP
Commit message (Collapse)AuthorAgeFilesLines
...
* [OPENMP 4.1] Add codegen for 'simdlen' clause.Alexey Bataev2015-08-211-0/+64
| | | | | | | | | Add emission of metadata for simd loops in presence of 'simdlen' clause. If 'simdlen' clause is provided without 'safelen' clause, the vectorizer width for the loop is set to value of 'simdlen' clause + all read/write ops in loop are marked with '!llvm.mem.parallel_loop_access' metadata. If 'simdlen' clause is provided along with 'safelen' clause, the vectorizer width for the loop is set to value of 'simdlen' clause + all read/write ops in loop are not marked with '!llvm.mem.parallel_loop_access' metadata. If 'safelen' clause is provided without 'simdlen' clause, the vectorizer width for the loop is set to value of 'safelen' clause + all read/write ops in loop are not marked with '!llvm.mem.parallel_loop_access' metadata. llvm-svn: 245697
* [OPENMP 4.1] Add ast-print tests for 'val', 'uval' and 'ref' modifiers.Alexey Bataev2015-08-211-6/+10
| | | | llvm-svn: 245693
* [OPENMP 4.1] Initial support for 'simdlen' clause.Alexey Bataev2015-08-219-24/+552
| | | | | | Add parsing/sema analysis for 'simdlen' clause in simd directives. Also add check that if both 'safelen' and 'simdlen' clauses are specified, the value of 'simdlen' parameter is less than the value of 'safelen' parameter. llvm-svn: 245692
* [OPENMP 4.1] Improved codegen for 'uval' qualifier of 'linear' clause.Alexey Bataev2015-08-211-0/+129
| | | | | | According to standard the 'uval' modifier declares the address of the original list item to have an invariant value for all iterations of the associated loop(s). Patch improves codegen for this qualifier by removing usage of the original reference variable and replacing by referenced l-value. llvm-svn: 245674
* [OPENMP 4.1] Allow to use 'uval' and 'ref' modifiers for reference types only.Alexey Bataev2015-08-201-6/+8
| | | | | | Standard allows to use 'uval' and 'ref' modifiers in 'linear' clause for variables with reference types only. Added check for it and modified test. llvm-svn: 245556
* [OPENMP 4.1] Initial support for modifiers in 'linear' clause.Alexey Bataev2015-08-202-8/+52
| | | | | | | | | | | | | | | | | | | | | | OpenMP 4.1 adds 3 optional modifiers to 'linear' clause. Format of 'linear' clause has changed to: ``` linear(linear-list[ : linear-step]) ``` where linear-list is one of the following ``` list modifier(list) ``` where modifier is one of the following: ``` ref (C++) val (C/C++) uval (C++) ``` Patch adds parsing and sema analysis for these modifiers. llvm-svn: 245550
* [OPENMP] Link libomp.lib on WindowsAlexey Bataev2015-08-191-0/+18
| | | | | | | Adds libomp.lib for -fopenmp=libomp and libiomp5md.lib for -fopenmp=libiomp5 on Windows Differential Revision: http://reviews.llvm.org/D11932 llvm-svn: 245414
* [OPENMP 4.1] Allow variables with reference types in private clauses.Alexey Bataev2015-08-1838-143/+135
| | | | | | OpenMP 4.1 allows to use variables with reference types in all private clauses (private, firstprivate, lastprivate, linear etc.). Patch allows to use such variables and fixes codegen for linear variables with reference types. llvm-svn: 245268
* [OPENMP] Fix for http://llvm.org/PR24371: Assert failure compiling blender 2.75.Alexey Bataev2015-08-145-20/+25
| | | | | | | blender uses statements expression in condition of the loop under control of the '#pragma omp parallel for'. This condition is used several times in different expressions required for codegen of the loop directive. If there are some variables defined in statement expression, it fires an assert during codegen because of redefinition of the same variables. We have to rebuild several expression to be sure that all variables are unique. llvm-svn: 245041
* [OPENMP] Fix for http://llvm.org/PR24430: clang hangs on invalid input with ↵Alexey Bataev2015-08-121-0/+5
| | | | | | | | openmp directive Add parsing of openmp directives inside structs/unions in C mode. llvm-svn: 244719
* This patch commits OpenMP 4 target device clausesMichael Wong2015-08-072-0/+56
| | | | | | | This is committed on behalf of Kelvin Li http://reviews.llvm.org/D11469?id=31227 llvm-svn: 244325
* [OPENMP 4.1] Allow references in init expression for loop-based constructs.Alexey Bataev2015-08-066-40/+55
| | | | | | OpenMP 4.1 allows to use variables with reference types in private clauses and, therefore, in init expressions of the cannonical loop forms. llvm-svn: 244209
* [OPENMP 4.1] Support for 'linear' clause in loop directives.Alexey Bataev2015-08-0414-78/+1063
| | | | | | OpenMP 4.1 allows 'linear' clause in loop directives. Patch adds support for it. llvm-svn: 243969
* [OPENMP] Fix compiler crash during data-sharing attributes analysis.Alexey Bataev2015-08-041-0/+3
| | | | | | If a global variable is marked as private in OpenMP construct and then is used in of the private clauses of the same construct, it might cause compiler crash because of incorrect capturing. llvm-svn: 243964
* [OPENMP 4.1] Initial support for extended 'ordered' clause.Alexey Bataev2015-07-304-4/+232
| | | | | | | | OpenMP 4.1 introduces optional argument '(n)' for 'ordered' clause, where 'n' is a number of loops that immediately follow the directive. 'n' must be constant positive integer expressions and it must be less or equal than the number of the loops in the resulting loop nest. Patch adds parsing and semantic analysis for this optional argument. llvm-svn: 243635
* [OpenMP] Fix copyin codegen test regression in order used in compareSamuel Antao2015-07-271-3/+3
| | | | | | instruction. llvm-svn: 243289
* [OpenMP] Fix copyin clause codegen regression caused by r243277. Samuel Antao2015-07-271-13/+13
| | | | llvm-svn: 243285
* [OpenMP] Add TLS requirement for the copyin clause codegen test. This is anSamuel Antao2015-07-271-1/+1
| | | | | | attempt to fix regressions triggered by r243277. llvm-svn: 243280
* [OpenMP] Add capture for threadprivate variables used in copyin clauseSamuel Antao2015-07-271-2/+257
| | | | | | if TLS is enabled in OpenMP code generation. llvm-svn: 243277
* Commit for http://reviews.llvm.org/D10765Michael Wong2015-07-213-0/+86
| | | | | | | for OpenMP 4 target data directive parsing and sema. This commit is on behalf of Kelvin Li. llvm-svn: 242785
* [OPENMP] Fixed detection of canonical loops with random access iterators.Alexey Bataev2015-07-166-7/+8
| | | | | | Add handling of iterators with copy/move constructors with default arguments + converting template constructors. llvm-svn: 242382
* [OPENMP] http://llvm.org/PR24121: canonical loop rejected when comparison ↵Alexey Bataev2015-07-151-1/+56
| | | | | | | | has implicit conversions or destruction Allow to use complex iterators expressions in loops for C++. llvm-svn: 242285
* [OPENMP] Drop type qualifiers from private variables.Alexey Bataev2015-07-1415-60/+60
| | | | | | If the variable is marked as private in OpenMP construct, the reference to this variable should not keep type qualifiers for the original variable. Private copy is not volatile or constant, so we can use unqualified type for private copy. llvm-svn: 242133
* [OpenMP] Add REQUIRES pragma to threadprivate regression tests.Samuel Antao2015-07-142-1/+2
| | | | llvm-svn: 242090
* [OpenMP] Add TLS-based implementation for threadprivate directive.Samuel Antao2015-07-135-36/+284
| | | | llvm-svn: 242080
* Revert "Revert r241620 and follow-up commits" and move the initializationAdrian Prantl2015-07-0840-28/+40
| | | | | | of the llvm targets from clang/CodeGen into ClangCheck.cpp and CIndex.cpp. llvm-svn: 241653
* Revert r241620 and follow-up commits while investigating linux buildbot ↵Adrian Prantl2015-07-0740-40/+28
| | | | | | failures. llvm-svn: 241642
* Add target requirements to testcases that emit PCH.Adrian Prantl2015-07-0710-5/+10
| | | | llvm-svn: 241630
* Update testcases that use precompiled headers to require a target afterAdrian Prantl2015-07-0718-11/+18
| | | | | | r241620. llvm-svn: 241623
* Wrap clang modules and pch files in an object file container.Adrian Prantl2015-07-0712-12/+12
| | | | | | | | | | | | | This patch adds ObjectFilePCHContainerOperations uses the LLVM backend to put the contents of a PCH into a __clangast section inside a COFF, ELF, or Mach-O object file container. This is done to facilitate module debugging by makeing it possible to store the debug info for the types defined by a module alongside the AST. rdar://problem/20091852 llvm-svn: 241620
* [OPENMP 4.0] Codegen for 'omp cancel' directive.Alexey Bataev2015-07-061-0/+95
| | | | | | | | | | Add the next codegen for 'omp cancel' directive: if (__kmpc_cancel()) { __kmpc_cancel_barrier(); <exit construct>; } llvm-svn: 241429
* [OPENMP 4.0] Fixed codegen for 'cancellation point' construct.Alexey Bataev2015-07-0313-59/+84
| | | | | | | | | | Generate the next code for 'cancellation point': if (__kmpc_cancellationpoint()) { __kmpc_cancel_barrier(); <exit construct>; } llvm-svn: 241336
* [OPENMP 4.0] Initial support for 'omp cancel' construct.Alexey Bataev2015-07-022-0/+130
| | | | | | Implemented parsing/sema analysis + (de)serialization. llvm-svn: 241253
* [OPENMP 4.0] Fixed test for 'cancellation point' directive.Alexey Bataev2015-07-021-1/+1
| | | | | | Added explicit target to pch test llvm-svn: 241240
* [OPENMP 4.0] Codegen for 'cancellation point' directive.Alexey Bataev2015-07-021-0/+70
| | | | | | | | | | The next code is generated for this construct: ``` if (__kmpc_cancellationpoint(ident_t *loc, kmp_int32 global_tid, kmp_int32 cncl_kind) != 0) <exit from outer innermost construct>; ``` llvm-svn: 241239
* [OPENMP 4.0] Initial support for 'omp cancellation point' construct.Alexey Bataev2015-07-012-0/+130
| | | | | | Add parsing and sema analysis for 'omp cancellation point' directive. llvm-svn: 241145
* Account for calling convention specifiers in function definitions in IR test ↵David Blaikie2015-06-2914-181/+181
| | | | | | | | | | | | | cases Several tests wouldn't pass when executed on an armv7a_pc_linux triple due to the non-default arm_aapcs calling convention produced on the function definitions in the IR output. Account for this with the application of a little regex. Patch by Ying Yi. llvm-svn: 240971
* [OPENMP] Codegen for 'depend' clause (OpenMP 4.0).Alexey Bataev2015-06-242-20/+190
| | | | | | | | If task directive has associated 'depend' clause then function kmp_int32 __kmpc_omp_task_with_deps ( ident_t *loc_ref, kmp_int32 gtid, kmp_task_t * new_task, kmp_int32 ndeps, kmp_depend_info_t *dep_list,kmp_int32 ndeps_noalias, kmp_depend_info_t *noalias_dep_list) must be called instead of __kmpc_omp_task(). If this directive has associated 'if' clause then also before a call of kmpc_omp_task_begin_if0() a function void __kmpc_omp_wait_deps ( ident_t *loc_ref, kmp_int32 gtid, kmp_int32 ndeps, kmp_depend_info_t *dep_list, kmp_int32 ndeps_noalias, kmp_depend_info_t *noalias_dep_list) must be called. Array sections are not supported yet. llvm-svn: 240532
* [OPENMP] Initial support for 'depend' clause (4.0).Alexey Bataev2015-06-232-8/+47
| | | | | | Parsing and sema analysis (without support for array sections in arguments) for 'depend' clause (used in 'task' directive, OpenMP 4.0). llvm-svn: 240409
* [OPENMP] Do not emit references to original variables in 'private' clause.Alexey Bataev2015-06-235-49/+23
| | | | | | | Currently if the variable is captured in captured region, capture record for this region stores reference to this variable for future use. But we don't need to provide the reference to the original variable if it was explicitly marked as private in the 'private' clause of the OpenMP construct, this variable is replaced by private copy. Differential Revision: http://reviews.llvm.org/D9550 llvm-svn: 240377
* [CodeGen] Teach X86_64ABIInfo about AVX512.Ahmed Bougacha2015-06-221-0/+3
| | | | | | | | | | | | | | | | As specified in the SysV AVX512 ABI drafts. It follows the same scheme as AVX2: Arguments of type __m512 are split into eight eightbyte chunks. The least significant one belongs to class SSE and all the others to class SSEUP. This also means we change the OpenMP SIMD default alignment on AVX512. Based on r240337. Differential Revision: http://reviews.llvm.org/D9894 llvm-svn: 240338
* [OPENMP] Codegen for 'proc_bind' clause (4.0).Alexey Bataev2015-06-181-0/+52
| | | | | | | Adds emission of the code for 'proc_bind(master|close|spread)' clause: call void @__kmpc_push_proc_bind(<loc>, i32 thread_id, i32 4|3|2) llvm-svn: 240018
* [OPENMP] Support for '#pragma omp taskgroup' directive.Alexey Bataev2015-06-183-0/+152
| | | | | | | | | | | | | Added parsing, sema analysis and codegen for '#pragma omp taskgroup' directive (OpenMP 4.0). The code for directive is generated the following way: #pragma omp taskgroup <body> void __kmpc_taskgroup(<loc>, thread_id); <body> void __kmpc_end_taskgroup(<loc>, thread_id); llvm-svn: 240011
* [OPENMP] Fixed test for '#pragma omp parallel for simd'.Alexey Bataev2015-06-181-1/+1
| | | | llvm-svn: 240009
* [OPENMP] Add support for 'omp parallel for' directive.Alexey Bataev2015-06-181-0/+696
| | | | | | Codegen for this directive is a combined codegen for 'omp parallel' region with 'omp for simd' region inside. Clauses are supported. llvm-svn: 240006
* [OPENMP] Add support for 'omp for simd' directive.Alexey Bataev2015-06-181-0/+686
| | | | | | Added codegen for combined 'omp for simd' directives, that is a combination of 'omp for' directive followed by 'omp simd' directive. Includes support for all clauses. llvm-svn: 239990
* [OPENMP] Fixed failed test for reduction clause in simd constructs.Alexey Bataev2015-06-171-6/+6
| | | | llvm-svn: 239895
* [OPENMP] Code reformatting for omp simd codegen, NFC.Alexey Bataev2015-06-171-6/+6
| | | | llvm-svn: 239889
* [OPENMP] Supported reduction clause in omp simd construct.Alexey Bataev2015-06-171-3/+30
| | | | | | | | | | | | | | | | The following code is generated for reduction clause within 'omp simd' loop construct: #pragma omp simd reduction(op:var) for (...) <body> alloca priv_var priv_var = <initial reduction value>; <loop_start>: <body> // references to original 'var' are replaced by 'priv_var' <loop_end>: var op= priv_var; llvm-svn: 239881
* [OPENMP] Support lastprivate clause in omp simd directive.Alexey Bataev2015-06-161-1/+8
| | | | | | Added codegen for lastprivate clauses within simd loop-based directives. llvm-svn: 239813
OpenPOWER on IntegriCloud