This is an archive of the discontinued LLVM Phabricator instance.

[flang] Add hlfir.declare codegen
ClosedPublic

Authored by jeanPerier on Nov 10 2022, 8:17 AM.

Details

Summary

hlfir.declare codegen generates a fir.declare, and may generate a
fir.embox/fir.rebox/fir.emboxchar if the base value does not convey
all the variable bounds and length parameter information.

Leave OPTIONAL as a TODO to keep this patch simple. It will require
making the embox/rebox optional to preserve the optionality aspects.

Depends on D137781

Diff Detail

Event Timeline

jeanPerier created this revision.Nov 10 2022, 8:17 AM
Herald added a project: Restricted Project. · View Herald Transcript
jeanPerier requested review of this revision.Nov 10 2022, 8:17 AM
clementval accepted this revision.Nov 11 2022, 1:41 AM

LGTM

flang/include/flang/Optimizer/Dialect/FortranVariableInterface.td
118
This revision is now accepted and ready to land.Nov 11 2022, 1:41 AM

Remove extra space before "?" in comments.

jeanPerier marked an inline comment as done.Nov 14 2022, 1:35 AM
This revision was automatically updated to reflect the committed changes.