Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation issues #122

Open
antoine-levitt opened this issue Feb 15, 2022 · 1 comment
Open

Documentation issues #122

antoine-levitt opened this issue Feb 15, 2022 · 1 comment

Comments

@antoine-levitt
Copy link

FLoops.jl 0.2 defaults to a parallel loop; i.e., it uses a parallel executor (e.g., ThreadedEx) when the executor is not specified and the explicit sequential form @floop begin ... end is not used.

That is to say, @floop without @reduce such as

@floop for i in eachindex(ys, xs)
    ys[i] = f(xs[i])
end

is now executed in parallel by default.

looks like it implies that with a @reduce it doesn't?

  • The doc sometimes talks about @reduce() do end and sometimes about @reduce and @init. Is the latter new syntax for the former?
@tkf
Copy link
Member

tkf commented Feb 15, 2022

I guess I can clarify it by saying

@floop even without @reduce

or something.

I don't remember if I implemented only @reduce() do first or I had @reduce acc += x from the getgo. @init is relatively new.

Current documentation is embarrassingly sparse. Probably these tutorials are actually better at explaining the API:
https://juliafolds.github.io/data-parallelism/tutorials/quick-introduction/#manual_reductions
https://juliafolds.github.io/data-parallelism/tutorials/concurrency-patterns/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants