Attached to the mail, you will find the code.Compiled with PARI/GP 2-17-2 and GCC c=99.
Piercarlo Piercarlo da Iphone Inizio messaggio inoltrato:
On Mon, Jun 30, 2025 at 10:14:13AM +0000, Piercarlo Giannattasio wrote:Good morning,
I'm trying to code a prime number generator in a specified range, using GP
and C, and I need to reduce processing times.
What is a prime number generator ? How is it different from forprime ?I'm trying to use forprime and posix multithreading, but when executing the
code I'm exceeding the parisizemax. I've tried with 1-15 threads, assigning
16GB of memory only to PARI, but I still get the same error: sometimes it
only calculates the first iteration of forprime_next...
You need to set threadsizemax too.Also, is there any technical documentation for the C implementation, besides
the one I'm studying (User Guide, Tutorial, Introduction to gp2c,
Introduction to Parallel GP) ?
Thre are the libpari manual, the examples directory, and of course the PARI source code.But I suggest you send me your code, I will tell you what you need to read.Cheers,Bill.
|