[PATCH] D91159: [flang]Add Semantic Checks for Allocate Directive

Kiran Chandramohan via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 16 10:57:40 PST 2020


kiranchandramohan added a comment.

I) Are you handling only a subset of the restrictions here? I see the following in,

1. General restrictions.

-> allocate directives that appear in a target region must specify an allocator clause unless a requires directive with the dynamic_allocators clause is present in the same compilation unit.

2. Fortran specific restrictions.

-> List items specified in the allocate directive must not have the ALLOCATABLE attribute unless the directive is associated with an allocate statement.
-> List items specified in an allocate directive that is associated with an allocate statement must be variables that are allocated by the allocate statement.
-> Multiple directives can only be associated with an allocate statement if list items are specified on each allocate directive.
-> If a list item has the SAVE attribute, is a common block name, or is declared in the scope of a module, then only predefined memory allocator parameters can be used in the allocator clause.
-> A type parameter inquiry cannot appear in an allocate directive.

Since the requires directive is not there I am assuming that only a subset of the check in the general restrictions can be checked now.
Please provide a clarification saying that only a subset of checks are implemented or implement the above checks.

II) A few files have no newline at end of file.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D91159/new/

https://reviews.llvm.org/D91159



More information about the llvm-commits mailing list