PDF conversion restricted to a single thread

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
acozzette
Posts: 2
Joined: 2013-02-05T15:54:20-07:00
Authentication code: 6789

PDF conversion restricted to a single thread

Post by acozzette »

I am using JMagick 6.6.9 and ImageMagick 6.7.9-10 2013-01-27 Q16, built from source and running on Amazon Linux, to convert PDFs to PNGs. Although I'm using JMagick I thought I would ask the question here because I believe it pertains to ImageMagick specifically. I noticed that when I have multiple threads converting PDFs, only a single gs (Ghostscript) command ever runs at once, which led me to realize that ImageMagick is only allowing a single thread to proceed at a time, blocking the others. Judging from the output of "convert -version", I have OpenMP enabled:

$ convert -version
Version: ImageMagick 6.7.9-10 2013-01-27 Q16 http://www.imagemagick.org
Copyright: Copyright (C) 1999-2012 ImageMagick Studio LLC
Features: OpenMP

I've also tried setting MAGICK_THREAD_LIMIT to a value greater than one but have had no luck with that approach. Any ideas on how else I could enable multiple threads to perform the PDF conversion process in parallel? I would appreciate any suggestions.

Best,
Adam Cozzette
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: PDF conversion restricted to a single thread

Post by magick »

We can reproduce the problem you posted and have a patch in ImageMagick 6.8.2-5 Beta available by sometime tomorrow. Thanks.
acozzette
Posts: 2
Joined: 2013-02-05T15:54:20-07:00
Authentication code: 6789

Re: PDF conversion restricted to a single thread

Post by acozzette »

That's great, thanks!
Post Reply