Thanks to all that have commented. The Linux perl's weren't build with -Duselongdouble and the GCC versions are the same (well, the major points are the same). The same CPU is being used, albeit with the Linux version running under VM. I have tried other machines/OS/GCC versions and I get the same results.
I have started to create smaller test cases. The following is a perl print out from the C structure when run under win32 (regardless of O level) and Linux (-O0) and Linux (regardless of O level) when ran via Valgrind:
170 : -25
171 : 9
172 : -28.0000000000005
173 : 25
174 : -156
175 : 26.0000000000005
176 : -50
177 : 34.0000000000005
178 : 36
179 : -10
180 : 22
181 : -70
The following is a perl print out from the C structure when ran under Linux when compiled with optimization (1,2 or 3):
170 : -25
171 : 8.99999999999963
172 : -28.0000000000001
173 : 25
174 : -156
175 : 26.0000000000005
176 : -50
177 : 34.0000000000003
178 : 37.0000000000005
179 : -10.0000000000001
180 : 21.9999999999999
181 : -70.0000000000003
I would expect to see differences of 0000000000003, but if you look at line 178 you'll notice a much larger difference and it's this that is causing the test script to fail. As yet, I dont know what is causing this difference...
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.