Seems the -fopenacc option is supported in both Clang and Flang. But Clang doesn’t generate parallel code for acc programs. Flang can only generate MLIR.
Where can I get the implementation status?
I don’t really have it published anywhere yet, so you’d have to look at commit history, which I know isn’t particularly useful.
Yes, the flag is supported in both compilers, and I cannot talk to the state of the Flang compiler (@clementval might be able to).
In Clang, we’re still working through the implementation. At the moment, I’m about 70% of the way through implementing the ‘semantic analysis’, though ZERO of the frontend codegen has been completed.
We are going to require MLIR/OpenACC-Dialect to have parallel code generated for OpenACC in Clang, so we’re blocked by the CIR upstreaming effort on getting the lowering working, but at least intend to start on that effort as “soon”.
We’re still likely a few releases of Clang away from having it functional.
There is currently no CodeGen in flang from OpenACC MLIR dialect. We have plan for it but as Erich mentioned we are also couple of releases away from having it fully implemented upstream.
@erichkeane @clementval Appreciate for your contribution.
Did you mean “There is currently no CodeGen in flang from OpenACC MLIR dialect” ?
Yes. Sorry I updated my reply
@clementval Does OpenACC parser and sema in flang currently support OpenACC3.3 or 3.2?
Parser and semantic are up to date with 3.3 specs. Let us know if you find any issue.
Any update on Clang + OpenACC? @erichkeane
@razvan.lupusoru has been working diligently to get the OpenACC lowering working, but I believe he’s concentrating on the Flang lowering at the moment.
There is likely some work that needs doing to get the lowering to be called in Clang (we haven’t done anything on it yet!), but there is definitely progress! Patches welcome if you’d like to enable it though, Clang doesn’t really have any optimizer-consumers for it yet, so there hasn’t been much of a ‘pull’ yet.