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

Re-write or remove the use of CACHELINE #128

Open
lundgren87 opened this issue Jun 23, 2022 · 0 comments
Open

Re-write or remove the use of CACHELINE #128

lundgren87 opened this issue Jun 23, 2022 · 0 comments

Comments

@lundgren87
Copy link
Member

CACHELINE is a hard-coded parameter in the MPI backend that can be roughly translated to number of pages (of size PAGE_SIZE) per ArgoDSM page for both cache-related operations and Pyxis (coherence) operations. This is currently untested due to being hard-coded, and I am certain that this does not work with all of our code, allocation policies in particular.

#ifndef CACHELINE
/** @brief Size of a ArgoDSM cacheline in number of pages */
#define CACHELINE 1L
#endif

I think the intended effects of CACHELINE are desirable in the sense of a tuning knob to trade false sharing for a reduction in remote operation. For workloads that access contiguous, large (in the sense of several pages or more), data appropriately divided between nodes, there is no such "false sharing". Using a larger PAGE_SIZE would for such workloads reduce the amount of remote operations without any significant drawbacks.

A proper implementation of this should not rely on repeatedly incorporating PAGE_SIZE*CACHELINE in the backend for all cache or coherence operations. One solution is to instead use an environment variable to set the page size in a controlled way (for example in powers of two hardware pages). Most, if not all of the calculations based on PAGE_SIZE should then be easily adaptable to a larger page size even in the current backend implementation.

Another alternative is to simply remove the CACHELINE parameter as it is currently of no use.

This was referenced Jun 23, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant