[PATCH] D99436: [OPENMP]Fix PR49366: crash on VLAs in task untied regions.

2021-03-26 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev created this revision. ABataev added a reviewer: jdoerfert. Herald added subscribers: guansong, yaxunl. ABataev requested review of this revision. Herald added a subscriber: sstefan1. Herald added a project: clang. We need to capture the local variables into a record in task untied regions

[PATCH] D99445: [OPENMP]Fix PR49052: Clang crashed when compiling target code with assert(0).

2021-03-26 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev created this revision. ABataev added a reviewer: jdoerfert. Herald added subscribers: guansong, yaxunl. ABataev requested review of this revision. Herald added a subscriber: sstefan1. Herald added a project: clang. Need to insert a basic block during generation of the target region to avoi

[PATCH] D99445: [OPENMP]Fix PR49052: Clang crashed when compiling target code with assert(0).

2021-03-29 Thread Alexey Bataev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGdcf96178cb34: [OPENMP]Fix PR49052: Clang crashed when compiling target code with assert(0). (authored by ABataev). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.o

[PATCH] D99432: [OPENMP]Fix PR48851: the locals are not globalized in SPMD mode.

2021-03-29 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. In D99432#2654025 , @jdoerfert wrote: > In D99432#2653483 , @ABataev wrote: > >> In D99432#2653474 , @jdoerfert >> wrote: >> >>> Can we please alway

[PATCH] D99297: [OPENMP]Fix PR49636: Assertion `(!Entry.getAddress() || Entry.getAddress() == Addr) && "Resetting with the new address."' failed.

2021-03-29 Thread Alexey Bataev via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGf6f21dcd6c2f: [OPENMP]Fix PR49636: Assertion `(!Entry.getAddress() || Entry.getAddress() ==… (authored by ABataev). Repository: rG LLVM Github Mon

[PATCH] D98812: [OPENMP]Map data field with l-value reference types.

2021-03-29 Thread Alexey Bataev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG0411b2331916: [OPENMP]Map data field with l-value reference types. (authored by ABataev). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D98812/new/ https://r

[PATCH] D99521: [OPENMP]Fix PR48885: Crash in passing firstprivate args to tasks on Apple M1.

2021-03-29 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev created this revision. ABataev added a reviewer: jdoerfert. Herald added subscribers: guansong, yaxunl. ABataev requested review of this revision. Herald added a project: clang. Need to bitcast the function pointer passed as a parameter to the real type to avoid possible problem with calli

[PATCH] D99530: [OPENMP]Fix PR49098: respect firstprivate of declare target variable.

2021-03-29 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev created this revision. ABataev added a reviewer: jdoerfert. Herald added subscribers: guansong, yaxunl. ABataev requested review of this revision. Herald added a subscriber: sstefan1. Herald added a project: clang. Need to respect mapping/privatization of declare target variables in the ta

[PATCH] D99459: [OpenMP] Implement '#pragma omp unroll'. WIP.

2021-03-29 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/include/clang/AST/OpenMPClause.h:899 +public: + /// Build a 'sizes' AST node. + /// `sizes`->`full` Comment at: clang/include/clang/AST/OpenMPClause.h:902 + /// \param C Context of the

[PATCH] D99539: [OPENMP]Fix PR48740: OpenMP declare reduction in C does not require an initializer

2021-03-29 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev created this revision. ABataev added a reviewer: jdoerfert. Herald added subscribers: guansong, yaxunl. ABataev requested review of this revision. Herald added a subscriber: sstefan1. Herald added a project: clang. If no initializer-clause is specified, the private variables will be initia

[PATCH] D99539: [OPENMP]Fix PR48740: OpenMP declare reduction in C does not require an initializer

2021-03-30 Thread Alexey Bataev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG1696b8ae96b2: [OPENMP]Fix PR48740: OpenMP declare reduction in C does not require an… (authored by ABataev). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99

[PATCH] D99611: [OPENMP]Fix PR48658: [OpenMP 5.0] Compiler crash when OpenMP atomic sync hints used.

2021-03-30 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev created this revision. ABataev added a reviewer: jdoerfert. Herald added subscribers: jfb, guansong, yaxunl. ABataev requested review of this revision. Herald added a subscriber: sstefan1. Herald added a project: clang. No need to consider hint clause kind as the main atomic clause kind at

[PATCH] D99190: WIP: [SYCL] Add design document for SYCL mode

2021-03-30 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/docs/SYCLSupport.md:123 +traverse all symbols accessible from kernel functions and add them to the +"device part" of the code marking them with the new SYCL device attribute. + bader wrote: > Naghasan wrote: > > Op

[PATCH] D99617: [OPENMP]Fix PR48607: Crash during clang openmp codegen for firstprivate() of `float _Complex`.

2021-03-30 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev created this revision. ABataev added a reviewer: jdoerfert. Herald added subscribers: guansong, yaxunl. ABataev requested review of this revision. Herald added a subscriber: sstefan1. Herald added a project: clang. Need to cast the argument for the debug wrapper function call to the corres

[PATCH] D99617: [OPENMP]Fix PR48607: Crash during clang openmp codegen for firstprivate() of `float _Complex`.

2021-03-30 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/CodeGen/CGStmtOpenMP.cpp:644 + if (PI->getType()->isFirstClassType()) +; LValue LV = WrapperCGF.MakeAddrLValue( jdoerfert wrote: > leftover? yes, need to restore original code here Reposit

[PATCH] D99617: [OPENMP]Fix PR48607: Crash during clang openmp codegen for firstprivate() of `float _Complex`.

2021-03-30 Thread Alexey Bataev via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGe2c7bf08cc8e: [OPENMP]Fix PR48607: Crash during clang openmp codegen for firstprivate() of… (authored by ABataev). Changed prior to commit: https:

[PATCH] D99611: [OPENMP]Fix PR48658: [OpenMP 5.0] Compiler crash when OpenMP atomic sync hints used.

2021-03-30 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/test/OpenMP/atomic_codegen.cpp:61 St().get() %= b; -#pragma omp atomic +#pragma omp atomic hint(6) s.field++; jdoerfert wrote: > Should this influence the IR in any way? Currently not, it is just igno

[PATCH] D99622: [OpenMP51] Accept `primary` as proc bind affinity policy in Clang

2021-03-31 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. Could you add a small codegen test? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99622/new/ https://reviews.llvm.org/D99622 ___ cfe-commits mailing list cfe-commits@lists.llvm.o

[PATCH] D99622: [OpenMP51] Accept `primary` as proc bind affinity policy in Clang

2021-03-31 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/test/OpenMP/distribute_parallel_for_proc_bind_codegen.cpp:108-135 +#ifdef CK2 + +typedef __INTPTR_TYPE__ intptr_t; + +// CK2-DAG: [[IDENT_T_TY:%.+]] = type { i32, i32, i32, i32, i8* } +// CK2-DAG: [[STR:@.+]] = private unnamed_add

[PATCH] D99622: [OpenMP51] Accept `primary` as proc bind affinity policy in Clang

2021-03-31 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/test/OpenMP/nvptx_target_parallel_proc_bind_codegen.cpp:110-147 +// Test target codegen - host bc file has to be created first. +// RUN: %clang_cc1 -DCK2 -verify -fopenmp -fopenmp-version=45 -fopenmp-cuda-mode -x c++ -triple powe

[PATCH] D99611: [OPENMP]Fix PR48658: [OpenMP 5.0] Compiler crash when OpenMP atomic sync hints used.

2021-03-31 Thread Alexey Bataev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG66da4f6fc9c1: [OPENMP]Fix PR48658: [OpenMP 5.0] Compiler crash when OpenMP atomic sync hints… (authored by ABataev). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm

[PATCH] D99521: [OPENMP]Fix PR48885: Crash in passing firstprivate args to tasks on Apple M1.

2021-03-31 Thread Alexey Bataev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGa28e835e9494: [OPENMP]Fix PR48885: Crash in passing firstprivate args to tasks on Apple M1. (authored by ABataev). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.o

[PATCH] D99689: [OPENMP]Add option -fopenmp-cuda-const-firstprivate to control address space of the corresponding global.

2021-03-31 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev created this revision. ABataev added a reviewer: jdoerfert. Herald added subscribers: jansvoboda11, dexonsmith, dang, guansong, yaxunl. ABataev requested review of this revision. Herald added a subscriber: sstefan1. Herald added a project: clang. Added options -f-[no]openmp-cuda-const-firs

[PATCH] D99689: [OPENMP]Add option -fopenmp-cuda-const-firstprivate to control address space of the corresponding global.

2021-03-31 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. In D99689#2662848 , @jdoerfert wrote: > Can you please show me a test case or explain to me when/how this global is > actually used. It is passed as an argument to the target region. When libomptarget requests the memory for the

[PATCH] D99689: [OPENMP]Add option -fopenmp-cuda-const-firstprivate to control address space of the corresponding global.

2021-03-31 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. In D99689#2662856 , @jdoerfert wrote: > In D99689#2662852 , @ABataev wrote: > >> In D99689#2662848 , @jdoerfert >> wrote: >> >>> Can you please show

[PATCH] D99689: [OPENMP]Add option -fopenmp-cuda-const-firstprivate to control address space of the corresponding global.

2021-04-01 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. In D99689#2662875 , @jdoerfert wrote: > In D99689#2662860 , @ABataev wrote: > >> In D99689#2662856 , @jdoerfert >> wrote: >> >>> In D99689#2662852 <

[PATCH] D99622: [OpenMP51] Accept `primary` as proc bind affinity policy in Clang

2021-04-01 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev accepted this revision. ABataev added a comment. This revision is now accepted and ready to land. LG Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99622/new/ https://reviews.llvm.org/D99622 ___ c

[PATCH] D99762: [OPENMP]Fix PR49777: Clang should not try to specialize orphaned directives in device codegen.

2021-04-01 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev created this revision. ABataev added a reviewer: jdoerfert. Herald added subscribers: guansong, yaxunl. ABataev requested review of this revision. Herald added a subscriber: sstefan1. Herald added a project: clang. Compiler supports generic code emission, but in some cases may erroneously

[PATCH] D99771: [OpenMP, test] Fix use of undef DECL FileCheck var

2021-04-01 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev accepted this revision. ABataev added a comment. This revision is now accepted and ready to land. LG, thanks Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99771/new/ https://reviews.llvm.org/D99771 _

[PATCH] D99775: [OpenMP, test] Fix use of undef VAR_PRIV FileCheck var

2021-04-01 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev accepted this revision. ABataev added a comment. This revision is now accepted and ready to land. LG Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99775/new/ https://reviews.llvm.org/D99775 ___ c

[PATCH] D99679: [OPENMP51]Initial support for novariants clause

2021-04-02 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/include/clang/AST/OpenMPClause.h:7659 +/// clause with condition 'a > 5'. +class OMPNovariantsClause : public OMPClause, public OMPClauseWithPreInit { + friend class OMPClauseReader; `final` Com

[PATCH] D99679: [OPENMP51]Initial support for novariants clause

2021-04-02 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:13567-13568 +case OMPD_dispatch: + CaptureRegion = OMPD_task; + break; +default: What about other directives? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST AC

[PATCH] D99679: [OPENMP51]Initial support for novariants clause

2021-04-02 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:13567-13568 +case OMPD_dispatch: + CaptureRegion = OMPD_task; + break; +default: jyu2 wrote: > ABataev wrote: > > What about other directives? > Hi Alexey, > > As of now "

[PATCH] D99679: [OPENMP51]Initial support for novariants clause

2021-04-02 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev accepted this revision. ABataev added a comment. This revision is now accepted and ready to land. LG Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99679/new/ https://reviews.llvm.org/D99679 ___ c

[PATCH] D99848: [OPENMP51]Initial support for nocontext clause

2021-04-05 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. Formatting Comment at: clang/lib/Sema/SemaOpenMP.cpp:14908 llvm::MapVector Captures; + ValExpr = tryBuildCapture(*this, ValExpr, Captures).get(); HelperValStmt = buildPreInits(Context, Captures); This must be fixed in

[PATCH] D99848: [OPENMP51]Initial support for nocontext clause

2021-04-05 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev accepted this revision. ABataev added a comment. This revision is now accepted and ready to land. LG Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99848/new/ https://reviews.llvm.org/D99848 ___ c

[PATCH] D99995: [OpenMP51] Initial support for marked directive and filter clause

2021-04-07 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. `marked`->`masked` Comment at: clang/include/clang/AST/OpenMPClause.h:8244 + + /// Set condition. + void setThreadID(Expr *TID) { ThreadID = TID; } condition? Comment at: clang/include/clang/AST/OpenMPClause.h:8270-

[PATCH] D100055: Fix missing generate capture expression for novariants's condition

2021-04-07 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev accepted this revision. ABataev added a comment. This revision is now accepted and ready to land. LG Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100055/new/ https://reviews.llvm.org/D100055 ___

[PATCH] D99995: [OpenMP51] Initial support for masked directive and filter clause

2021-04-08 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/Parse/ParseOpenMP.cpp:2814 } if (CKind == OMPC_ordered && PP.LookAhead(/*N=*/0).isNot(tok::l_paren)) This can be simplified like this: ``` if (!FirstClause) { Diag(Tok, diag::err_omp_more_

[PATCH] D99995: [OpenMP51] Initial support for masked directive and filter clause

2021-04-08 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev accepted this revision. ABataev added a comment. This revision is now accepted and ready to land. LG Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D5/new/ https://reviews.llvm.org/D5 ___ c

[PATCH] D100187: [OPENMP]Fix PR49115: Incorrect results for scan directive.

2021-04-09 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev created this revision. ABataev added reviewers: jdoerfert, mikerice, jyu2. Herald added subscribers: guansong, yaxunl. ABataev requested review of this revision. Herald added a subscriber: sstefan1. Herald added a project: clang. For combined worksharing directives need to emit the temp ar

[PATCH] D100187: [OPENMP]Fix PR49115: Incorrect results for scan directive.

2021-04-12 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev updated this revision to Diff 336909. ABataev added a comment. Rebase + fixes Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100187/new/ https://reviews.llvm.org/D100187 Files: clang/lib/CodeGen/CGStmtOpenMP.cpp clang/lib/Sema/SemaOpenM

[PATCH] D100514: [OpenMP] Added codegen for masked directive

2021-04-15 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/CodeGen/CGStmtOpenMP.cpp:3853-3855 + if (const auto *FilterClause = S.getSingleClause()) { +Filter = FilterClause->getThreadID(); + } No need for braces here Comment at: clang/test/Open

[PATCH] D100514: [OpenMP] Added codegen for masked directive

2021-04-15 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev accepted this revision. ABataev added a comment. This revision is now accepted and ready to land. LG Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100514/new/ https://reviews.llvm.org/D100514 ___

[PATCH] D100187: [OPENMP]Fix PR49115: Incorrect results for scan directive.

2021-04-16 Thread Alexey Bataev via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG10c7b9f64fa6: [OPENMP]Fix PR49115: Incorrect results for scan directive. (authored by ABataev). Repository: rG LLVM Github Monorepo CHANGES SINCE

[PATCH] D99689: [OPENMP]Add option -fopenmp-cuda-const-firstprivate to control address space of the corresponding global.

2021-04-16 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev updated this revision to Diff 338100. ABataev added a comment. Rebase + update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99689/new/ https://reviews.llvm.org/D99689 Files: clang/include/clang/Basic/LangOptions.def clang/include/clan

[PATCH] D99432: [OPENMP]Fix PR48851: the locals are not globalized in SPMD mode.

2021-04-16 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev updated this revision to Diff 338107. ABataev added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99432/new/ https://reviews.llvm.org/D99432 Files: clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp clang/test/OpenMP/nvptx_dist

[PATCH] D99530: [OPENMP]Fix PR49098: respect firstprivate of declare target variable.

2021-04-16 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev updated this revision to Diff 338111. ABataev added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99530/new/ https://reviews.llvm.org/D99530 Files: clang/lib/Sema/SemaOpenMP.cpp clang/test/OpenMP/target_firstprivate_c

[PATCH] D99436: [OPENMP]Fix PR49366: crash on VLAs in task untied regions.

2021-04-16 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev updated this revision to Diff 338114. ABataev added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99436/new/ https://reviews.llvm.org/D99436 Files: clang/include/clang/Basic/DiagnosticSemaKinds.td clang/include/clang/

[PATCH] D99350: [OPENMP]Fix PR49649: The introduction of $ref globals is not always valid.

2021-04-16 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev updated this revision to Diff 338116. ABataev added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99350/new/ https://reviews.llvm.org/D99350 Files: clang/lib/CodeGen/CGOpenMPRuntime.cpp clang/test/OpenMP/declare_targe

[PATCH] D99762: [OPENMP]Fix PR49777: Clang should not try to specialize orphaned directives in device codegen.

2021-04-16 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev updated this revision to Diff 338122. ABataev added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99762/new/ https://reviews.llvm.org/D99762 Files: clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp clang/lib/CodeGen/CGOpenMPRu

[PATCH] D100673: [OPENMP]Fix PR49698: OpenMP declare mapper causes segmentation fault.

2021-04-16 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev created this revision. ABataev added reviewers: jdoerfert, abhinavgaba, jyu2, mikerice. Herald added subscribers: guansong, yaxunl. ABataev requested review of this revision. Herald added subscribers: openmp-commits, sstefan1. Herald added projects: clang, OpenMP. The implicitly generated

[PATCH] D100673: [OPENMP]Fix PR49698: OpenMP declare mapper causes segmentation fault.

2021-04-16 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. In D100673#2695694 , @jdoerfert wrote: > Can we use the reproducer from the bug report, I want an outermost array > section with objects that have a declare mapper. Sure, will add. Comment at: openmp/libompt

[PATCH] D100673: [OPENMP]Fix PR49698: OpenMP declare mapper causes segmentation fault.

2021-04-16 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev updated this revision to Diff 338210. ABataev added a comment. Added repro from PR49698 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100673/new/ https://reviews.llvm.org/D100673 Files: clang/lib/CodeGen/CGOpenMPRuntime.cpp clang/test/

[PATCH] D100673: [OPENMP]Fix PR49698: OpenMP declare mapper causes segmentation fault.

2021-04-19 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. In D100673#2698168 , @protze.joachim wrote: > I tested the patch and still get wrong results (I modified the > `declare_mapper_nested_default_mappers_complex_structure.cpp` test to use my > verbose printf from bugzilla): > >

[PATCH] D100673: [OPENMP]Fix PR49698: OpenMP declare mapper causes segmentation fault.

2021-04-19 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev updated this revision to Diff 338624. ABataev added a comment. Fixes and rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100673/new/ https://reviews.llvm.org/D100673 Files: clang/lib/CodeGen/CGOpenMPRuntime.cpp clang/test/OpenMP/d

[PATCH] D100673: [OPENMP]Fix PR49698: OpenMP declare mapper causes segmentation fault.

2021-04-21 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: openmp/libomptarget/test/mapping/declare_mapper_nested_default_mappers_complex_structure.cpp:123-126 + assert(outer[1].arr[1].arr[0].data1 == 11 && + outer[1].arr[1].arr[0].data2 == 22 && + outer[1].arr[1].arr[1].data1

[PATCH] D100673: [OPENMP]Fix PR49698: OpenMP declare mapper causes segmentation fault.

2021-04-21 Thread Alexey Bataev via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG079884225a55: [OPENMP]Fix PR49698: OpenMP declare mapper causes segmentation fault. (authored by ABataev). Repository: rG LLVM Github Monorepo CH

[PATCH] D94185: [OpenMP][Docs] Mark finished features as done

2021-01-06 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev accepted this revision. ABataev added a comment. This revision is now accepted and ready to land. LG Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94185/new/ https://reviews.llvm.org/D94185 ___ c

[PATCH] D94315: [OpenMP][FIX] Enforce a function boundary for a new data environment

2021-01-08 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. In D94315#2487150 , @JonChesterfield wrote: > I'm guessing we're using the function boundary as a compiler barrier. That > seems fragile in the face of improving cross-function optimisation. Looks like applying inaccessiblemem_o

[PATCH] D94315: [OpenMP][FIX] Enforce a function boundary for a new data environment

2021-01-08 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. In D94315#2487242 , @jdoerfert wrote: > In D94315#2487164 , @ABataev wrote: > >> In D94315#2487150 , >> @JonChesterfield wrote: >> >>> I'm guessing

[PATCH] D94315: [OpenMP][FIX] Enforce a function boundary for a new data environment

2021-01-08 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. In D94315#2487257 , @jdoerfert wrote: > In D94315#2487244 , @ABataev wrote: > >> In D94315#2487242 , @jdoerfert >> wrote: >> >>> I don't understand

[PATCH] D94315: [OpenMP][FIX] Enforce a function boundary for a new data environment

2021-01-08 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev accepted this revision. ABataev added a comment. This revision is now accepted and ready to land. In D94315#2487643 , @jdoerfert wrote: > What we should do, as we move to the OpenMPIRBuilder, is to use runtime > interfaces that match OpenMP direct

[PATCH] D94871: [Clang][OpenMP] Fixed an issue that clang crashed when compiling OpenMP program in device only mode without host IR

2021-01-18 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/CodeGen/CGOpenMPRuntime.cpp:2944-2947 +// This could happen if the device compilation is invoked standalone. +if (!hasTargetRegionEntryInfo(DeviceID, FileID, ParentName, LineNum)) + initializeTargetRegionEntryInfo(

[PATCH] D94871: [Clang][OpenMP] Fixed an issue that clang crashed when compiling OpenMP program in device only mode without host IR

2021-01-18 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. Comment at: clang/lib/CodeGen/CGOpenMPRuntime.cpp:2944-2947 +// This could happen if the device compilation is invoked standalone. +if (!hasTargetRegionEntryInfo(DeviceID, FileID, ParentName, LineNum)) + initializeTargetRegionEntryInfo(Dev

[PATCH] D94871: [Clang][OpenMP] Fixed an issue that clang crashed when compiling OpenMP program in device only mode without host IR

2021-01-19 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/CodeGen/CGOpenMPRuntime.cpp:2944-2947 +// This could happen if the device compilation is invoked standalone. +if (!hasTargetRegionEntryInfo(DeviceID, FileID, ParentName, LineNum)) + initializeTargetRegionEntryInfo(

[PATCH] D94961: [OpenMP] Add OpenMP offloading toolchain skeleton for AMDGPU

2021-01-19 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. In D94961#2506460 , @JonChesterfield wrote: > This patch was written, roughly, by: > > - copying the known-working openmp driver from rocm into the trunk source tree > - deleting lots of stuff that didn't look necessary > - deleti

[PATCH] D94871: [Clang][OpenMP] Fixed an issue that clang crashed when compiling OpenMP program in device only mode without host IR

2021-01-19 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/CodeGen/CGOpenMPRuntime.cpp:2944-2947 +// This could happen if the device compilation is invoked standalone. +if (!hasTargetRegionEntryInfo(DeviceID, FileID, ParentName, LineNum)) + initializeTargetRegionEntryInfo(

[PATCH] D94871: [Clang][OpenMP] Fixed an issue that clang crashed when compiling OpenMP program in device only mode without host IR

2021-01-19 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/CodeGen/CGOpenMPRuntime.cpp:2944-2947 +// This could happen if the device compilation is invoked standalone. +if (!hasTargetRegionEntryInfo(DeviceID, FileID, ParentName, LineNum)) + initializeTargetRegionEntryInfo(

[PATCH] D91261: [OPENMP]Do not use OMP_MAP_TARGET_PARAM for data movement directives.

2021-01-19 Thread Alexey Bataev via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGb272698de790: [OPENMP]Do not use OMP_MAP_TARGET_PARAM for data movement directives. (authored by ABataev). Changed prior to commit: https://review

[PATCH] D111115: [OPENMP] Fix assert of "Unable to find base lambda address" from adjustMemberOfForLambdaCaptures.

2021-10-05 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/CodeGen/CGOpenMPRuntime.cpp:8451-8454 + ArrayRef MapModifiers; + ArrayRef MotionModifiers; + return getMapTypeBits( + I->getSecond(), MapModifiers, MotionModifiers, false, No need to cre

[PATCH] D111115: [OPENMP] Fix assert of "Unable to find base lambda address" from adjustMemberOfForLambdaCaptures.

2021-10-05 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/CodeGen/CGOpenMPRuntime.cpp:8923-8937 +// Extract map information. +for (const auto *C : Dir.getClausesOfKind()) { + if (C->getMapType() != OMPC_MAP_to) +continue; + for (auto L : C->component_lists())

[PATCH] D111115: [OPENMP] Fix assert of "Unable to find base lambda address" from adjustMemberOfForLambdaCaptures.

2021-10-05 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/CodeGen/CGOpenMPRuntime.cpp:8451-8454 + ArrayRef MapModifiers; + ArrayRef MotionModifiers; + return getMapTypeBits( + I->getSecond(), MapModifiers, MotionModifiers, false, ABataev wrote:

[PATCH] D111115: [OPENMP] Fix assert of "Unable to find base lambda address" from adjustMemberOfForLambdaCaptures.

2021-10-05 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. Tests with modifiers? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D15/new/ https://reviews.llvm.org/D15 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://l

[PATCH] D111115: [OPENMP] Fix assert of "Unable to find base lambda address" from adjustMemberOfForLambdaCaptures.

2021-10-06 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev accepted this revision. ABataev added a comment. This revision is now accepted and ready to land. LG Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D15/new/ https://reviews.llvm.org/D15 ___

[PATCH] D111316: [CFE][Codegen][In-progress] Remove CodeGenFunction::InitTempAlloca()

2021-10-11 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/CodeGen/CGOpenMPRuntime.cpp:4784 + CGF.Builder.CreateStore(llvm::ConstantInt::get(CGF.IntPtrTy, 0), + NumLVal.getAddress(CGF)); llvm::Value *PrevVal = CGF.EmitLoadOfScalar(NumLVal, E->ge

[PATCH] D71016: [SYCL] Implement OpenCL kernel function generation

2021-10-13 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/include/clang/Sema/Sema.h:12798 + /// Access to SYCL kernels. + SmallVectorImpl &getSYCLKernels() { return SYCLKernels; } + `ArrayRef getSYCLKernels()` Comment at: clang/lib/Sema/SemaSYCL.cpp:9

[PATCH] D112292: [Clang][OpenMP] Allow loop iteration var with threadprivate directive

2021-10-22 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:8653 ? (DSAStack->hasMutipleLoops() ? OMPC_lastprivate : OMPC_linear) -: OMPC_private; -if (((isOpenMPSimdDirective(DKind) && DVar.CKind != OMPC_unknown && -

[PATCH] D112292: [Clang][OpenMP] Allow loop iteration var with threadprivate directive

2021-10-22 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:8653 ? (DSAStack->hasMutipleLoops() ? OMPC_lastprivate : OMPC_linear) -: OMPC_private; -if (((isOpenMPSimdDirective(DKind) && DVar.CKind != OMPC_unknown && -

[PATCH] D112292: [Clang][OpenMP] Allow loop iteration var with threadprivate directive

2021-10-22 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:8653 ? (DSAStack->hasMutipleLoops() ? OMPC_lastprivate : OMPC_linear) -: OMPC_private; -if (((isOpenMPSimdDirective(DKind) && DVar.CKind != OMPC_unknown && -

[PATCH] D112292: [Clang][OpenMP] Allow loop iteration var with threadprivate directive

2021-10-22 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev accepted this revision. ABataev added a comment. This revision is now accepted and ready to land. LG with a nit. Comment at: clang/lib/Sema/SemaOpenMP.cpp:8658 !isOpenMPSimdDirective(DKind) && DVar.CKind != OMPC_unknown && + DVar.CKind != OMP

[PATCH] D108421: Mark openmp internal global dso_local

2021-08-20 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/CodeGen/CGOpenMPRuntime.cpp:2182-2189 + llvm::GlobalVariable *GV = new llvm::GlobalVariable( + CGM.getModule(), Ty, /*IsConstant*/ false, + llvm::GlobalValue::CommonLinkage, llvm::Constant::getNullValue(Ty), + E

[PATCH] D108421: Mark openmp internal global dso_local

2021-08-24 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. In D108421#2962151 , @lebedev.ri wrote: > In D108421#2961611 , @kamleshbhalui > wrote: > >> updated test and make changes local to auto generated global vars for lock. > > I do not under

[PATCH] D108421: Mark openmp internal global dso_local

2021-08-24 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. In D108421#2962199 , @lebedev.ri wrote: > In D108421#2962160 , @ABataev wrote: > >> In D108421#2962151 , @lebedev.ri >> wrote: >> >>> In D108421

[PATCH] D102449: [WIP][Clang][OpenMP] Add the support for compare clause in atomic directive

2021-08-24 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/include/clang/AST/StmtOpenMP.h:2797-2824 + enum DataPositionTy : size_t { +POS_X = 0, +POS_V, +POS_D, +POS_E, +POS_UpdateExpr, +POS_CondExpr, It is worth it to pre-commit these and related

[PATCH] D99436: [OPENMP]Fix PR49366: crash on VLAs in task untied regions.

2021-08-24 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev updated this revision to Diff 368393. ABataev added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99436/new/ https://reviews.llvm.org/D99436 Files: clang/include/clang/Basic/DiagnosticSemaKinds.td clang/include/clang/

[PATCH] D99350: [OPENMP]Fix PR49649: The introduction of $ref globals is not always valid.

2021-08-24 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev updated this revision to Diff 368405. ABataev added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99350/new/ https://reviews.llvm.org/D99350 Files: clang/lib/CodeGen/CGOpenMPRuntime.cpp clang/test/OpenMP/declare_targe

[PATCH] D108648: [Clang][OpenMP] Use enum to dereference children data array in OMPAtomicDirective

2021-08-24 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev accepted this revision. ABataev added a comment. This revision is now accepted and ready to land. LG Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D108648/new/ https://reviews.llvm.org/D108648 ___

[PATCH] D105297: [OPENMP]Fix PR50347: Mapping of global scope deep object fails.

2021-08-24 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev updated this revision to Diff 368426. ABataev added a comment. Herald added a subscriber: jfb. Rebase + update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D105297/new/ https://reviews.llvm.org/D105297 Files: clang/lib/CodeGen/CGOpenMPRu

[PATCH] D105151: [OPENMP]Fix PR50733: unexpected final value of list-item in linear clause in loop construct.

2021-08-24 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev updated this revision to Diff 368427. ABataev added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D105151/new/ https://reviews.llvm.org/D105151 Files: clang/lib/Sema/SemaOpenMP.cpp clang/test/OpenMP/for_linear_codegen.

[PATCH] D108774: [OpenMP][FIX] Allow declare variant to work with reference types

2021-08-26 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/AST/ASTContext.cpp:9691 // the expression is a function call (possibly inside parentheses). + if (LHS->getAs() && RHS->getAs()) +return mergeTypes(LHS->getAs()->getPointeeType(), Does it matter if it is

[PATCH] D108774: [OpenMP][FIX] Allow declare variant to work with reference types

2021-08-26 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev accepted this revision. ABataev added a comment. This revision is now accepted and ready to land. LG Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D108774/new/ https://reviews.llvm.org/D108774 ___

[PATCH] D108826: [SLP][LTO][WIP]Allow full SLP in LTO only at link time.

2021-08-27 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev created this revision. Herald added subscribers: hiraditya, inglorion. ABataev requested review of this revision. Herald added projects: clang, LLVM. Herald added subscribers: llvm-commits, cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D108826 Files: clang

[PATCH] D108826: [SLP][LTO][WIP]Allow full SLP in LTO only at link time.

2021-08-27 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. In D108826#2969471 , @lebedev.ri wrote: > I think there is something really wrong with vectorzer passes in LTO > pipelines. > Can you say whether the problem you are observing is in ThinLTO, Full LTO, or > both? I saw it in Fu

[PATCH] D108826: [SLP][LTO][WIP]Allow full SLP in LTO only at link time.

2021-08-27 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. In D108826#2969594 , @lebedev.ri wrote: > In D108826#2969547 , @ABataev wrote: > >> In D108826#2969471 , @lebedev.ri >> wrote: >> >>> I think th

[PATCH] D108826: [SLP][LTO][WIP]Allow full SLP in LTO only at link time.

2021-08-27 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. In D108826#2969677 , @spatel wrote: > In D108826#2969604 , @ABataev wrote: > >> In D108826#2969594 , @lebedev.ri >> wrote: >> >>> Aha, so full lt

[PATCH] D108826: [SLP][LTO][WIP]Allow full SLP in LTO only at link time.

2021-08-27 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. In D108826#2969701 , @nikic wrote: > @ABataev The pipeline already distinguishes between pre-link and post-link > optimization pipelines, see e.g. the flag that gets passed to LoopRotate to > control rotation of loops with calls

[PATCH] D109175: [openmp] Add clang cc1 option -fopenmp-skip-deferred-diags

2021-09-02 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. In D109175#2981054 , @jdoerfert wrote: > In D109175#2980905 , @weiwang wrote: > >> In D109175#2980900 , @jdoerfert >> wrote: >> >>> In D109175#29

[PATCH] D109255: [NFC][OpenMP] Add fsyntax-only to driver tests

2021-09-03 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. I think we can use just `clang_cc1` here instead of `%clang -c` Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D109255/new/ https://reviews.llvm.org/D109255 ___ cfe-commits mailing

[PATCH] D109255: [NFC][OpenMP] Add fsyntax-only to driver tests

2021-09-03 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev accepted this revision. ABataev added a comment. This revision is now accepted and ready to land. LG Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D109255/new/ https://reviews.llvm.org/D109255 ___

<    17   18   19   20   21   22   23   >