Closed Bug 773056 Opened 12 years ago Closed 11 years ago

Disable aslr when running the GC rooting analysis

Categories

(Release Engineering :: General, defect, P5)

x86_64
Linux
defect

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: terrence, Assigned: sfink)

Details

Attachments

(2 files)

It is important that these tests be reproducible.
I don't know what this means. What needs changing?
Priority: -- → P3
ASLR is "Address Space Layout Randomization".  With this on, malloc hands out different addresses on every execution.  The upshot is that addresses will not be stable between runs, which will make debugging oranges more difficult than it should be.

ASLR has to be turned off either on the full system, or by the process that does the forking.  This is why I have not formatted a patch for this yet: it may turn out to be difficult with our current setup.  As a fallback, we can always just refork internally in the JS shell with an argument, but I wanted to see if we can do it in the test harness first.
Priority: P3 → --
Priority: -- → P5
Looks like there's already a simple command to do this (setarch).
Attachment #752722 - Flags: review?(bhearsum)
Assignee: nobody → sphink
Comment on attachment 752722 [details] [diff] [review]
Disable ASLR for spidermonkey shell tests

Review of attachment 752722 [details] [diff] [review]:
-----------------------------------------------------------------

stampy stamp stamp
Attachment #752722 - Flags: review?(bhearsum) → review+
\o/ Nice find! With any luck the new, deterministic memory ordering will not turn SM(r) perma-orange ;-).
Priority: P5 → --
Priority: -- → P5
Attachment #752722 - Flags: checked-in+
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Comment on attachment 752722 [details] [diff] [review]
Disable ASLR for spidermonkey shell tests

Backed out in https://hg.mozilla.org/build/tools/rev/9fbc9adbd523 - the only remaining working Mac spidermonkey job says, https://tbpl.mozilla.org/php/getParsedLog.php?id=23338627&tree=Mozilla-Inbound, "what is this setarch of which you speak?"
Attachment #752722 - Flags: checked-in+ → checked-in-
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
The setarch command is linux only, as are our root analysis builds. I expect this wasn't meant to -- and shouldn't(!) -- leak out to all the other spidermonkey jobs.
Another try. Note that it's possible to disable ASLR on osx too, but the most reliable way seems to be to turn off a magic MH_PIE bit on the executable, and it turns out we really only need this for rootanalysis builds that are currently only on Linux anyway.
Attachment #754001 - Flags: review?(bhearsum)
Attachment #754001 - Flags: review?(bhearsum) → review+
Attachment #754001 - Flags: checked-in+
I at least ran spidermonkey.sh locally this time. Not that that would have caught the previous error.

http://hg.mozilla.org/build/tools/rev/fc0b79da069d
Status: REOPENED → RESOLVED
Closed: 11 years ago11 years ago
Resolution: --- → FIXED
Product: mozilla.org → Release Engineering
Component: General Automation → General
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: