LogoopenSUSE Build Service > Projects
Sign Up | Log In

Easily execute stuff in parallel

While every full-featured shell provides job control, it is only meant for manual, interactive handling of several jobs, and not much more. prll (pronounced "parallel") was created to simplify a common task of running a large number of jobs a few at a time. 

If you have a bunch of files to process, a loop is what you need. However, if you have a multicore/multiprocessor machine, it is much more efficient to run as many processes in parallel as there are CPUs available. While a minor extension to the loop might be adequate, it is not the most efficient solution.

prll is implemented as a shell function, with helper programs written in C. While there are other ways to tackle the problem, like using the xargs utility, and while many are "saner" in some sense, having a shell function has a distinct advantage: you don't need to write any scripts or programs. Implement your task as a shell function, and prll will run it using the context of your current shell. 

Summary of features:
* Easy to use. Focuses on a single task and doesn't try to emulate a kitchen sink.
* Code is passed in shell functions to ease interactive use.
* Works in both bash and zsh and in several operating systems.
* Execution can be terminated gracefully, letting started jobs finish their work.
* Can be terminated from within the code it executes, easing aborting on errors or implementing an ad-hoc parallel search.
* Does internal buffering and locking to prevent mangling/interleaving of output from separate jobs.

Source Files

Filename Size Changed Actions
prll-0.6.2.tar.bz2 37 KB about 5 years ago Download File
prll.spec 3.15 KB about 5 years ago Download File

Comments for home:zhonghuaren (0)

Login required, please login or signup in order to comment