mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-10-19 11:02:59 +02:00
[Flang][openmp][1/5] Make Allocate clause part of OmpClause
After discussion in `D93482` we found that the some of the clauses were not following the common OmpClause convention. The benefits of using OmpClause: - Functionalities from structure checker are mostly aligned to work with `llvm::omp::Clause`. - The unparsing as well can take advantage. - Homogeneity with OpenACC and rest of the clauses in OpenMP. - Could even generate the parser with TableGen, when there is homogeneity. - It becomes confusing when to use `flangClass` and `flangClassValue` inside TableGen, if incase we generate parser using TableGen we could have only a single `let expression`. This patch makes `allocate` clause part of `OmpClause`.The unparse function for `OmpAllocateClause` is adapted since the keyword and parenthesis are issued by the corresponding unparse function for `parser::OmpClause::Allocate`. Reviewed By: clementval Differential Revision: https://reviews.llvm.org/D93640
This commit is contained in:
parent
cffdb541a0
commit
5a58d3eafe
@ -254,7 +254,7 @@ def OMPC_AtomicDefaultMemOrder : Clause<"atomic_default_mem_order"> {
|
||||
}
|
||||
def OMPC_Allocate : Clause<"allocate"> {
|
||||
let clangClass = "OMPAllocateClause";
|
||||
let flangClass = "OmpAllocateClause";
|
||||
let flangClassValue = "OmpAllocateClause";
|
||||
}
|
||||
def OMPC_NonTemporal : Clause<"nontemporal"> {
|
||||
let clangClass = "OMPNontemporalClause";
|
||||
|
Loading…
Reference in New Issue
Block a user