The MCE Sandbox repository is where I try writing fast code using Perl MCE + Inline::C, Math::Prime::Util, and the C/C++ libprimesieve library. The demos and examples folders are new for the 2023 update. I learned Codon, a Python-like language that compiles to native code.
.Inline/ Where Inline::C is configured to cache C object file +s. bin/ algorithm3.pl Practical sieve based on Algorithm3 from Xuedong Luo + [1]. primesieve.pl Calls the primesieve.org C API for generating primes +. primeutil.pl Utilizes the Math::Prime::Util module for primes. demos/ primes1.c Algorithm3 in C with OpenMP directives. primes2.codon Algorithm3 in Codon, a Python-like language. primes3.c Using libprimesieve C API in C primes4.codon Using libprimesieve C API in Codon examples/ Progressive demonstrations. practicalsieve.c single big loop segmentsieve.c segmented variant, faster rangesieve.c process range; start stop prangesieve.c parallel rangesieve in C cpusieve.codon parallel rangesieve in Codon (CPU) gpusieve.codon parallel rangesieve in Codon (GPU) pgpusieve.codon using Codon @par(gpu=True) syntax cudasieve.cu using NVIDIA CUDA Toolkit lib/ Sandbox.pm Common code for the bin scripts. CpuAffinity.pm CPU Affinity support on Linux. src/ algorithm3.c Inline::C code for algorithm3.pl. bits.h Utility functions for byte array. output.h Fast printing of primes to a file descriptor. primesieve.c Inline::C code for primesieve.pl. sandbox.h Header file, includes bits.h, output.h, sprintull.h. sprintull.h Fast base10 to string conversion. typemap Type-map file for Inline::C.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: MCE Sandbox 2023-08
by marioroy (Prior) on Jan 23, 2024 at 13:00 UTC | |
Re: MCE Sandbox 2023-08
by karlgoethebier (Abbot) on Aug 28, 2023 at 12:30 UTC |