11 Commits

Author SHA1 Message Date
Mats Petersson
d1f510cca8
Fix warning by removing unused variable (#81604)
Apparently, some compilers [correctly] warn that the variable that was
created prior to this change is unused.

This reemoves the variable.
2024-02-13 14:32:26 +00:00
Mats Petersson
b2b3a52485
Skip compiler directives between OMP PARALLEL DO and the loop (#81021)
This fixes a compilation error when code like this is presented to the
compiler:

  !$OMP PARALLEL DO
  !DIR$ VECTOR ALIGNED
  DO 20 i=1,N
     a = a + 0.5
20   CONTINUE

The directive itself is later ignored (with a warning that this is
happening), but because the compiler already errored out before that
point, it completely fails to compile this code. Other compilers accept
the code without complaints.
2024-02-09 18:05:51 +00:00
Ethan Luis McDonough
42df495114
[flang] OpenMP allocate directive parse tree fix
Addresses the same issue as the following abandoned revision: D104391.

Rewrite leading declarative allocations so they are nested within their respective executable allocate directive

Original:
ExecutionPartConstruct -> OpenMPDeclarativeAllocate
ExecutionPartConstruct -> OpenMPDeclarativeAllocate
ExecutionPartConstruct -> OpenMPExecutableAllocate

After rewriting:
ExecutionPartConstruct -> OpenMPExecutableAllocate
| ExecutionPartConstruct -> OpenMPDeclarativeAllocate
| ExecutionPartConstruct -> OpenMPDeclarativeAllocate

Reviewed By: kiranchandramohan

Differential Revision: https://reviews.llvm.org/D148409

Co-authored-by: Isaac Perry <isaac.perry@arm.com>
2023-05-05 15:50:49 -05:00
Ethan Luis McDonough
a6e616cdb1
Revert "[flang] OpenMP allocate directive parse tree fix"
This reverts commit 597d8563cd66f23d857196bf135a0c513115ece2.
2023-05-05 15:47:00 -05:00
Ethan Luis McDonough
597d8563cd
[flang] OpenMP allocate directive parse tree fix
Addresses the same issue as the following abandoned revision: D104391.

Rewrite leading declarative allocations so they are nested within their respective executable allocate directive

Original:
```
ExecutionPartConstruct -> OpenMPDeclarativeAllocate
ExecutionPartConstruct -> OpenMPDeclarativeAllocate
ExecutionPartConstruct -> OpenMPExecutableAllocate
```

After rewriting:
```
ExecutionPartConstruct -> OpenMPExecutableAllocate
| ExecutionPartConstruct -> OpenMPDeclarativeAllocate
| ExecutionPartConstruct -> OpenMPDeclarativeAllocate
```

Co-authored-by: Isaac Perry <isaac.perry@arm.com>

Reviewed By: kiranchandramohan

Differential Revision: https://reviews.llvm.org/D148409
2023-05-05 14:55:25 -05:00
Ethan Luis McDonough
936d40cdb5
Revert "[flang] OpenMP allocate directive parse tree fix"
This reverts commit 5faf45a3d24e603cbc8fe4eb45da386653dae5e5.
Once again arcanist stripped the co-author metadata.  I'm going to add it to the revision description and try one last time.
2023-05-05 14:50:14 -05:00
Ethan Luis McDonough
5faf45a3d2
[flang] OpenMP allocate directive parse tree fix
Addresses the same issue as the following abandoned revision: D104391.

Rewrite leading declarative allocations so they are nested within their respective executable allocate directive

Original:
```
ExecutionPartConstruct -> OpenMPDeclarativeAllocate
ExecutionPartConstruct -> OpenMPDeclarativeAllocate
ExecutionPartConstruct -> OpenMPExecutableAllocate
```

After rewriting:
```
ExecutionPartConstruct -> OpenMPExecutableAllocate
| ExecutionPartConstruct -> OpenMPDeclarativeAllocate
| ExecutionPartConstruct -> OpenMPDeclarativeAllocate
```

Reviewed By: kiranchandramohan

Differential Revision: https://reviews.llvm.org/D148409
2023-05-05 14:41:15 -05:00
Ethan Luis McDonough
c89959842f
Revert "[flang] OpenMP allocate directive parse tree fix"
This reverts commit eaf7d97865140a17f13ad77e5dc0216438127094.
Arcanist stripped co-author data from initial commit.
2023-05-05 14:31:01 -05:00
Ethan Luis McDonough
eaf7d97865
[flang] OpenMP allocate directive parse tree fix
Addresses the same issue as the following abandoned revision: D104391.

Rewrite leading declarative allocations so they are nested within their respective executable allocate directive

Original:
```
ExecutionPartConstruct -> OpenMPDeclarativeAllocate
ExecutionPartConstruct -> OpenMPDeclarativeAllocate
ExecutionPartConstruct -> OpenMPExecutableAllocate
```

After rewriting:
```
ExecutionPartConstruct -> OpenMPExecutableAllocate
| ExecutionPartConstruct -> OpenMPDeclarativeAllocate
| ExecutionPartConstruct -> OpenMPDeclarativeAllocate
```

Reviewed By: kiranchandramohan

Differential Revision: https://reviews.llvm.org/D148409
2023-05-05 13:53:11 -05:00
Tim Keith
1f8790050b [flang] Reformat with latest clang-format and .clang-format
Original-commit: flang-compiler/f18@9fe84f45d7
Reviewed-on: https://github.com/flang-compiler/f18/pull/1094
2020-03-28 21:00:16 -07:00
CarolineConcatto
64ab3302d5 [flang] [LLVMify F18] Compiler module folders should have capitalised names (flang-compiler/f18#980)
This patch renames the modules in f18 to use a capital letter in the
module name

Signed-off-by: Caroline Concatto <caroline.concatto@arm.com>

Original-commit: flang-compiler/f18@d2eb7a1c44
Reviewed-on: https://github.com/flang-compiler/f18/pull/980
2020-02-25 07:11:52 -08:00