Add OpenMP parallel declarations and iterable handling - #75
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| use_openmp <- isTRUE(attr(fsub@scope, "uses_openmp", exact = TRUE)) | ||
| env <- quickr_fcompiler_env( | ||
| build_dir = build_dir, | ||
| use_openmp = use_openmp | ||
| ) |
There was a problem hiding this comment.
Fallback build drops requested OpenMP flags
When declare(parallel()) is used, compile() now sets use_openmp and feeds quickr_fcompiler_env() so that the first build uses OpenMP-specific Makevars (lines 219‑223). If that build fails because the toolchain lacks OpenMP support, the fallback system2() call immediately recompiles without env, so the shared object is produced with OpenMP directives treated as comments. This silently ignores the user’s request for parallelization and can make availability checks (e.g. openmp_supported_or_skip()) report success while loops run serially instead of erroring. The fallback should be disabled or the original failure propagated whenever OpenMP was requested.
Useful? React with 👍 / 👎.
Welcome to Codecov 🎉Once you merge this PR into your default branch, you're all set! Codecov will compare coverage reports and display results in all future pull requests. Thanks for integrating Codecov - We've got you covered ☂️ |
Summary