PERF: Reorder header for philox#34
Merged
mattip merged 3 commits intomattip:randomgenfrom May 27, 2019
Merged
Conversation
Reorder header so that support uint128 is always used if avilable, irrespective of platform
Author
|
This patch improves performance on Win64 if built using ICC or Clang (I think, not verified) since they support uint128. |
mattip
reviewed
May 27, 2019
numpy/random/src/philox/philox.h
Outdated
| } | ||
|
|
||
| /* Prefer uint128 if available: GCC, clang, ICC */ | ||
| #if __SIZEOF_INT128__ |
Author
|
Thanks, fixed 2 places. |
mattip
reviewed
May 27, 2019
numpy/random/src/philox/philox.h
Outdated
Author
There was a problem hiding this comment.
This one doesn't work _Win64 is defined for 32 bit windows.
Use ifdef to detec uint128
390ecf4 to
8e0165d
Compare
mattip
reviewed
May 27, 2019
numpy/random/src/philox/philox.h
Outdated
| #include <intrin.h> | ||
| /* TODO: This isn't correct for many platforms */ | ||
| #ifdef _WIN64 | ||
| #ifdef _WIN64 && _M_AMD64 |
Owner
There was a problem hiding this comment.
Sorry, I should have been more explicit: #if defined(_WIN64) && defined(_M_AMD64) which will work even if they have values that will fail for && like 2 and 1: 2 && 1 -> 0
Owner
|
thanks |
mattip
pushed a commit
that referenced
this pull request
May 27, 2019
* PERF: Reorder header for philox Reorder header so that support uint128 is always used if avilable, irrespective of platform
mattip
pushed a commit
that referenced
this pull request
Nov 15, 2023
Merge in ~STEPAN.SINDELAR_ORACLE.COM/numpy-hpy from fa/fix_universal_crashes to labs-hpy-port * commit '3e21b1a35e92fa196650a9a4cf6c438337b5342f': Migrate is_known_scalar_type_function Correctly convert to/from HPyArrayMethod_Context
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Reorder header so that support uint128 is always used if available, irrespective of platform