[Insight-developers] itkWarningMacro not thread safe?

Bradley Lowekamp blowekamp at mail.nih.gov
Wed May 2 12:53:17 EDT 2012


Sorry, I prematurely hit the send button by mistake.

I was going to go on to say that I don't have a good grasp of all the different Outputs and loggers and other display text like things that are in ITK, neither why they are all needed or which one to choose. Kris Zygmunt recently said she uses the logger for debug output because the output is multi-thread coherent, and not intermixed.

I think that these methods should be concurrent thread safe.

Brad


On May 2, 2012, at 12:48 PM, Bradley Lowekamp wrote:

> Hello Kent,
> 
> I have expected that method to be concurrent thread safe. That's impressive you were able to track that down. This would also mean that the DebugMacro is not thread safe either, which I would be quite surprised about. 
> 
> 
> 
> 
> On May 2, 2012, at 12:38 PM, Williams, Norman K wrote:
> 
>> I was trying to chase down an intermittent bug in one of our programs,
>> BRAINSTransformConvert.
>> 
>> Without going into my particular issue too much, the problem is that
>> BSplineDeformableTransform::TransformPoint prints out an warning message
>> using itkWarningMacro, and the underlying print mechanism --
>> itk::OutputWindow -- is apparently not thread safe.
>> 
>> I logged a Jira ticket about it and will submit a patch
>> https://itk.icts.uiowa.edu/jira/secure/EditIssue!default.jspa?id=18327
>> 
>> My question is this: Is it reasonable to expect that itkWarningMacro (and
>> behind the scenes itk::OutputWindow) be callable from a multithreaded
>> filter?  If so, could itk::OutputWindow be made thread-safe?
>> 
>> --
>> Kent Williams norman-k-williams at uiowa.edu
>> 
>> 
>> 
>> 
>> 
>> 
>> ________________________________
>> Notice: This UI Health Care e-mail (including attachments) is covered by the Electronic Communications Privacy Act, 18 U.S.C. 2510-2521, is confidential and may be legally privileged.  If you are not the intended recipient, you are hereby notified that any retention, dissemination, distribution, or copying of this communication is strictly prohibited.  Please reply to the sender that you have received the message in error, then delete it.  Thank you.
>> ________________________________
>> _______________________________________________
>> Powered by www.kitware.com
>> 
>> Visit other Kitware open-source projects at
>> http://www.kitware.com/opensource/opensource.html
>> 
>> Kitware offers ITK Training Courses, for more information visit:
>> http://kitware.com/products/protraining.php
>> 
>> Please keep messages on-topic and check the ITK FAQ at:
>> http://www.itk.org/Wiki/ITK_FAQ
>> 
>> Follow this link to subscribe/unsubscribe:
>> http://www.itk.org/mailman/listinfo/insight-developers
> 
> ========================================================
> Bradley Lowekamp  
> Medical Science and Computing for
> Office of High Performance Computing and Communications
> National Library of Medicine 
> blowekamp at mail.nih.gov
> 
> 
> 

========================================================
Bradley Lowekamp  
Medical Science and Computing for
Office of High Performance Computing and Communications
National Library of Medicine 
blowekamp at mail.nih.gov



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-developers/attachments/20120502/0453e9df/attachment.htm>


More information about the Insight-developers mailing list