Closed Bug 408258 Opened 17 years ago Closed 12 years ago

[valgrind] scriptableIO.xul test failures valgrind errors when compiled with bug 407794 settings

Categories

(Core :: General, defect)

x86
Linux
defect
Not set
normal

Tracking

()

RESOLVED WONTFIX

People

(Reporter: sayrer, Unassigned)

References

(Blocks 1 open bug)

Details

(Keywords: valgrind)

Attachments

(2 files)

This can be reproduced by running perl runtests.pl --chrome, and visiting the scriptableIO.xul test. CCing roc, because there are also textrun warnings present in the valgrind log.
Attached file valgrind log
Attachment #293005 - Attachment is patch: false
Blocks: 407794
It looks like some uninitialized data gets set as text hereabouts: ==4592== Conditional jump or move depends on uninitialised value(s) ==4592== at 0x168F61A1: nsTextFragment::SetTo(unsigned short const*, int) (in /home/sayrer/dev/opt_firefox/mozilla/layout/build/libgklayout.so) And then later we reflow and render it and that causes cascading warnings in text rendering code. In fact the root cause is probably earlier because the warnings above look like JS converting some uninitialized number to a string. Let's figure out what the initial problem is and then we can see what's left over after that's fixed.
OK, so without the patch in 407794 applied, we're building the unit test box with "-O"... and missing a bunch of optimizations. With that patch applied, the settings are the same, which is preferable. The nightlies and releases are probably hitting this, so requesting blocking.
Flags: blocking1.9?
Attached file warnings
These warnings in the streams code cause the bug. If we compile with -fno-strict-aliasing (and give up those optimizations), it works as expected.
This might also explain the issues that the binary input streams unit tests ran into? We might want to fix this in both, since the latter are used by fastload, which might in fact hit the bugs in question...
Flags: blocking1.9? → blocking1.9+
I wallpapered this in bug 407794, so we would stop shipping it in nightlies.
Blocks: 403783
Version: unspecified → Trunk
Keywords: valgrind
Flags: blocking1.9+
There might be a trick for compiling without -fno-strict-aliasing and still getting this right (I didn't test though). According to the comment, it doesn't seem to hurt too much performance wise. http://www.google.com/codesearch/p?hl=en#h0RrPvyPu-c/base/basictypes.h&l=265
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → WONTFIX
Neil, why was this wontfixed?
scriptableIO hasn't been around for a long time, so this bug isn't needed.
Blocks: 900714
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: