Closed
Bug 19431
Opened 25 years ago
Closed 25 years ago
Solaris + gcc-2.7.2.3 + -pedantic creates bad bits b/c of "long long"
Categories
(Core :: XPCOM, defect, P1)
Tracking
()
VERIFIED
FIXED
M13
People
(Reporter: MatsPalmgren_bugz, Assigned: cls)
References
Details
Attachments
(3 files)
1.48 KB,
patch
|
Details | Diff | Splinter Review | |
1.47 KB,
patch
|
Details | Diff | Splinter Review | |
1.53 KB,
patch
|
Details | Diff | Splinter Review |
STEPS TO REPRODUCE: 1. start mozilla 2. click menu item "Tasks"->"Tools"->"History" Before it crashes it says (in the console window): we don't handle eBorderStyle_close yet... please fix me Illegal Instruction - core dumped With build 1999111909 on Sun/Solaris 2.6/sparc I get the following stackdump: =>[1] 0xefff9fd0(0x839600, 0xef34fba0, 0x839600, 0xef7ed2b8, 0xef7ec9c0, 0x2ca), at 0xefff9fcf [2] PR_ExplodeTime(0x359b6, 0xef34fba0, 0xefff9fd0, 0x839600, 0x0, 0xefffa074), at 0xef34f178 [3] FormatPRTime__20nsDateTimeFormatUnixP9nsILocaleiilR8nsString(0x241000, 0x0, 0x2, 0x1, 0x359b6, 0xefffa2f0), at 0xeda09334 [4] GetTextForNode__17nsXULContentUtilsP10nsIRDFNodeR8nsString(0x0, 0x839600, 0xefffa2f0, 0xedbaea48, 0x839600, 0xedb7cb84), at 0xedbaebbc [5] SubstituteText__21RDFGenericBuilderImplP14nsIRDFResourceR8nsString(0x7ef580, 0x82b960, 0xefffa2f0, 0xefffa2f0, 0xedb9a5e4, 0xedb99d94), at 0xedba3e68 [6] BuildContentFromTemplate__21RDFGenericBuilderImplP10nsIContentT1iP14nsIRDFResour cei(0x7ef580, 0x815b80, 0x83d580, 0x0, 0x82b960, 0x0), at 0xedba4a9c [7] CreateTemplateContents__21RDFGenericBuilderImplP10nsIContentRC8nsString(0x7ef580 , 0x83d580, 0xefffaac8, 0xefffaac8, 0xedb9a5e4, 0x23d860), at 0xedba61a4 [8] CreateContents__21RDFGenericBuilderImplP10nsIContent(0x7ef580, 0x83d580, 0xedba100c, 0xef405b98, 0x2243c0, 0x837c00), at 0xedba10a8 [9] CreateContents__13nsXULDocumentP10nsIContent(0x7dee00, 0x83d580, 0x7dee04, 0xedbb478c, 0x83a000, 0x0), at 0xedbb4828 [10] EnsureContentsGenerated__C12nsXULElement(0x83d580, 0x83d580, 0x1322a0, 0x0, 0x0, 0xefffacd4), at 0xedb9c3f0 [11] ChildCount__C12nsXULElementRi(0x83d580, 0xefffad84, 0xedb98db0, 0x83dc00, 0x83d580, 0x83a000), at 0xedb98db4 [12] ProcessChildren__21nsCSSFrameConstructorP14nsIPresContextR23nsFrameConstructorSt ateP10nsIContentP8nsIFrameiR12nsFrameItemsi(0x626d40, 0x4d1f00, 0xefffb5b8, 0x83d580, 0x83dc00, 0x1), at 0xed3d0eb8 [13] ConstructTableCellFrameOnly__21nsCSSFrameConstructorP14nsIPresContextR23nsFrameC onstructorStateP10nsIContentP8nsIFrameP15nsIStyleContextRP8nsIFrameT6R14nsTableC reatori(0x626d40, 0x4d1f00, 0xefffb5b8, 0x83d580, 0x83d400, 0x837c00), at 0xed3c3f7c [14] ConstructTableCellFrame__21nsCSSFrameConstructorP14nsIPresContextR23nsFrameConst ructorStateP10nsIContentP8nsIFrameP15nsIStyleContextRP8nsIFrameN26R14nsTableCrea tori(0x626d40, 0x4d1f00, 0xefffb5b8, 0x83d580, 0x83d400, 0x837c00), at 0xed3c3bc4 [15] ConstructXULFrame__21nsCSSFrameConstructorP14nsIPresContextR23nsFrameConstructor StateP10nsIContentP8nsIFrameP7nsIAtomP15nsIStyleContextR12nsFrameItemsRi(0x626d4 0, 0x4d1f00, 0xefffb5b8, 0x83d580, 0x83d400, 0x23d860), at 0xed3c8a18 [16] ConstructFrame__21nsCSSFrameConstructorP14nsIPresContextR23nsFrameConstructorSta teP10nsIContentP8nsIFrameR12nsFrameItems(0x0, 0x4d1f00, 0xefffb5b8, 0x83d580, 0x83d400, 0xefffb2d0), at 0xed3ca7b4 [17] TableProcessChild__21nsCSSFrameConstructorP14nsIPresContextR23nsFrameConstructor StateP10nsIContentP8nsIFrameP15nsIStyleContextR12nsFrameItemsR14nsTableCreator(0 x626d40, 0x4d1f00, 0xefffb5b8, 0x83d580, 0x83d400, 0x837800), at 0xed3c4320 [18] TableProcessChildren__21nsCSSFrameConstructorP14nsIPresContextR23nsFrameConstruc torStateP10nsIContentP8nsIFrameR12nsFrameItemsR14nsTableCreator(0x0, 0x4d1f00, 0xefffb5b8, 0x83d380, 0x83d400, 0xefffb2d0), at 0xed3c422c [19] ConstructTableRowFrameOnly__21nsCSSFrameConstructorP14nsIPresContextR23nsFrameCo nstructorStateP10nsIContentP8nsIFrameP15nsIStyleContextiRP8nsIFrameR14nsTableCre ator(0x0, 0x4d1f00, 0xefffb5b8, 0x83d380, 0x83cb00, 0x837800), at 0xed3c37a8 [20] ConstructTableRowFrame__21nsCSSFrameConstructorP14nsIPresContextR23nsFrameConstr uctorStateP10nsIContentP8nsIFrameP15nsIStyleContextRP8nsIFrameT6R14nsTableCreato rP11nsTableList(0x626d40, 0x4d1f00, 0xefffb5b8, 0x83d380, 0x83cb00, 0x837800), at 0xed3c34e4 [21] ConstructXULFrame__21nsCSSFrameConstructorP14nsIPresContextR23nsFrameConstructor StateP10nsIContentP8nsIFrameP7nsIAtomP15nsIStyleContextR12nsFrameItemsRi(0x626d4 0, 0x4d1f00, 0xefffb5b8, 0x83d380, 0x83cb00, 0x23d820), at 0xed3c89b4 [22] ConstructFrame__21nsCSSFrameConstructorP14nsIPresContextR23nsFrameConstructorSta teP10nsIContentP8nsIFrameR12nsFrameItems(0x0, 0x4d1f00, 0xefffb5b8, 0x83d380, 0x83cb00, 0xefffb5f0), at 0xed3ca7b4 [23] CreateTreeWidgetContent__21nsCSSFrameConstructorP14nsIPresContextP8nsIFrameT2P10 nsIContentPP8nsIFrameii(0x626d40, 0x4d1f00, 0x83cb00, 0x0, 0x83d380, 0x83cb44), at 0xed3d2b80 [24] GetFirstFrameForReflow__19nsTreeRowGroupFrameR14nsIPresContext(0x83cb00, 0x4d1f00, 0xed4488d8, 0xfe1, 0xed44908c, 0x23d8a0), at 0xed448bb8 [25] ReflowMappedChildren__20nsTableRowGroupFrameR14nsIPresContextR19nsHTMLReflowMetr icsR19RowGroupReflowStateRUiP15nsTableRowFrame14nsReflowReasonii(0x83cb00, 0x4d1f00, 0xefffbb30, 0xefffb928, 0xefffc6f4, 0x0), at 0xed41f8d0 [26] Reflow__20nsTableRowGroupFrameR14nsIPresContextR19nsHTMLReflowMetricsRC17nsHTMLR eflowStateRUi(0x83cb00, 0x4d1f00, 0xefffbb30, 0xefffba90, 0xefffc6f4, 0x4d1f00), at 0xed420c30 [27] ReflowChild__16nsContainerFrameP8nsIFrameR14nsIPresContextR19nsHTMLReflowMetrics RC17nsHTMLReflowStateiiUiRUi(0x0, 0x83cb00, 0x4d1f00, 0xefffbb30, 0xefffba90, 0x0), at 0xed2c49f0 [28] ReflowMappedChildren__20nsTableRowGroupFrameR14nsIPresContextR19nsHTMLReflowMetr icsR19RowGroupReflowStateRUiP15nsTableRowFrame14nsReflowReasonii(0x836600, 0x4d1f00, 0xefffbf20, 0xefffbc28, 0xefffc6f4, 0x0), at 0xed41fad0 [29] Reflow__20nsTableRowGroupFrameR14nsIPresContextR19nsHTMLReflowMetricsRC17nsHTMLR eflowStateRUi(0x836600, 0x4d1f00, 0xefffbf20, 0xefffbe50, 0xefffc6f4, 0x4d1f00), at 0xed420c30 [30] ReflowChild__16nsContainerFrameP8nsIFrameR14nsIPresContextR19nsHTMLReflowMetrics RC17nsHTMLReflowStateiiUiRUi(0x0, 0x836600, 0x4d1f00, 0xefffbf20, 0xefffbe50, 0x0), at 0xed2c49f0 [31] ReflowMappedChildren__12nsTableFrameR14nsIPresContextR19nsHTMLReflowMetricsR21In nerTableReflowStateRUi(0x817b00, 0x4d1f00, 0xefffc478, 0xefffbfc8, 0xefffc6f4, 0xed416964), at 0xed416c30 [32] ResizeReflowPass2__12nsTableFrameR14nsIPresContextR19nsHTMLReflowMetricsRC17nsHT MLReflowStateRUi(0x817b00, 0x4d1f00, 0xefffc478, 0xefffc0a0, 0xefffc6f4, 0xed41484c), at 0xed4149a0 [33] Reflow__12nsTableFrameR14nsIPresContextR19nsHTMLReflowMetricsRC17nsHTMLReflowSta teRUi(0x817b00, 0x4d1f00, 0xefffc478, 0xefffc3d0, 0xefffc6f4, 0x0), at 0xed414254 [34] Reflow__11nsTreeFrameR14nsIPresContextR19nsHTMLReflowMetricsRC17nsHTMLReflowStat eRUi(0x817b00, 0x4d1f00, 0xefffc478, 0xefffc3d0, 0xefffc6f4, 0xed4456a4), at 0xed445734 [35] ReflowChild__16nsContainerFrameP8nsIFrameR14nsIPresContextR19nsHTMLReflowMetrics RC17nsHTMLReflowStateiiUiRUi(0x0, 0x817b00, 0x4d1f00, 0xefffc478, 0xefffc3d0, 0x0), at 0xed2c49f0 [36] Reflow__17nsTableOuterFrameR14nsIPresContextR19nsHTMLReflowMetricsRC17nsHTMLRefl owStateRUi(0x817a80, 0x4d1f00, 0xefffc810, 0xefffc550, 0xefffc6f4, 0xed41b9d8), at 0xed41bcb8 [37] ReflowBlock__20nsBlockReflowContextP8nsIFrameRC6nsRectiiiR8nsMarginRUi(0xefffc7d 0, 0x817a80, 0x0, 0x0, 0x0, 0x1), at 0xed2c1c58 [38] ReflowBlockFrame__12nsBlockFrameR18nsBlockReflowStateP9nsLineBoxPi(0x817a00, 0xefffca90, 0x831a80, 0xefffc9c4, 0xefffc940, 0xed2cd558), at 0xed2bd414 [39] ReflowLine__12nsBlockFrameR18nsBlockReflowStateP9nsLineBoxPii(0x817a00, 0xefffca90, 0x831a80, 0xefffc9c4, 0x0, 0xff0000), at 0xed2bc2ec [40] ReflowDirtyLines__12nsBlockFrameR18nsBlockReflowState(0x817a00, 0xefffca90, 0x4d1f00, 0xefffcd34, 0xefffce78, 0x0), at 0xed2bbf00 [41] Reflow__12nsBlockFrameR14nsIPresContextR19nsHTMLReflowMetricsRC17nsHTMLReflowSta teRUi(0x817a00, 0x4d1f00, 0xefffce78, 0xefffccf0, 0xefffce5c, 0x81a8c0), at 0xed2bae34 [42] FlowChildAt__10nsBoxFrameP8nsIFrameR14nsIPresContextR19nsHTMLReflowMetricsRC17ns HTMLReflowStateRUiR19nsCalculatedBoxInfoRiR8nsString(0x835880, 0x817a00, 0x4d1f00, 0xefffce78, 0xefffd1a8, 0xefffce5c), at 0xed4378e0 [43] GetChildBoxInfo__10nsBoxFrameR14nsIPresContextRC17nsHTMLReflowStateP8nsIFrameR19 nsCalculatedBoxInfo(0x81a880, 0x4d1f00, 0xefffd1a8, 0x817a00, 0x835880, 0xed436510), at 0xed4367cc [44] GetBoxInfo__10nsBoxFrameR14nsIPresContextRC17nsHTMLReflowStateR9nsBoxInfo(0x81a8 80, 0x4d1f00, 0xefffd1a8, 0xefffd020, 0xed438864, 0xed2cd558), at 0xed438928 [45] Reflow__10nsBoxFrameR14nsIPresContextR19nsHTMLReflowMetricsRC17nsHTMLReflowState RUi(0x81a880, 0x4d1f00, 0xefffd248, 0xefffd1a8, 0xefffd500, 0xed436848), at 0xed436984 [46] ReflowChild__16nsContainerFrameP8nsIFrameR14nsIPresContextR19nsHTMLReflowMetrics RC17nsHTMLReflowStateiiUiRUi(0x0, 0x81a880, 0x4d1f00, 0xefffd248, 0xefffd1a8, 0x0), at 0xed2c49f0 [47] Reflow__9RootFrameR14nsIPresContextR19nsHTMLReflowMetricsRC17nsHTMLReflowStateRU i(0x81a7c0, 0x4d1f00, 0xefffd428, 0xefffd380, 0xefffd500, 0xefffd500), at 0xed2d4100 [48] ReflowChild__16nsContainerFrameP8nsIFrameR14nsIPresContextR19nsHTMLReflowMetrics RC17nsHTMLReflowStateiiUiRUi(0x0, 0x81a7c0, 0x4d1f00, 0xefffd428, 0xefffd380, 0x0), at 0xed2c49f0 [49] Reflow__13ViewportFrameR14nsIPresContextR19nsHTMLReflowMetricsRC17nsHTMLReflowSt ateRUi(0x81a780, 0x4d1f00, 0xefffd5b0, 0xefffd508, 0xefffd500, 0xefffd500), at 0xed2fa370 [50] InitialReflow__9PresShellii(0x6eb000, 0xefffd5f4, 0x1194, 0xed2e9b10, 0xefffd760, 0xedbcfa84), at 0xed2e9df0 [51] StartLayout__13nsXULDocument(0x7dee00, 0xefffd6f0, 0x7dee00, 0xefffd750, 0x0, 0x80000000), at 0xedbb7d08 [52] ResumeWalk__13nsXULDocument(0x7dee00, 0xefffd840, 0xefffd88c, 0xedc1dc78, 0x1, 0x7dee00), at 0xedbbae1c [53] OnUnicharStreamComplete__13nsXULDocumentP22nsIUnicharStreamLoaderUiPCUs(0x7dee00 , 0x717b60, 0x70e214, 0x809000, 0xedbbb05c, 0x0), at 0xedbbb0dc [54] OnStopRequest__21nsUnicharStreamLoaderP10nsIChannelP11nsISupportsUiPCUs(0x717b60 , 0x719680, 0x0, 0x0, 0x0, 0xee3507e4), at 0xee350810 [55] OnStopRequest__17nsChannelListenerP10nsIChannelP11nsISupportsUiPCUs(0x717ba0, 0x719680, 0x0, 0x0, 0x0, 0xeda85494), at 0xeda854b8 [56] OnStopRequest__13nsFileChannelP10nsIChannelP11nsISupportsUiPCUs(0x719680, 0x823900, 0x0, 0x0, 0x0, 0xeec67f34), at 0xeec67f58 [57] HandleEvent__20nsOnStopRequestEvent(0x70b220, 0xee33ef5c, 0x64ec0, 0xef746f2c, 0xefffded8, 0xef746f24), at 0xee33ef88 [58] HandlePLEvent__21nsStreamListenerEventP7PLEvent(0x70b240, 0xee33e9dc, 0xef746c00, 0xef746f2c, 0xef746c00, 0x1), at 0xee33e9f8 [59] PL_HandleEvent(0x70b240, 0x70d000, 0x371000, 0x70b000, 0x709000, 0x0), at 0xef4e2328 [60] PL_ProcessPendingEvents(0x97040, 0x2, 0x70900c, 0x709000, 0x709cc0, 0x709), at 0xef4e22b0 [61] ProcessPendingEvents__16nsEventQueueImpl(0x64e60, 0xef429e84, 0x6eb, 0x709000, 0x709c80, 0x709), at 0xef429e88 [62] 0xee0f2bb4(0x64e60, 0x7, 0x1, 0xee0f2b98, 0x0, 0x0), at 0xee0f2bb3 [63] 0xee0f2600(0x23f660, 0x1, 0x23f640, 0xee0f25dc, 0x0, 0x0), at 0xee0f25ff [64] 0xef7011bc(0x23f680, 0xefffded8, 0x23f640, 0x709c98, 0x0, 0xefffde48), at 0xef7011bb [65] 0xef7029bc(0xef746c00, 0xef746c00, 0xef746c00, 0xef746f2c, 0xefffded8, 0xef746f24), at 0xef7029bb [66] 0xef702fcc(0xef746c00, 0xef746c00, 0xef746c00, 0xef746f2c, 0xef746c00, 0x1), at 0xef702fcb [67] g_main_run(0x23f6e0, 0xef745800, 0x0, 0xc8, 0xef7ec9c0, 0x17), at 0xef703154 [68] gtk_main(0x0, 0x64e60, 0x1, 0xee0f30b8, 0xef426a0c, 0x0), at 0xef66f5b4 [69] Run__10nsAppShell(0xc7580, 0xee0f2eb4, 0xc7580, 0xeee90818, 0x0, 0xffe), at 0xee0f3024 [70] Run__17nsAppShellService(0x6efc0, 0xeee7d800, 0x6efc0, 0xedad8398, 0x0, 0xef12a148), at 0xeee7d814 [71] 0x14e94(0x1, 0xefffe2e4, 0x0, 0x2, 0xffffffff, 0xef7c16e1), at 0x14e93 [72] main(0x1, 0xefffe2e4, 0xefffe2ec, 0x29a70, 0x0, 0x0), at 0x150d8 (dbx)
Reporter | ||
Updated•25 years ago
|
Severity: normal → critical
Updated•25 years ago
|
Assignee: leger → radha
Component: Browser-General → XPApps
Comment 1•25 years ago
|
||
history, radha.
Updated•25 years ago
|
Assignee: radha → leger
Comment 2•25 years ago
|
||
I do only session History, BAck/Forward buttons. This is the global history window. Stack trace suggests something in XUL/CSS or some date/time calculation for history entries. waterson or evaughan may be able to help. Reassigning to leger.
Assignee: leger → pierre
Component: XPApps → Style System
QA Contact: leger → chrisd
Updated•25 years ago
|
Assignee: pierre → waterson
Comment 4•25 years ago
|
||
I can't reproduce it on recent builds on Mac and Windows. Reassigning to waterson who seemed to have worked on History and who is more likely to have a Unix box.
Updated•25 years ago
|
QA Contact: chrisd → tever
Updated•25 years ago
|
Status: NEW → ASSIGNED
Priority: P3 → P1
Target Milestone: M13
Comment 5•25 years ago
|
||
hey mcafee, can you help me with this one? i've managed to reproduce it: it's solaris-only, and is dying in the bowels of NSPR's date conversion routines. I've managed to trap in in gdb, and everything looks sane, so I have no idea why we're getting a segfault.
Updated•25 years ago
|
Summary: Crash when attempting to open the History window → Solaris: Crash when attempting to open the History window
Comment 6•25 years ago
|
||
waterson, I can help look at this, updating my build now.
Comment 7•25 years ago
|
||
ok, i tried building this with both gcc-2.7.2.3 and egcs-1.1.2. I was only able to reproduce the crash-on-open with gcc-2.7.2.3. I'm going to check in a fix for 22294 (which may be related), and then re-try both platforms.
Updated•25 years ago
|
Summary: Solaris: Crash when attempting to open the History window → Solaris/gcc-2.7.2.3: Crash when attempting to open the History window
Comment 8•25 years ago
|
||
wan-teh, are there any known problems with LL_L2I() on gcc-2.7.2.3/solaris?
Comment 9•25 years ago
|
||
No, I don't know of any problem with LL_L2I() on gcc-2.7.2.3/solaris. This macro expands to: i = (PRInt32) l; I could see you may have problems due to truncation, but I don't understand how you would crash in an assignment statement.
Updated•25 years ago
|
Component: Style System → Threading
Comment 10•25 years ago
|
||
0xef3415c4 <ComputeGMT+36>: clr %o0 0xef3415c8 <ComputeGMT+40>: or %o1, 0x240, %o1 0xef3415cc <ComputeGMT+44>: std %o0, [ %fp + -88 ] 0xef3415d0 <ComputeGMT+48>: ldd [ %fp + -24 ], %o0 0xef3415d4 <ComputeGMT+52>: ldd [ %fp + -88 ], %o2 0xef3415d8 <ComputeGMT+56>: call 0xef375d28 <_PROCEDURE_LINKAGE_TABLE_+2652> 0xef3415dc <ComputeGMT+60>: nop 0xef3415e0 <ComputeGMT+64>: std %o0, [ %fp + -72 ] 0xef3415e4 <ComputeGMT+68>: ldd [ %fp + -24 ], %o2 0xef3415e8 <ComputeGMT+72>: mov %o2, %o0 0xef3415ec <ComputeGMT+76>: mov %o3, %o1 0xef3415f0 <ComputeGMT+80>: ldd [ %fp + -88 ], %o2 ---Type <return> to continue, or q <return> to quit--- 0xef3415f4 <ComputeGMT+84>: call 0xef375d34 <_PROCEDURE_LINKAGE_TABLE_+2664> 0xef3415f8 <ComputeGMT+88>: nop 0xef3415fc <ComputeGMT+92>: std %o0, [ %fp + -80 ] 0xef341600 <ComputeGMT+96>: ld [ %fp + 0x4c ], %o0 0xef341604 <ComputeGMT+100>: ld [ %fp + -76 ], %o1 0xef341608 <ComputeGMT+104>: st %o1, [ %o0 ] It crashes there in 0xef321608 at the store statement. At that point in time, the o1 and o0 registers are: o0 0xef342c64 -281793436 o1 0xa88a4 690340 And: (gdb) print gmt $1 = (PRExplodedTime *) 0xef342c64 (gdb) print &usec $2 = (long long int *) 0xefffaa30 (gdb) print usec $3 = 690340 (gdb) print *gmt $4 = {tm_usec = -1646018768, tm_sec = -536371136, tm_min = -265838524, tm_hour = 318767188, tm_mday = -1877843584, tm_month = -802701380, tm_year = -28665, tm_wday = -65 '¿', tm_yday = -28153, tm_params = { tp_gmt_offset = 1073794098, tp_dst_offset = 16777216}} (gdb) Hope that helps a bit.
Comment 11•25 years ago
|
||
I looked at the sparc assembly and variable values that bruce obtained from the debugger. I am not familiar with sparc assembly, but I don't see anything wrong. Come to think of it, NSPR did not define HAVE_LONG_LONG for Solaris before. I was told that the reason was that gcc did not support long long. I don't know which version of gcc that was and whether gcc didn't have the long long type or had a buggy implementation of long long stuff.
Comment 12•25 years ago
|
||
okay, i think the problem is that we're invoking the compiler differently between NSPR and the rest of the browser source tree. The way that C++ is passing long-long's as parameters is not how NSPR is expecting it. so the parameters are being munged on the way in to PR_ExplodeTime().
Comment 13•25 years ago
|
||
Doh! In the C++ code, sizeof(PRTime) == 4. In NSPR, sizeof(PRTime) == 8. Oops.
Comment 14•25 years ago
|
||
sonofabitch. it's the "-pedantic" option. #include <stdio.h> int main(int argc, char* argv) { long long foo; printf("%d\n", sizeof(foo)); return 0; } compile that with gcc-2.7.2.3, once with "-pedantic", once without. The program's output will be "4" and "8", respectively. Moral of the story: don't use "-pedantic" with gcc-2.7.2.3.
Updated•25 years ago
|
Assignee: waterson → cls
Status: ASSIGNED → NEW
Summary: Solaris/gcc-2.7.2.3: Crash when attempting to open the History window → Solaris + gcc-2.7.2.3 + -pedantic creates bad bits b/c of "long long"
Comment 15•25 years ago
|
||
cls: i'm gonna give this bug to you: you can either mark it as INVALID, or figure out some way to bulletproof "configure" to keep people from shooting themselves in the foot. thanks!
Updated•25 years ago
|
Target Milestone: M13
Comment 16•25 years ago
|
||
clear M13 TFV
Comment 17•25 years ago
|
||
*** Bug 23359 has been marked as a duplicate of this bug. ***
Updated•25 years ago
|
Target Milestone: M13
Comment 18•25 years ago
|
||
Ugh. Actually, this is kind of a big deal. I thought that -pedantic was only turned on if you said "--enable-pedantic". It looks like it is -always- on for gcc-2.7.2.3. So, this pretty much needs to be done for M13. Adding leaf to cc list in case cls can't get to this...
Assignee | ||
Comment 19•25 years ago
|
||
Well, I was trying to find out if the proposed check would work on 64 bit machines like an alpha. I was under the possible misconception that sizeof(long) == sizeof(long long) == 8 on the alpha. I may have to an another conditional to the patch...&& sizeof(long) != 8.
Assignee | ||
Comment 20•25 years ago
|
||
Comment 21•25 years ago
|
||
You only need to check whether sizeof(long long) == 8. The size of long is irrelevant to this bug. It is true that sizeof(long long) == sizeof(long) == 8 on 64-bit systems such as Alpha. This is called the LP64 model (meaning longs and pointers are 64-bit).
Assignee | ||
Comment 22•25 years ago
|
||
Assignee | ||
Comment 23•25 years ago
|
||
I don't have gcc 2.7.2.3 on my solaris box, so if someone would check that this properly halts the configure process with an error message, I'll check the patch in.
Comment 24•25 years ago
|
||
cls: i just tried this patch, and it claimed that gcc-2.7.2.3 did -not- have the bug (and thus, configured it to build with -pedantic *on*). can I make "configure" run verbosely so I can watch what it's trying to do?
Comment 25•25 years ago
|
||
ok, shaver pointed me to config.log. It doesn't appear to be adding the "-pedantic" to the CFLAGS before running: configure:9158: checking whether compiler has -pedantic long long bug configure:9169: gcc -o conftest -g -pedantic conftest.c -lw -lposix4 -lintl -lelf -lnsl -lsocket -lresolv -ldl -lm 1>&5 configure: In function `main': configure:9165: warning: ANSI C does not support `long long' configure:9213: checking whether compiler supports -Wno-long-long configure:9222: gcc -c -g -Wno-long-long conftest.c 1>&5 cc1: Invalid option `-Wno-long-long' configure: failed program was: #line 9215 "configure" #include "confdefs.h" int main() { return(0); ; return 0; }
Comment 26•25 years ago
|
||
Oh, I am an idiot. It's right there. Duh. Ok, let me poke around a bit more...
Comment 27•25 years ago
|
||
Ok, I see the problem. AC_TRY_RUN() is invoking gcc as "gcc", which correctly notes that sizeof(long long) == 8. If I try to compile the file BY HAND using "c++", I get sizeof(long long) == 4.
Comment 28•25 years ago
|
||
FWIW, at Netscape, % which c++ /tools/contrib/gcc-2.7.2.3/bin/c++ % c++ -v Reading specs from /tools/contrib/gcc-2.7.2.3/lib/gcc-lib/sparc-sun-solaris2.6/2.7.2.3/specs Interestingly, invoking as "g++" gets it right (i.e., sizeof(long long) == 8). I'm way confused now.
Comment 29•25 years ago
|
||
cls: i have no idea if this is sane or not, but adding: _SAVE_CC=$CC CC=$CXX /* ...the rest of the goop... */ CC=$_SAVE_CC Seems to get AC_TRY_RUN() to do the right thing.
Comment 30•25 years ago
|
||
Oh, and one more thing: when you check this in, you will instantly break wensleydale (unless someone has already added --disable-pedantic to wensleydale's .mozconfig).
Assignee | ||
Comment 31•25 years ago
|
||
Comment 32•25 years ago
|
||
looks good to me; r=waterson. just be sure to coordinate with leaf so wensleydale doesn't burn. thanks, chris!
Comment 33•25 years ago
|
||
I can also help with watching/fixing wensleydale.
Status: ASSIGNED → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
Assignee | ||
Comment 34•25 years ago
|
||
Checked in the fix on Friday. Wensleydale went red for a bit because it used the options from .mozconfig rather than the tinderbox script itself.
Comment 36•22 years ago
|
||
Moving all threading bugs to XPCOM. See bug 160356.
Component: Threading → XPCOM
You need to log in
before you can comment on or make changes to this bug.
Description
•