magick wrote:We disabled OpenMP for SampleImage() only in the current release, 6.5.5-1. We recommend you download it and leave OpenMP enabled. The deadlock problem should be resolved.
Unfortunately, it looks like there was nothing special about SampleImage that was causing a deadlock. The problem has moved and now I have a deadlock between two threads, but in two slightly different places:
Code: Select all
#0 0xb69cf823 in ?? () from /usr/lib/libgomp.so.1
#1 0xb69cf87f in ?? () from /usr/lib/libgomp.so.1
#2 0xb69ce8ae in ?? () from /usr/lib/libgomp.so.1
#3 0xb6d33076 in VerticalFilter (resize_filter=0xb4ad78f8, image=0xb4ad11e0, resize_image=0xb068acb0, y_factor=0.20000000000000001, span=188, quantum=0xb40a1c20, exception=0xb2ab2788)
at magick/resize.c:1903
#4 0xb6d3425e in ResizeImage (image=0xb4ad11e0, columns=4294966784, rows=4294966784, filter=UndefinedFilter, blur=1, exception=0xb2ab2788) at magick/resize.c:2231
#5 0xb6d34555 in ZoomImage (image=0xb4ad11e0, columns=82, rows=106, exception=0xb2ab2788) at magick/resize.c:3012
#6 0xb6d34c0a in ThumbnailImage (image=0xb2aaf5c0, columns=82, rows=106, exception=0xb2ab2788) at magick/resize.c:2906
#7 0xb37b4258 in WritePDFImage (image_info=0xaccb3108, image=0xb2aaf5c0) at coders/pdf.c:1792
#8 0xb6c53476 in WriteImage (image_info=0xacaf9e28, image=0xb2aaf5c0) at magick/constitute.c:1125
#9 0xb8089352 in Magick::Image::write (this=0xb40ac208, imageSpec_=@0xb40ac21c) at Magick++/lib/Image.cpp:2083
#10 0x080704ea in image2pdf
and
Code: Select all
#0 0xb69cf823 in ?? () from /usr/lib/libgomp.so.1
#1 0xb69cf87f in ?? () from /usr/lib/libgomp.so.1
#2 0xb69ce8ae in ?? () from /usr/lib/libgomp.so.1
#3 0xb6d33eb6 in HorizontalFilter (resize_filter=0xc389208, image=0xb13e688, resize_image=0x9f74390, x_factor=0.20000000000000001, span=188, quantum=0xaebe9c20, exception=0xcf437e0) at magick/resize.c:1903
#4 0xb6d34293 in ResizeImage (image=0xe9b4ed8, columns=4294966784, rows=4294966784, filter=UndefinedFilter, blur=1, exception=0xcf437e0) at magick/resize.c:2233
#5 0xb6d34555 in ZoomImage (image=0xe9b4ed8, columns=82, rows=106, exception=0xcf437e0) at magick/resize.c:3012
#6 0xb6d34c0a in ThumbnailImage (image=0xcf40618, columns=82, rows=106, exception=0xcf437e0) at magick/resize.c:2906
#7 0xb37b4258 in WritePDFImage (image_info=0xa9433a0, image=0xcf40618) at coders/pdf.c:1792
#8 0xb6c53476 in WriteImage (image_info=0xa93b388, image=0xcf40618) at magick/constitute.c:1125
#9 0xb8089352 in Magick::Image::write (this=0xaebf4208, imageSpec_=@0xaebf421c) at Magick++/lib/Image.cpp:2083
#10 0x080704ea in image2pdf
So it seems that its a general issue with OpenMP rather than something specifically wrong with one code path. Maybe OpenMP isn't thread safe in the way that I'm using it?