The default bug view has changed. See this FAQ.

Crash on s390x (nsXPCComponents::AttachNewComponentsObject() fails).

RESOLVED FIXED in mozilla11

Status

()

Core
XPConnect
RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: Martin Stránský, Assigned: Martin Stránský)

Tracking

8 Branch
mozilla11
Other
Linux
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment, 1 obsolete attachment)

v2
2.62 KB, patch
glandium
: review+
Details | Diff | Splinter Review
(Assignee)

Description

5 years ago
On s390x, the nsXPCComponents::AttachNewComponentsObject() fails in optimized builds, it causes xpcshell crash and firefox fails to build there. s390 works fine.

###!!! ASSERTION: This is not supposed to fail!: 'Error', file /root/rpmbuild/BUILD/xulrunner-8.0/mozilla-release/js/src/xpconnect/src/nsXPConnect.cpp, line 984
###!!! ASSERTION: Failed to initialize nsScriptSecurityManager: 'NS_SUCCEEDED(rv)', file /root/rpmbuild/BUILD/xulrunner-8.0/mozilla-release/caps/src/nsScriptSecurityManager.cpp, line 3455
WARNING: NS_ENSURE_TRUE(sPreferences) failed: file /root/rpmbuild/BUILD/xulrunner-8.0/mozilla-release/modules/libpref/src/Preferences.cpp, line 1396
###!!! ASSERTION: Could not initialize nsContentUtils: 'Error', file /root/rpmbuild/BUILD/xulrunner-8.0/mozilla-release/layout/build/nsLayoutStatics.cpp, line 163
WARNING: Not Initialized: file /root/rpmbuild/BUILD/xulrunner-8.0/mozilla-release/content/html/content/src/nsHTMLDNSPrefetch.cpp, line 122
WARNING: NS_ENSURE_TRUE(sPreferences) failed: file /root/rpmbuild/BUILD/xulrunner-8.0/mozilla-release/modules/libpref/src/Preferences.cpp, line 1438
WARNING: NS_ENSURE_TRUE(sPreferences) failed: file /root/rpmbuild/BUILD/xulrunner-8.0/mozilla-release/modules/libpref/src/Preferences.cpp, line 1438
###!!! ASSERTION: ReleaseStatics called without Initialize!: 'sLiveShells', file /root/rpmbuild/BUILD/xulrunner-8.0/mozilla-release/layout/base/nsPresShell.cpp, line 9368
+++ Failed to get ScriptSecurityManager service, running without principals###!!! ASSERTION: We are assuming that nsScriptSecurityManager::Init() has been run: 'cb', file /root/rpmbuild/BUILD/xulrunner-8.0/mozilla-release/js/src/xpconnect/shell/xpcshell.cpp, line 1914

Program received signal SIGSEGV, Segmentation fault.
main (argc=5, argv=0x3ffff8aab48, envp=0x3ffff8aab78)
    at /root/rpmbuild/BUILD/xulrunner-8.0/mozilla-release/js/src/xpconnect/shell/xpcshell.cpp:1915
1915	        NS_ASSERTION(!cb->findObjectPrincipals, "Your pigeon is in my hole!");
(Assignee)

Updated

5 years ago
Assignee: nobody → stransky
(Assignee)

Comment 1

5 years ago
Created attachment 578411 [details] [diff] [review]
patch

Actually it's the same as Bug 696393, but for s390x. Works fine although I'm unsure about the params of vtable_func.
Comment on attachment 578411 [details] [diff] [review]
patch

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

This looks good, provided the ABI is similar to that of s390 as documented on
ftp://archive.download.redhat.com/pub/redhat/linux/7.2/en/os/s390/doc/l390abi0.pdf
which is about the only document I found about the linux s390 ABI. (and I found no corresponding document for s390x)

What you can do to gain some more confidence is to build and run the test in xpcom/reflect/xptcall/tests and check the output. It's unfortunately not very easy to get what is an error and what is not in that test, so it's probably best to compare the output to the one you get on e.g. x86-64.
Attachment #578411 - Flags: review+
(Note that Debian is currently in the process of adding s390x as a supported architecture, and we're going to have s390x chroots available soon, so I'll be able to help there soon)
(Assignee)

Comment 4

5 years ago
Comment on attachment 578411 [details] [diff] [review]
patch

Thanks for pointing me to the test. Unfortunately the patch is broken, the TestXPTCInvoke segfaults on s390x.
Attachment #578411 - Flags: review+ → review-
(Assignee)

Comment 5

5 years ago
Created attachment 578566 [details] [diff] [review]
v2

Better one, passes xpcom tests (IMHO).
Attachment #578411 - Attachment is obsolete: true
Attachment #578566 - Flags: review?(mh+mozilla)

Comment 6

5 years ago
to Mike Hommey [:glandium] from comment #2)
> Comment on attachment 578411 [details] [diff] [review] [diff] [details] [review]
> patch
> 
> Review of attachment 578411 [details] [diff] [review] [diff] [details] [review]:
> -----------------------------------------------------------------
> 
> This looks good, provided the ABI is similar to that of s390 as documented on
> ftp://archive.download.redhat.com/pub/redhat/linux/7.2/en/os/s390/doc/
> l390abi0.pdf
> which is about the only document I found about the linux s390 ABI. (and I
> found no corresponding document for s390x)

ftp://legacy.redhat.com/pub/redhat/linux/7.1/es/os/s390x/doc/lzsabi0.pdf

or 

http://www.linuxbase.org/spec/ELF/zSeries/index_s390.html (once/if they get it working again)
Comment on attachment 578566 [details] [diff] [review]
v2

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

Seems good. 5 integer registers, one of which is used for "this", and 4 double registers.
Attachment #578566 - Flags: review?(mh+mozilla) → review+
(Assignee)

Updated

5 years ago
Keywords: checkin-needed
http://hg.mozilla.org/integration/mozilla-inbound/rev/2e6ab844f770
Keywords: checkin-needed
Target Milestone: --- → mozilla11

Comment 9

5 years ago
(In reply to Dão Gottwald [:dao] from comment #8)
> http://hg.mozilla.org/integration/mozilla-inbound/rev/2e6ab844f770

Just a small nitpicking: unused variable "PRUint64 result;"
http://hg.mozilla.org/integration/mozilla-inbound/rev/2e6ab844f770#l1.24
https://hg.mozilla.org/mozilla-central/rev/2e6ab844f770
Status: NEW → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.