The Multithreaded version of FORM
M. Tentyukov, J. A. M. Vermaseren
TL;DR
The paper introduces TFORM, a multithreaded version of FORM that leverages shared-memory parallelism via POSIX threads to accelerate symbolic computations. It details codebase cleanup to ensure thread-safety, the per-thread data model, and a master–worker parallelization strategy including bucketed work distribution and a centralized final sort. Through extensive benchmarks on chromatic polynomials, Feynman diagrams, and large systems of equations, the authors show substantial speedups (up to ~3× on 4 processors) with saturation effects due to master overhead and I/O. The work positions TFORM alongside ParFORM, highlighting comparable gains and outlining practical bottlenecks and avenues for future optimization, such as reworking the final sorting tree to reduce master load.
Abstract
We present TFORM, the version of the symbolic manipulation system FORM that can make simultaneous use of several processors in a shared memory architecture. The implementation uses Posix threads, also called pthreads, and is therefore easily portable between various operating systems. Most existing FORM programs will be able to take advantage of the increased processing power, without the need for modifications. In some cases some minor additions may be needed. For a computer with two processors a typical improvement factor in the running time is 1.7 when compared to the traditional version of FORM. In the case of computers with 4 processors a typical improvement factor in the execution time is slightly above 3.
