>   The order you call the register routines should not matter. Only the order 
> they are listed in the struct matters. Did you get something breaking if you 
> didn't call the register routines in order?

Yes, originally I fixed the problem just by changing the order of the register 
calls.

Bizarrely, I can't recreate the error now, regardless of the order of the 
entries in the struct or the order of the register calls.

This goes for my test-code as well as src/sys/examples/tutorials/ex5.c

I have pulled and recompiled petsc-dev since submitting that issue to 
petsc-maint

Rich



> 
>   I know the ascii view prints "incorrect" values. This is a universal 
> problem with working with quad precision. C provides no portable (or even 
> nonportable) way of handling format statements for different precisions 
> builds. 
> 
>   Unless Jed figures out a way to do it the current model is that with quad 
> they are printed wrong and you need to manage their display yourself.
> 
>   Barry
> 
> I try to handle the problem with %G format that we manually map to different 
> "standard" C formats, but quad doesn't have a "standard" C format that works.
> 
> 
> On Mar 24, 2011, at 12:30 PM, Richard Katz wrote:
> 
>> Attached is a diff file updating 
>> src/sys/examples/tutorials/ex5.c
>> which is an example of PetscBag use.
>> 
>> I've changed the order of the parameter registrations to put the Real values 
>> first, as required with quad precision.
>> 
>> If you run the new version with quad precision, you'll see that when the bag 
>> is viewed to stdout, the Real numerical values are incorrectly displayed.
>> 
>> Cheers
>> Rich
>> 
>> 
>> <ex5.diff>
> 

________________________________
Richard Foa Katz
Dept Earth Sciences, Univ Oxford
http://www.earth.ox.ac.uk/katz


Reply via email to