Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 28 Dec 2009 12:02:21 -0600
From:      Robert Noland <rnoland@FreeBSD.org>
To:        "Carlos A. M. dos Santos" <unixmania@gmail.com>
Cc:        freebsd-x11@freebsd.org
Subject:   Re: x11perf -all leads to Xorg crash on 8-STABLE
Message-ID:  <1262023342.30049.3.camel@balrog.2hip.net>
In-Reply-To: <e71790db0912280728l59a80c86rc76a3e760b5a21d7@mail.gmail.com>
References:  <e71790db0912261431h7285eeb4yeb1f648694730b@mail.gmail.com> <alpine.BSF.2.00.0912262126540.32530@wonkity.com> <e71790db0912270917n4ccdb185pe65f2f5c4f30ea0c@mail.gmail.com> <1261934521.2220.2834.camel@balrog.2hip.net> <e71790db0912270941hdd0bc04oe3c66a81b663f6eb@mail.gmail.com> <1261942898.2220.2976.camel@balrog.2hip.net> <e71790db0912271633q5178b868u26514a7e1ba6ec87@mail.gmail.com> <e71790db0912271735h7a3f7096rdad098e2f945243a@mail.gmail.com> <1261972205.2220.3468.camel@balrog.2hip.net> <e71790db0912280728l59a80c86rc76a3e760b5a21d7@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, 2009-12-28 at 13:28 -0200, Carlos A. M. dos Santos wrote:
> On Mon, Dec 28, 2009 at 1:50 AM, Robert Noland <rnoland@freebsd.org> wrote:
> > On Sun, 2009-12-27 at 23:35 -0200, Carlos A. M. dos Santos wrote:
> >> I just noticed that the CONFIGURE_ARGS in x11/pixman should disable
> >> sse2 on AMD64, but this is not working:
> >>
> >> > #0  0x000000080107c255 in pixman_blt_sse2 (src_bits=0x81344f000,
> >> > dst_bits=0x804000000, src_stride=2400,
> >> >    dst_stride=4096, src_bpp=32, dst_bpp=32, src_x=576, src_y=576,
> >> > dst_x=3, dst_y=3, width=10, height=9)
> >> >    at pixman-sse2.c:5330
> >>
> >> I rebuilt and reinstalled the pixman with
> >>
> >> # cd /usr/ports/x11/pixman
> >> # make BATCH=yes CONFIGURE_ARGS='--disable-vmx --disable-arm-simd
> >> --disable-mmx --disable-sse2' FORCE_PKG_REGISTER=yes install
> >>
> >> This did not solve the problem, just gave me a different kind of crash:
> >
> > How about updating pixman?  Patch attached.  It may not be an issue in
> > pixman, though.  I can't tell exactly what is invalid from the trace.
> > If you run it with drm debugging enabled, does drm return an error that
> > is triggering the server to abort?  What GPU is this on?
> 
> Updating pixman did not help:
> 
> Program received signal SIGSEGV, Segmentation fault.
> 0x000000080107d215 in pixman_blt_sse2 (src_bits=0x81364f000,
> dst_bits=0x804200000, src_stride=2400, dst_stride=4096, src_bpp=32,
> dst_bpp=32, src_x=576, src_y=576, dst_x=3, dst_y=3, width=10,
> height=9)
>     at pixman-sse2.c:5358
> 5358		    *(uint32_t *)d = *(uint32_t *)s;
> (gdb) print d
> $26 = (uint8_t *) 0x80420300c "���"
> (gdb) print s
> $27 = (uint8_t *) 0x8137a1100 <Error reading address 0x8137a1100: Bad address>

Ok, following the math in pixman... I don't quite see how this happens.
Are you using any unusual compiler optimizations?

I just tested this with pixman-0.16.0 from ports and xserver 1.7.3 with
nouveau and it does not kill the server.  I'm not sure that the output
is correct, but it does complete without error.

robert.

> The GPU is Intel 945GM
> 
> Program received signal SIGSEGV, Segmentation fault.
> 0x000000080107d215 in pixman_blt_sse2 (src_bits=0x81364f000,
> dst_bits=0x804200000, src_stride=2400, dst_stride=4096, src_bpp=32,
> dst_bpp=32, src_x=576, src_y=576, dst_x=3, dst_y=3, width=10,
> height=9)
>     at pixman-sse2.c:5358
> 5358		    *(uint32_t *)d = *(uint32_t *)s;
> (gdb) print d
> $26 = (uint8_t *) 0x80420300c "���"
> (gdb) print s
> $27 = (uint8_t *) 0x8137a1100 <Error reading address 0x8137a1100: Bad address>
> 
> Enabling DRM debug I get this:
> 
> [drm:pid14907:drm_modeset_ctl] pre-modeset, crtc 1
> [drm:pid14907:drm_vblank_get] enabling vblank on crtc 1, ret: 0
> [drm:pid14907:drm_update_vblank_count] enabling vblank interrupts on
> crtc 1, missed 776
> [drm:pid14907:drm_ioctl] pid=14907, cmd=0xc0086444, nr=0x44, dev
> 0xffffff0001560b00, auth=1
> [drm:pid14907:i915_emit_irq] emitting: 827225
> [drm:pid14907:drm_ioctl] pid=14907, cmd=0x80046445, nr=0x45, dev
> 0xffffff0001560b00, auth=1
> [drm:pid14907:drm_ioctl] pid=14907, cmd=0x2000641f, nr=0x1f, dev
> 0xffffff0001560b00, auth=1
> [drm:pid14907:drm_ioctl] no function
> pid 14907 (Xorg), uid 0: exited on signal 6 (core dumped)
> [drm:pid14907:drm_close] open_count = 1
> [drm:pid14907:drm_close] pid = 14907, device = 0xffffff0001560b00,
> open_count = 1
> [drm:pid14907:drm_close] Process 14907 dead, freeing lock for context 5
> [drm:pid14907:drm_lastclose]
> 
> The GPU is Intel 945GM
> 
> hostb0@pci0:0:0:0:	class=0x060000 card=0x30aa103c chip=0x27a08086
> rev=0x03 hdr=0x00
>     vendor     = 'Intel Corporation'
>     device     = '955XM/945GM/PM/GMS/940GML Express Processor to DRAM
> Controller'
>     class      = bridge
>     subclass   = HOST-PCI
> vgapci0@pci0:0:2:0:	class=0x030000 card=0x30aa103c chip=0x27a28086
> rev=0x03 hdr=0x00
>     vendor     = 'Intel Corporation'
>     device     = 'Mobile 945GM/GU Express Integrated Graphics Controller'
>     class      = display
>     subclass   = VGA
> vgapci1@pci0:0:2:1:	class=0x038000 card=0x30aa103c chip=0x27a68086
> rev=0x03 hdr=0x00
>     vendor     = 'Intel Corporation'
>     device     = 'Mobile 945GM/GU Express Integrated Graphics Controller'
>     class      = display
> 
> 
> BTW, the problem does not seem to be specific to Intel GPU or FreeBSD.
> I also get a X server crash by running x11perf -shmputxy10 on another
> machine running Ubuntu 8.10, with a nVidia GPU:
> 
> 00:05.0 VGA compatible controller: nVidia Corporation C51 [Geforce
> 6150 Go] (rev a2)
> 	Subsystem: Hewlett-Packard Company Device 30b7
> 	Flags: bus master, 66MHz, fast devsel, latency 0, IRQ 18
> 	Memory at b2000000 (32-bit, non-prefetchable) [size=16M]
> 	Memory at c0000000 (64-bit, prefetchable) [size=256M]
> 	Memory at b1000000 (64-bit, non-prefetchable) [size=16M]
> 	[virtual] Expansion ROM at 40000000 [disabled] [size=128K]
> 	Capabilities: <access denied>
> 	Kernel driver in use: nvidia
> 	Kernel modules: nvidiafb, nvidia
-- 
Robert Noland <rnoland@FreeBSD.org>
FreeBSD




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1262023342.30049.3.camel>