| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
Add assignment operator in the test to check that even if the operator
was declare explicitly, the constructor is called in the user-defined
reduction initializer anyway.
|
|
|
|
|
|
|
| |
reduction initializers.
Better to use copy constructor at the initialization of the declare
reduction construct rather than assignment operator.
|
|
|
|
|
|
|
|
|
|
| |
For consistency with normal instructions and clarity when reading IR,
it's best to print the %0, %1, ... names of function arguments in
definitions.
Also modifies the parser to accept IR in that form for obvious reasons.
llvm-svn: 367755
|
|
|
|
|
|
|
| |
Simplified codegen for the outlined regions, excluding duplication code
for handling variables with the reference types.
llvm-svn: 361529
|
|
|
|
|
|
|
|
|
|
|
| |
performance.
Internally generated functions must be marked as always_inlines in most
cases. Patch marks some extra reduction function + outlined parallel
functions as always_inline for better performance, but only if the
optimization is requested.
llvm-svn: 361269
|
|
|
|
|
|
|
| |
Functions __kmpc_alloc/__kmpc_free are updated with the new interfaces.
Patch synchronizes the compiler with the runtime.
llvm-svn: 357933
|
|
|
|
|
|
| |
Added test for the reduction variables with the allocate clause.
llvm-svn: 357629
|
|
|
|
|
|
|
| |
This reverts commit https://reviews.llvm.org/rL344150 which causes
MachineOutliner related failures on the ppc64le multistage buildbot.
llvm-svn: 344526
|
|
|
|
|
|
|
|
|
| |
This is currently a clang extension and a resolution
of the defect report in the C++ Standard.
Differential Revision: https://reviews.llvm.org/D46441
llvm-svn: 344150
|
|
|
|
|
|
|
|
|
|
|
| |
Currently ident_t objects are created const when debug info is not
enabled, but the libittnotify libray in the OpenMP runtime writes to
the reserved_2 field (See __kmp_itt_region_forking in
openmp/runtime/src/kmp_itt.inl). Now create ident_t objects non-const.
Differential Revision: https://reviews.llvm.org/D51331
llvm-svn: 340934
|
|
|
|
|
|
|
|
|
|
| |
See https://reviews.llvm.org/D47106 for details.
Reviewed By: probinson
Differential Revision: https://reviews.llvm.org/D47172
llvm-svn: 336844
|
|
|
|
|
|
|
|
|
| |
only.
Added support for -fopenmp-simd option that allows compilation of
simd-based constructs without emission of OpenMP runtime calls.
llvm-svn: 321560
|
|
|
|
|
|
|
|
|
|
|
|
| |
The adjustment is calculated with CreatePtrDiff() which returns
the difference in (base) elements. This is passed to CreateGEP()
so make sure that the GEP base has the correct pointer type:
It needs to be a pointer to the base type, not a pointer to a
constant sized array.
Differential Revision: https://reviews.llvm.org/D40911
llvm-svn: 319931
|
|
|
|
|
|
|
|
|
|
| |
spaces.
Though it is incorrect from point of view of OpenMP standard to have
dependent iteration space in OpenMP loops, compiler should not crash.
Patch fixes this problem.
llvm-svn: 319700
|
|
|
|
|
|
|
| |
Fixed passing of VLAs and variably-modified types to outlined functions.
Synchronized passing with the types codegen.
llvm-svn: 316488
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In some cases the compiler can deduce the length of an array section
as constants. With this information, VLAs can be avoided in place of
a constant sized array or even a scalar value if the length is 1.
Example:
int a[4], b[2];
pragma omp parallel reduction(+: a[1:2], b[1:1])
{ }
For chained array sections, this optimization is restricted to cases
where all array sections except the last have a constant length 1.
This trivially guarantees that there are no holes in the memory region
that needs to be privatized.
Example:
int c[3][4];
pragma omp parallel reduction(+: c[1:1][1:2])
{ }
This relands commit r316229 that I reverted in r316235 because it
failed on some bots. During investigation I found that this was because
Clang and GCC evaluate the two arguments to emplace_back() in
ReductionCodeGen::emitSharedLValue() in a different order, hence
leading to a different order of generated instructions in the final
LLVM IR. Fix this by passing in the arguments from temporary variables
that are evaluated in a defined order.
Differential Revision: https://reviews.llvm.org/D39136
llvm-svn: 316362
|
|
|
|
|
|
|
|
|
|
| |
This breaks at least two buildbots:
http://lab.llvm.org:8011/builders/clang-cmake-x86_64-avx2-linux/builds/1175
http://lab.llvm.org:8011/builders/clang-atom-d525-fedora-rel/builds/10478
This reverts commit r316229 during local investigation.
llvm-svn: 316235
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In some cases the compiler can deduce the length of an array section
as constants. With this information, VLAs can be avoided in place of
a constant sized array or even a scalar value if the length is 1.
Example:
int a[4], b[2];
pragma omp parallel reduction(+: a[1:2], b[1:1])
{ }
For chained array sections, this optimization is restricted to cases
where all array sections except the last have a constant length 1.
This trivially guarantees that there are no holes in the memory region
that needs to be privatized.
Example:
int c[3][4];
pragma omp parallel reduction(+: c[1:1][1:2])
{ }
Differential Revision: https://reviews.llvm.org/D39136
llvm-svn: 316229
|
|
|
|
|
|
| |
Adds codegen for taskloop-based directives.
llvm-svn: 308174
|
|
|
|
| |
llvm-svn: 307916
|
|
|
|
| |
llvm-svn: 307915
|
|
|
|
| |
llvm-svn: 307914
|
|
|
|
| |
llvm-svn: 307912
|
|
|
|
| |
llvm-svn: 307911
|
|
|
|
|
|
|
| |
Reworked codegen for reduction clauses for future support of reductions
in task-based directives.
llvm-svn: 307910
|
|
|
|
|
|
| |
Clang can generate LLVM IR for x86 without a registered x86 backend.
llvm-svn: 284836
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
access, by Erich Keane
OpenMP creates a variable array type with a a null size-expr. The Debug
generation failed to due to this. This patch corrects the openmp
implementation, updates the tests, and adds a new one for this
condition.
Differential Revision: https://reviews.llvm.org/D25373
llvm-svn: 284110
|
|
|
|
|
|
|
|
| |
Currently there is a problem with codegen of inlined directives inside
lambdas, it may cause a crash during codegen because of incorrect
capturing of variables. Patch fixes this problem.
llvm-svn: 267677
|
|
OpenMP 4.0 allows to define custom reduction operations using '#pragma
omp declare reduction' construct. Patch allows to use this custom
defined reduction operations in 'reduction' clauses.
llvm-svn: 263701
|