[comp.windows.x] More about the dreaded Xsun core dump problem.

fmayhar@hermes.ladc.bull.com (Frank Mayhar) (02/09/90)

Just had Xsun core dump on me.  Fortunately, I was waiting for it, and had
compiled it with "-g".  I'll keep the core file around for a while, so if
anyone (say, at MIT) wants any more information from it, I'll be able to
provide it.

The environment:  Sun 386i/150 (20 MHz, no cache), running SunOS 4.0.2.
8MB memory, ~16MB swap, monochrome frame buffer (1152x900).  Xsun
compiled with "-g", everything else with "-O".

I was fooling around with xclipboard at the time, and it had a couple of
scrollbars on it.  I had scrolled down in the buffer, and wanted to scroll
back up.  It looked a little funny (like it wasn't displaying everything),
but I'm not sure that that's significant.  What _is_ significant is that,
just as I clicked left on the vertical scrollbar to scroll back, Xsun crashed.
I'm certain that this has happened at least once before, using xterm, same
circumstances (i.e. scrolling back).

Here's some preliminary info from the core dump.  I hope it helps; not being
an X hacker myself, it doesn't mean much to me.  I note, though, that
pReg->data is 2, which isn't a very good pointer value, and is the reason
for the SEGV.

I would have sent a real bug report to xbugs, but I don't have enough
information.

dbx /usr/bin/X11/Xsun.g core
Reading symbolic information...
Read 88902 symbols
program terminated by signal SEGV (no mapping at the fault address)
(dbx) where
miRegionUninit(pReg = 0xfbfffac4), line 343 in
                       "/usr2_app/X.V11R4/sun386i/mit/server/ddx/mi/miregion.c"
mfbCopyArea(pSrcDrawable = 0xbcf60, pDstDrawable = 0xafa18, pGC = 0xdffa4,
            srcx = 0, srcy = 0, width = 31, height = 25, dstx = 585,
            dsty = 219), line 292 in
                     "/usr2_app/X.V11R4/sun386i/mit/server/ddx/mfb/mfbbitblt.c"
miSpriteCopyArea(pSrc = 0xbcf60, pDst = 0xafa18, pGC = 0xdffa4, srcx = 0,
                 srcy = 0, w = 31, h = 25, dstx = 585, dsty = 219), line 999 in
                       "/usr2_app/X.V11R4/sun386i/mit/server/ddx/mi/misprite.c"
miDCRestoreUnderCursor(pScreen = 0xaef7c, x = 585, y = 219, w = 31, h = 25),
          line 386 in "/usr2_app/X.V11R4/sun386i/mit/server/ddx/mi/midispcur.c"
miSpriteRemoveCursor(pScreen = 0xaef7c), line 1924 in
                       "/usr2_app/X.V11R4/sun386i/mit/server/ddx/mi/misprite.c"
miSpritePolyFillRect(pDrawable = 0xd2144, pGC = 0xdd77c, nrectFill = 1,
                     prectInit = 0xf0e6c), line 1395 in
                       "/usr2_app/X.V11R4/sun386i/mit/server/ddx/mi/misprite.c"
ProcPolyFillRectangle(client = 0xbcf60), line 1782 in
                          "/usr2_app/X.V11R4/sun386i/mit/server/dix/dispatch.c"
Dispatch(), line 256 in "/usr2_app/X.V11R4/sun386i/mit/server/dix/dispatch.c"
main(argc = 4, argv = 0xfbfffd38, 0xfbfffd4c), line 251 in
                              "/usr2_app/X.V11R4/sun386i/mit/server/dix/main.c"
(dbx) list
  338   void
  339   miRegionUninit(pReg)
  340       RegionPtr pReg;
  341   {
  342       good(pReg);
  343       xfreeData(pReg);
  344   }
  345   
(dbx) 0x76a00/20i
miRegionDestroy:		jmp    miRegionDestroy-0x2e
miRegionUninit-0x27:		jmp    miRegionUninit-3
miRegionUninit-0x25:		movl   spentry(%ebp),%eax
miRegionUninit-0x22:		cmpl   $0,spentry(%eax)
miRegionUninit-0x1e:		je     miRegionUninit-5
miRegionUninit-0x1c:		movl   spentry(%ebp),%eax
miRegionUninit-0x19:		movl   spentry(%eax),%edx
miRegionUninit-0x16:		cmpl   $0,(%edx)
miRegionUninit-0x13:		je     miRegionUninit-5
miRegionUninit-0x11:		movl   spentry(%ebp),%eax
miRegionUninit-0xe:		pushl  spentry(%eax)
miRegionUninit-0xb:		call   Xfree-0x18
miRegionUninit-6:		popl   %ecx
miRegionUninit-5:		leave  
miRegionUninit-4:		ret    
miRegionUninit-3:		pushl  %ebp
miRegionUninit-2:		movl   %esp,%ebp
miRegionUninit:		jmp    miRegionUninit-0x25
miRectAlloc-0xde:		jmp    miRectAlloc-3
miRectAlloc-0xd9:		movl   spentry(%ebp),%edi
(dbx) print $eip
$eip = 0x76a13
(dbx) 0x76a13/i
miRegionUninit-0x16:		cmpl   $0,(%edx)
(dbx) print $edx
$edx = 2
(dbx) print pReg
`miregion`miRegionUninit`pReg = 0xfbfffac4
(dbx) print *pReg
*`miregion`miRegionUninit`pReg = {
        extents = {
                x1 = -21846
                y1 = -21846
                x2 = 24940
                y2 = 14
        }
        data    = 0x2
}
(dbx) quit
--
Frank Mayhar  fmayhar@hermes.ladc.bull.com (..!{uunet,hacgate}!ladcgw!fmayhar)
              Bull HN Information Systems Inc.  Los Angeles Development Center
              5250 W. Century Blvd., LA, CA  90045    Phone:  (213) 216-6241

rws@EXPO.LCS.MIT.EDU (Bob Scheifler) (02/09/90)

We have a fix for this, it should be out soon.