jscrashreport.cpp fails to compile on mingw

RESOLVED FIXED in mozilla8

Status

()

Core
JavaScript Engine
RESOLVED FIXED
6 years ago
6 years ago

People

(Reporter: Jacek Caban, Assigned: Jacek Caban)

Tracking

Trunk
mozilla8
x86
Windows 7
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(2 attachments, 1 obsolete attachment)

(Assignee)

Description

6 years ago
Created attachment 545193 [details] [diff] [review]
fix v1.0

It's mostly due to using MS-style inline assembly. I could add ifdefed GCC assembly, but I think it's cleaner to use the existing solution for win64 and call RtlCaptureContext.

I've also changed case in windows.h include to fix cross compiling on case sensitive OSes.
Attachment #545193 - Flags: review?(wmccloskey)
Thanks for the patch. Unfortunately, I just found out on #developers that we still nominally support Windows 2000, where RtlCaptureContext is unavailable. Is there some other way to do this?
(Assignee)

Comment 2

6 years ago
Created attachment 545213 [details] [diff] [review]
fix with inline GCC assembly
Assignee: general → jacek
Attachment #545193 - Attachment is obsolete: true
Attachment #545213 - Flags: review?(wmccloskey)
Attachment #545193 - Flags: review?(wmccloskey)
(Assignee)

Comment 3

6 years ago
Created attachment 545214 [details] [diff] [review]
fix without support for win2k in mingw builds
Attachment #545214 - Flags: review?(wmccloskey)
(Assignee)

Comment 4

6 years ago
Thanks for quick review. I've attached two versions of the fix that will keep support for win2k. The first version is just a port of existing assembly code to GCC. The second version is my previous approach, ifdefed so that MSC builds will still use assembly code. I think it's fine to not support win2k in mingw builds (I'd expect it to be already broken). Also this way, once we'll drop win2k support, we can just remove _MSC_VER ifdef and use the new code for MSC as well. I will the choice for you.
Comment on attachment 545214 [details] [diff] [review]
fix without support for win2k in mingw builds

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

Thanks again. I like this one better.
Attachment #545214 - Flags: review?(wmccloskey) → review+
Attachment #545213 - Flags: review?(wmccloskey)
(Assignee)

Comment 6

6 years ago
Pushed to m-i:

http://hg.mozilla.org/integration/mozilla-inbound/rev/126abe6c099a
Whiteboard: [inbound]
http://hg.mozilla.org/mozilla-central/rev/126abe6c099a
Status: NEW → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED
Whiteboard: [inbound]
Target Milestone: --- → mozilla8
You need to log in before you can comment on or make changes to this bug.