[Flang][OpenMP] Fix loop index privatisation in Parallel region in HLFIR
HLFIR lowering always adds hlfir.declare when symbols are bound to their address allocated on the stack. Ensure that the declare is placed along with the alloca if it is hoisted. And always return the mlir value that is bound to the symbol (i.e the alloca in FIR lowering and the declare in HLFIR lowering). Context: Loop index variables in OpenMP parallel regions should be privatised to work correctly. Reviewed By: tblah Differential Revision: https://reviews.llvm.org/D158594
parent
b7f49156
Please register or sign in to comment