[flang-commits] [PATCH] D133174: [flang] Add atomic_fetch_or to the list of intrinsics
Katherine Rasmussen via Phabricator via flang-commits
flang-commits at lists.llvm.org
Thu Sep 1 18:01:55 PDT 2022
ktras added a comment.
In this patch, in `flang/lib/Evaluate/intrinsics.cpp`, I would like to be able to bring in and use the value `atomic_int_kind` from the `iso_fortran_env` module. I have drafted my solution in this patch where I declare a variable with the value of `atomic_int_kind` but with the `bind(c)` attribute in a new Fortran module and then use an `extern int` in a `.h` file to theoretically grab that value. However, I have not done much Fortran/C interoperability and am not sure how to do the right CMake changes to make my idea work. At the moment, I commented out the `extern int` and am just using a magic number. Would anyone be able to help me figure out how to make the right CMake changes so I can use that `extern int`? Or is there a totally different and better way to get a value equivalent to `atomic_int_kind` that is not a magic number?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D133174/new/
https://reviews.llvm.org/D133174
More information about the flang-commits
mailing list