[Insight-developers] Fwd: Histogramtest

Bill Hoffman bill . hoffman at kitware . com
Tue, 03 Sep 2002 11:44:40 -0400


Yes, and also the sun with gcc 2.95.

-Bill


At 08:39 AM 9/3/2002 -0700, Jisung Kim wrote:

>I'll make the size variable to const one.
>Is this a problem for OSX and gcc 3.x?
>
>Thank you,
>
>Jisung
>--- Bill Hoffman <bill.hoffman@kitware.com> wrote:
>> Here is the remaining crash.
>> 
>> Looks like the compiler generated Size copy
>> constructor is not working. 
>> I am having him try changing these to SizeType
>> const& size, there is no
>> reason to copy here.
>> 
>> -Bill
>> 
>> >Date: Tue, 3 Sep 2002 14:23:09 +0200
>> >Subject: Histogramtest
>> >From: Jon Harald Kaspersen <kaspersen@mac.com>
>> >To: William Hoffman <bill.hoffman@kitware.com>
>> >X-Mailer: Apple Mail (2.543)
>> >
>> >Hi Bill, 
>> >
>> >we have discovered that the malloc error in the
>> histogram test may be a compiler bug. 
>> >
>> >We checked the backtrace and found that the error
>> occurs in itkHistogram.txx: 
>> >
>> >In Initialize(SizeType size, MeasurementVectorType
>> lowerBound, 
>> >             MeasurementVectorType upperBound),
>> which is called by the itkHistogramTest, the
>> Initialize(SizeType size) is called, passing the
>> size parameter further to the Initialize(size)
>> function. What happens then is interesting. 
>> >
>> >By inserting 
>> >
>> >std::cout << "Size: " << size << "\n"; 
>> >
>> >as the first line in each of the functions, the
>> following output is generated: 
>> >
>> >Size: [64, 64, 64] 
>> >Size: [3221223168, 3221223492, 583320] 
>> >
>> >
>> >
>>
>>========================================================
>> 
>> >Jon Harald Kaspersen                    Tel:       
>>     +47 73 59 75 89 
>> >Ph.D. Mechanical Engineering            Mob:       
>>     +47 93 03 65 90 
>> >Senior Scientist                               
>> Pager   +47 96 84 29 94 
>> >SINTEF Unimed - Ultralyd                Fax:       
>>     +47 73 59 78 73 
>> >N-7465 Trondheim 
>> >NORWAY                  e-mail:
>> Jon.H.Kaspersen@unimed.sintef.no 
>> >                                WEB:   
>>
><http://www.us.unimed.sintef.no/>http://www.us.unimed.sintef.no/
>> 
>>
>>========================================================
>> </blockquote></x-html> 
>> 
>
>
>=====
>Jisung Kim
>bahrahm@yahoo.com
>106 Mason Farm Rd.
>129 Radiology Research Lab., CB# 7515
>Univ. of North Carolina at Chapel Hill
>Chapel Hill, NC 27599-7515
>
>__________________________________________________
>Do You Yahoo!?
>Yahoo! Health - Feel better, live better
>http://health.yahoo.com
>_______________________________________________
>Insight-developers mailing list
>Insight-developers@public.kitware.com
>http://public.kitware.com/mailman/listinfo/insight-developers