[fir] Update fir.alloca op
authorKiran Chandramohan <kiran.chandramohan@arm.com>
Thu, 30 Sep 2021 15:00:17 +0000 (17:00 +0200)
committerValentin Clement <clementval@gmail.com>
Thu, 30 Sep 2021 15:02:32 +0000 (17:02 +0200)
commit4cab4f6b1c089fe51d50b4b4d931976db64fecce
treef2f5ac9dd18a5ff0251d5b3d8105e5a5de7fdc28
parentc15bbdeafffb4a19f511671d1781a64bba638400
[fir] Update fir.alloca op

Add pinned attributes and speicifc builders.

The pinned attribute helps mark those allocas in OpenMP regions that should not
be hoisted out by an alloca hoisting pass.

This patch is part of the upstreaming effort from fir-dev branch.

Coming from PR: https://github.com/flang-compiler/f18-llvm-project/pull/1065

Reviewed By: kiranchandramohan

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

Co-authored-by: Valentin Clement <clementval@gmail.com>
flang/include/flang/Optimizer/Dialect/FIROps.td
flang/lib/Optimizer/Dialect/FIROps.cpp