vermaseren / form

The FORM project for symbolic manipulation of very big expressions
GNU General Public License v3.0
982 stars 118 forks source link

Can't set tform worker count from the source file, setfile, or an environment variable #329

Open magv opened 4 years ago

magv commented 4 years ago

Hi, folks. The docs for FORM 4.2.1 list the following three ways of changing the number of workers for tform:

It is also possible to specify the number of worker threads in the setup file, using the line

Threads 4

for 4 threads. And as with all setup parameters one can pass this information also via the environment variable FORM_threads or with the line

: Threads 4

at the beginning of the program file.

None of these three methods work, according to my tests.

Only passing '-w4' to tform on the command line actually has any effect.


I've investigated the reason, and it looks to me that the part of setfile.c that is responsible for changing AM.totalnumberofthreads after parsing the "threads" setting is commented out: see setfile.c:359. It was commented out 13 years ago in this commit.

In any case, could you folks restore the proper behavior?