This is an archive of the discontinued LLVM Phabricator instance.

[flang][openacc] Initial reduction clause lowering
ClosedPublic

Authored by clementval on May 26 2023, 6:40 AM.

Details

Summary

Add initial support to lower reduction clause to its representation in MLIR.

This patch adds support for addition of integer and real scalar types. Other
operators and types will be added with follow up patches.

Diff Detail

Event Timeline

clementval created this revision.May 26 2023, 6:40 AM
Herald added projects: Restricted Project, Restricted Project. · View Herald TranscriptMay 26 2023, 6:40 AM
clementval requested review of this revision.May 26 2023, 6:40 AM
clementval added inline comments.May 26 2023, 6:56 AM
flang/lib/Lower/OpenACC.cpp
528–549

This is unrelated. I'll remove it.

razvanlupusoru accepted this revision.May 26 2023, 7:45 AM

Looks great. Thank you.

flang/include/flang/Lower/OpenACC.h
62

Spacing seems off - you might need to run clang-format

flang/lib/Lower/OpenACC.cpp
662

nitpicking: Please rephrase as "reduction with unsupported type". Since complex type has a specific meaning.

This revision is now accepted and ready to land.May 26 2023, 7:45 AM
clementval marked 2 inline comments as done.

Address review comments

razvanlupusoru accepted this revision.May 30 2023, 8:49 AM

Thank you!

This revision was automatically updated to reflect the committed changes.