Subject: XFree 4.2.0 on Alpha
To: None <tech-x11@netbsd.org>
From: David Hopper <dhop@nwlink.com>
List: tech-x11
Date: 05/02/2002 07:11:05
Sorry for the length of this.  I'm posting this in the hope that someone
here may know the intricacies of memory allocation in XFree86 on the Alpha
better than me (when [me contains zero knowledge]).

Here's the scoop:  since XFree 4.0 was imported, we Alpha users have had to
use -Wl,-E (or -Wl,--export-dynamic) in order to avoid PLT (dynamic symbol
table) errors on most Alpha platforms.  We've also needed to patch
bsd_axp.c and bsd_video.c using patches generated against 4.0.3.  Doing
this though has gotten me a rock-solid 4.1.0 server on a Digital PWS 500au.

However, it stopped working in 4.2.0 (one of the server modules still had
an -rpath, maybe), and I had to use -Wl,-Bstatic.  No problem there, that
solved the PLT errors.  But now with the new 4.2.0 server I'm seeing a kind
of multicolored pixel ghosting, or trailing, whenever I move windows, or
when there is a stipple effect.  Back when I hacked on X for the Amiga,
this meant that the pixel clock was overdriven.  I don't know what it means
on the Alpha.  (I should add that I've added byte/word optimization with
-mcpu=ev56 and --memory-clock=3 to this compile; I didn't do this with
4.1.0).

Here's the diff (edited for obvious content) of the functional 4.1.0 server
log against the log of the solid-but-ugly 4.2.0 server.  Both logs are
against the same /etc/XF86Config, and both logs are using the 4.2.0
codebase _except for the server binary_ (I can run a 4.1.0 server binary
against a 4.2.0 X11R6 just fine, so far).  Basically, I don't know what to
look for, but it seems like there's a memory register that would be an easy
fix.  This is all on current code (to April 29), and a Matrox Millennium II
(2164w).

Thanks VERY MUCH for any help.
Dave

2,4c2,4
< XFree86 Version 4.1.0 / X Window System
< (protocol Version 11, revision 0, vendor release 6510)
< Release Date: 2 June 2001
---
> XFree86 Version 4.2.0 / X Window System
> (protocol Version 11, revision 0, vendor release 6600)
> Release Date: 23 January 2002
7,10c7,8
< 	reporting problems.  (See http://www.XFree86.Org/FAQ)
< Build Operating System: NetBSD/alpha 1.5X [ELF] The NetBSD Foundation,
Inc.
< (==) Log file: "/var/log/XFree86.0.log", Time: Thu May  2 06:13:39 2002
< (==) Using config file: "/etc/X11/XF86Config"
---
> 	reporting problems.  (See http://www.XFree86.Org/)
> Build Operating System: NetBSD/alpha 1.5ZC [ELF] The NetBSD Foundation, Inc.
13a12,13
> (==) Log file: "/var/log/XFree86.0.log", Time: Thu May  2 05:47:28 2002
> (==) Using config file: "/etc/X11/XF86Config"
123c123,124
< 	mga2164w AGP, mgag100, mgag100 PCI, mgag200, mgag200 PCI, mgag400
---
> 	mga2164w AGP, mgag100, mgag100 PCI, mgag200, mgag200 PCI, mgag400,
> 	mgag550
126,129c127,131
[supported hardware diffs deleted]
< 	S3VProbe begin
< (WW) ****INVALID MEM ALLOCATION**** b: 0x80860000 e: 0x80863fff
correcting
< (II) NonSys
< 	[0] -1	0x80800000 - 0x80ffffff (0x800000) MX[B]
< 	[1] -1	0x80865000 - 0x80865fff (0x1000) MX[B]
< 	[2] -1	0x80840000 - 0x8087ffff (0x40000) MX[B]
< 	[3] -1	0x80864000 - 0x80864fff (0x1000) MX[B]
< 	[4] -1	0x80900000 - 0x809fffff (0x100000) MX[B]
< 	[5] -1	0x80940000 - 0x8097ffff (0x40000) MX[B]
< 	[6] -1	0xffffffff - 0xffffffff (0x1) MX[B]
< 	[7] -1	0x00000000 - 0x00000000 (0x1) MX[B]
< 	[8] -1	0x000c0000 - 0x000effff (0x30000) MX[B]
< 	[9] -1	0x00008000 - 0x000080ff (0x100) IX[B]
< 	[10] -1	0x00008100 - 0x000081ff (0x100) IX[B]
< 	[11] -1	0x00009080 - 0x000090ff (0x80) IX[B]
< 	[12] -1	0x00009000 - 0x0000907f (0x80) IX[B]
< 	[13] -1	0xffffffff - 0xffffffff (0x1) IX[B]
< 	[14] -1	0x00000000 - 0x000000ff (0x100) IX[B]
< (II) window:
< 	[0] -1	0x80000000 - 0x808fffff (0x900000) MX[B]
< (II) resSize:
< 	[0] -1	0x00000000 - 0xffffffff (0x0) MX[B]
< (II) window fixed:
< 	[0] -1	0x80000000 - 0x808fffff (0x900000) MX[B]
195,203c198,206
< 	[0] -1	0x80800000 - 0x80803fff (0x4000) MX[B](B)
< 	[1] -1	0xffffffff - 0xffffffff (0x1) MX[B]
< 	[2] -1	0x00000000 - 0x00000000 (0x1) MX[B]
< 	[3] -1	0x000c0000 - 0x000effff (0x30000) MX[B]
< 	[4] -1	0x80865000 - 0x80865fff (0x1000) MX[B]E
< 	[5] -1	0x80864000 - 0x80864fff (0x1000) MX[B]E
< 	[6] -1	0x80940000 - 0x8097ffff (0x40000) MX[B]E
< 	[7] -1	0x80850000 - 0x8085ffff (0x10000) MX[B](B)
< 	[8] -1	0x80000000 - 0x807fffff (0x800000) MX[B](B)
---
> 	[0] -1	0xffffffff - 0xffffffff (0x1) MX[B]
> 	[1] -1	0x00000000 - 0x00000000 (0x1) MX[B]
> 	[2] -1	0x000c0000 - 0x000effff (0x30000) MX[B]
> 	[3] -1	0x80865000 - 0x80865fff (0x1000) MX[B]E
> 	[4] -1	0x80864000 - 0x80864fff (0x1000) MX[B]E
> 	[5] -1	0x80940000 - 0x8097ffff (0x40000) MX[B]E
> 	[6] -1	0x80850000 - 0x8085ffff (0x10000) MX[B](B)
> 	[7] -1	0x80000000 - 0x807fffff (0x800000) MX[B](B)
> 	[8] -1	0x80860000 - 0x80863fff (0x4000) MX[B](B)
216a220
> (--) MGA(0): Chipset: "mga2164w" (G400)
219d222
< (--) MGA(0): Chipset: "mga2164w"
221c224
< (--) MGA(0): MMIO registers at 0x80800000
---
> (--) MGA(0): MMIO registers at 0x80860000
226d228
< (II) xf86ReadBIOS(80850000, 0, Buf, 40)-> 55 aa 40 eb...
228c230,232
< (II) xf86ReadBIOS(80850000, 0, Buf, 10000)-> 55 aa 40 eb...
---
> (II) dense base = 0x8600000000
> (II) Truncating PCI BIOS Length to 32768
> (II) dense base = 0x8600000000
241a246
> (II) MGA(0): vgaHWGetIOBase: hwp->IOBase is 0x03d0, hwp->PIOOffset is 0x0000
247c252
< (II) MGA(0): I2C Monitor info: 0x1209f5000
---
> (II) MGA(0): I2C Monitor info: 0x12089e400
281a287
> [monitor modeline errors deleted]
< (--) MGA(0): Display dimensions: (30, 23) cm
---
> (--) MGA(0): Display dimensions: (300, 230) mm
327c367
< 	[1] 0	0x80800000 - 0x80803fff (0x4000) MX[B]
---
> 	[1] 0	0x80860000 - 0x80863fff (0x4000) MX[B]
329,337c369,377
< 	[3] -1	0x80800000 - 0x80803fff (0x4000) MX[B](B)
< 	[4] -1	0xffffffff - 0xffffffff (0x1) MX[B]
< 	[5] -1	0x00000000 - 0x00000000 (0x1) MX[B]
< 	[6] -1	0x000c0000 - 0x000effff (0x30000) MX[B]
< 	[7] -1	0x80865000 - 0x80865fff (0x1000) MX[B]E
< 	[8] -1	0x80864000 - 0x80864fff (0x1000) MX[B]E
< 	[9] -1	0x80940000 - 0x8097ffff (0x40000) MX[B]E
< 	[10] -1	0x80850000 - 0x8085ffff (0x10000) MX[B](B)
< 	[11] -1	0x80000000 - 0x807fffff (0x800000) MX[B](B)
---
> 	[3] -1	0xffffffff - 0xffffffff (0x1) MX[B]
> 	[4] -1	0x00000000 - 0x00000000 (0x1) MX[B]
> 	[5] -1	0x000c0000 - 0x000effff (0x30000) MX[B]
> 	[6] -1	0x80865000 - 0x80865fff (0x1000) MX[B]E
> 	[7] -1	0x80864000 - 0x80864fff (0x1000) MX[B]E
> 	[8] -1	0x80940000 - 0x8097ffff (0x40000) MX[B]E
> 	[9] -1	0x80850000 - 0x8085ffff (0x10000) MX[B](B)
> 	[10] -1	0x80000000 - 0x807fffff (0x800000) MX[B](B)
> 	[11] -1	0x80860000 - 0x80863fff (0x4000) MX[B](B)
349a390
> (II) MGA(0): vgaHWGetIOBase: hwp->IOBase is 0x03d0, hwp->PIOOffset is 0x0000
378a420,458
> [keyboard stuff deleted]
> GetModeLine - scrn: 0 clock: 65000
> GetModeLine - hdsp: 1024 hbeg: 1048 hend: 1184 httl: 1344
>               vdsp: 768 vbeg: 771 vend: 777 vttl: 806 flags: 10