This file contains 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
// prime calculation based on https://gist.github.com/rongjiecomputer/d52f34d27a21b8c9c9e82ca85b806640 | |
// add increase limits or it wont compile for sieveSize = 1000000 -fconstexpr-loop-limit=2000000 -fconstexpr-ops-limit=335544320 | |
// use debug build. | |
// release build will optimize most of the loop away. | |
#include <chrono> | |
#include <iostream> | |
#include <numeric> | |
#include <span> | |
#include <stdio.h> |