[OMPIRBuilder] Add support for simd (loop) directive.
authorArnamoy Bhattacharyya <arnamoy.bhattacharyya@huawei.com>
Wed, 19 Jan 2022 16:18:35 +0000 (11:18 -0500)
committerArnamoy Bhattacharyya <arnamoy.bhattacharyya@huawei.com>
Wed, 19 Jan 2022 16:32:17 +0000 (11:32 -0500)
commit9fbd33ad623d2b576fc563545bbdf2c257cdf709
tree8958007f27f0264b0d6e830a6a574e3815ee9690
parent8e53ae3d37190c7442f87915a49f3f292d1d9956
[OMPIRBuilder] Add support for simd (loop) directive.

This patch adds OMPIRBuilder support for the simd directive (without any clause).  This will be a first step towards lowering simd directive in LLVM_Flang.  The patch uses existing CanonicalLoop infrastructure of IRBuilder to add the support.  Also adds necessary code to add llvm.access.group and llvm.loop metadata wherever needed.

Reviewed By: Meinersbur

Differential Revision: https://reviews.llvm.org/D114379
clang/lib/CodeGen/CGStmtOpenMP.cpp
clang/test/OpenMP/irbuilder_simd.cpp [new file with mode: 0644]
llvm/include/llvm/Frontend/OpenMP/OMPIRBuilder.h
llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp
llvm/unittests/Frontend/OpenMPIRBuilderTest.cpp