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

default cache line size #10

Merged
merged 2 commits into from
Aug 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion inc/mkn/avx/lazy.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include <new>
#include <tuple>
#include <vector>
#include <cstdint>

namespace mkn::avx
{
Expand Down Expand Up @@ -225,7 +226,11 @@ struct LazyEvaluator
}
};

auto const cl_size = std::hardware_destructive_interference_size;
#ifdef __cpp_lib_hardware_interference_size
std::size_t const cl_size = std::hardware_destructive_interference_size;
#else
std::size_t constexpr cl_size = 64;
#endif

std::size_t const batch = cl_size / sizeof(T) / N;

Expand Down
2 changes: 1 addition & 1 deletion mkn.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ profile:

- name: test
parent: headers
main: test/test.cpp
test: test/test_(\w).cpp
mode: none

- name: bench
Expand Down
File renamed without changes.