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

Better documentation for performance annotations #17700

Closed
wants to merge 6 commits into from

Conversation

lopezm94
Copy link

@lopezm94 lopezm94 commented Jul 29, 2016

That sentence might make you think applying it to a function will remove bounds check.

or even to a whole function

@inbounds function f(...)
    ...
end

which is not true as seen here

@kshyatt kshyatt added docs This change adds or pertains to documentation performance Must go faster labels Jul 29, 2016
@lopezm94
Copy link
Author

lopezm94 commented Jul 29, 2016

I think this pretty much sums up what I wasn't able to understand before.

@yuyichao @eschnett

@lopezm94 lopezm94 changed the title Remove confusing statement in performance-tips Better documentation for performance annotations Jul 29, 2016
Both :obj:`@simd` and :obj:`@inbounds` do a simple rewrite of the expression
and delegate the optimizations to compiler, much like ``:meta`` expressions.
This means they merely give the compiler license to optimize. Whether
it actually does so depends on the compiler. As consequence how you
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"As consequence" is not grammatical. Actually, I think you can just delete the "As consequence..." sentence.

@lopezm94
Copy link
Author

Thank you for the much needed corrections

@lopezm94
Copy link
Author

I think is ready for merging

@@ -932,6 +927,13 @@ On a computer with a 2.4GHz Intel Core i5 processor, this produces::
GFlop = 1.9467069505224963
GFlop (SIMD) = 17.578554163920018

Certain preconditions need to be met before using some of these macros.
Both :obj:`@simd` and :obj:`@inbounds` do a simple rewrite of the expression
and delegate the optimizations to compiler, much like ``:meta`` expressions.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

delegate the optimizations to the compiler

@tkelman
Copy link
Contributor

tkelman commented Jul 30, 2016

Please reopen this against master.

@stevengj
Copy link
Member

stevengj commented Aug 1, 2016

Note, for future reference, that it is better to do a forced push to an existing PR than to open a new PR.

@yuyichao
Copy link
Contributor

yuyichao commented Aug 1, 2016

Not when the target branch is wrong.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs This change adds or pertains to documentation performance Must go faster
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants