# Sapphire X1650 Pro Video Card: 3D Acceleration Slow [SOLVED]

## don quixada

Can anyone help me with 3D acceleration for my Sapphire X1650 Pro (PCI-E) video card? I'm using the latest ~AMD64 of the fglrx drivers, but still Neverball and Neverputt are unplayable (even at the lowest graphics settings). I tested the frame rate with glxgears but it shows around 900 fps so that's no help.

I'm beginning to suspect it's not a video problem but something else, but I have no idea what it is. I will say that I have 'evdev' loaded, but have never gotten it to work properly.

TIA.

dqLast edited by don quixada on Sun Oct 12, 2008 1:25 am; edited 1 time in total

----------

## alex.blackbit

hi,

i have a very similar setup and problems too.

what does 

```
grep -E "(^\(WW\)|^\(EE\)|^\(NI\)|^\(??\))" /var/log/Xorg.0.log
```

 say? maybe you should define yourself an alias for that in your shell rc file, you will need that again.

edited for readability.Last edited by alex.blackbit on Wed Oct 08, 2008 1:43 pm; edited 1 time in total

----------

## DirtyHairy

Your problems are at least not directly related, as don quixada is using fglrx, while alex.blackbit uses the opensource ati driver. In addition to the errors in the X.org log alex.blackbit asked for, what's the ouput of 

```
glxinfo | grep direct
```

----------

## don quixada

'grep -E "(^\(WW\)|^\(EE\)|^\(NI\)|^\(??\))" /var/log/Xorg.0.log' says:

```
(WW) The directory "/usr/share/fonts/TTF/" does not exist.

(WW) The directory "/usr/share/fonts/OTF" does not exist.

(WW) Open ACPI failed (/var/run/acpid.socket) (No such file or directory)

(WW) fglrx: No matching Device section for instance (BusID PCI:1:0:1) found

(WW) fglrx: No matching Device section for instance (BusID PCI:1:0:1) found

(WW) Warning, couldn't open module dri

(EE) fglrx: Failed to load module "dri" (module does not exist, 0)

(WW) fglrx(0): Failed to load DRI module

(WW) fglrx(0): Cannot resolve drmOpen symbol.

(WW) fglrx(0): board is an unknown third party board, chipset is supported

(WW) fglrx(0): Only one display is connnected,so single mode is enabled

(WW) fglrx(0): No DRM connection for driver fglrx.

(EE) fglrx(0): DRI module is not loaded.

(WW) fglrx(0): ***********************************************

(WW) fglrx(0): * DRI initialization failed!                  *

(WW) fglrx(0): * (maybe driver kernel module missing or bad) *

(WW) fglrx(0): * 2D acceleraton available (MMIO)             *

(WW) fglrx(0): * no 3D acceleration available                *

(WW) fglrx(0): ********************************************* *

(WW) fglrx(0): Textured Video not supported without DRI enabled.

(EE) fglrx(0): XMM failed to open CMMQS connection.
```

I recently added

```
Section "dri"

        Mode 0666

EndSection
```

into my xorg.conf, but as you can see it doesn't make a difference.

I never tried the RadeonHD drivers since they do not have 3D acceleration.

'glxinfo | grep direct' says:

```
OpenGL renderer string: Mesa GLX Indirect
```

Also 'eselect opengl list' says:

```
Available OpenGL implementations:

  [1]   ati *

  [2]   xorg-x11
```

Oh, and in case you're wondering my kernel is the latest vanilla AMD64 one (2.6.27-gentoo-r7).

Thanks.

dq

----------

## don quixada

Hmmm, I just noticed that I had '-dri' in my make.conf; I remember doing this a few months ago when X suddenly stopped working. Rebuilding with Xorg '-dri' in it seemed to fix the problem. I can't remember how I got to that conclusion, but I think it was a bug. I'll try rebuilding with 'dri' as a use flag and report back-- maybe the bug is fixed...

dq

----------

## cyrillic

 *don quixada wrote:*   

> I never tried the RadeonHD drivers since they do not have 3D acceleration. 

 

3D is supported for the r5xx chips, but not yet for the r6xx or r7xx chips.

----------

## alex.blackbit

as cyrillic said, accelerated 3d support is != null in the foss ati drivers.

http://www.x.org/wiki/RadeonFeature

----------

## don quixada

But how can I find what chip I have? I think it's not supported because I looked into it earlier. Unfortunately I have no "paper-trail"...

dq

----------

## alex.blackbit

the radeon x1650 belongs to the R520 series.

x.org says R500.

----------

## don quixada

No change when compiling-in the 'dri' into Xorg. No change when I changed to the RadeonHD driver. I set-up xorg.conf as per the gentoo-wiki instructions. Output of 'grep -E "(^\(WW\)|^\(EE\)|^\(NI\)|^\(??\))" /var/log/Xorg.0.log':

```
(WW) The directory "/usr/share/fonts/TTF/" does not exist.

(WW) The directory "/usr/share/fonts/OTF" does not exist.

(WW) Open ACPI failed (/var/run/acpid.socket) (No such file or directory)

(WW) RADEONHD: No matching Device section for instance (BusID PCI:1:0:1) found

(WW) RADEONHD(0): rhdAtomAllocateFbScratch: FW FB scratch area 536850432 (size: 20480) extends beyond available framebuffer size 268435456
```

'glxinfo | grep direct':

```
direct rendering: No

OpenGL renderer string: Mesa GLX Indirect
```

glxgears reports ~935 fps.

dq

----------

## cyrillic

One thing you will need in the kernel (and the wiki forgot to mention this) is the radeon DRI driver.

```
Device Drivers  --->

  Graphics support  --->

    <M> Direct Rendering Manager (XFree86 4.1.0 and higher DRI support)  --->

      <M>   ATI Radeon 
```

If you are missing this, or if your kernel is not recent enough, then you will only get 2D acceleration and not 3D.

What you want to see is something like this.

```
drmOpenDevice: node name is /dev/dri/card0

drmOpenDevice: open result is 8, (OK)

drmOpenDevice: node name is /dev/dri/card0

drmOpenDevice: open result is 8, (OK)

drmOpenByBusid: Searching for BusID pci:0000:01:00.0

drmOpenDevice: node name is /dev/dri/card0

drmOpenDevice: open result is 8, (OK)

drmOpenByBusid: drmOpenMinor returns 8

drmOpenByBusid: drmGetBusid reports pci:0000:01:00.0

(II) [drm] DRM interface version 1.3

(II) [drm] DRM open master succeeded.

(II) RADEONHD(0): [drm] Using the DRM lock SAREA also for drawables.

(II) RADEONHD(0): [drm] framebuffer handle = 0xe0000000

(II) RADEONHD(0): [drm] added 1 reserved context for kernel

(II) RADEONHD(0): X context handle = 0x1

(II) RADEONHD(0): [drm] installed DRM signal handler

(II) RADEONHD(0): [pci] 16384 kB allocated with handle 0x0851e200

(II) RADEONHD(0): [pci] ring handle = 0x2efff000

(II) RADEONHD(0): [pci] Ring mapped at 0x7f415916f000

(II) RADEONHD(0): [pci] Ring contents 0x00000000

(II) RADEONHD(0): [pci] ring read ptr handle = 0x1f000000

(II) RADEONHD(0): [pci] Ring read ptr mapped at 0x7f416d018000

(II) RADEONHD(0): [pci] Ring read ptr contents 0x00000000

(II) RADEONHD(0): [pci] vertex/indirect buffers handle = 0x2f000000

(II) RADEONHD(0): [pci] Vertex/indirect buffers mapped at 0x7f4158f6f000

(II) RADEONHD(0): [pci] Vertex/indirect buffers contents 0x00000000

(II) RADEONHD(0): [pci] GART texture map handle = 0x2f001000

(II) RADEONHD(0): [pci] GART Texture map mapped at 0x7f41583af000

(II) RADEONHD(0): [drm] register handle = 0xf9000000

(II) RADEONHD(0): [dri] Visual configs initialized

(II) RADEONHD(0): [DRI] installation complete

(II) RADEONHD(0): [drm] Added 32 65536 byte vertex/indirect buffers

(II) RADEONHD(0): [drm] Mapped 32 vertex/indirect buffers

(II) RADEONHD(0): [drm] dma control initialized, using IRQ 16

(II) RADEONHD(0): [drm] Initialized kernel GART heap manager, 12320768

(II) RADEONHD(0): Direct rendering enabled

(II) RADEONHD(0): Using accelerated EXA DownloadFromScreen hook; GART location = 0xf0000000

... 
```

----------

## DirtyHairy

Glxinfo shows that accelerated 3D is not enabled. You might want to try 

```
emerge -N world
```

 after readding the dri use flag to make.conf; I'm pretty sure that DRI not being properly set up is the cause of your problem. Also, you have to add 

```
Load "dri"
```

 to the modules section in your Xorg.conf file (if it isn't already there). Fglrx works fine for me apart from some really borked driver versions, while I have yet to get any useful 3D acceleration out of the open source drivers (mobility X1300).

----------

## don quixada

I tried the 'emerge -ND world' previously, but there was no change. I forgot to add 'Load "dri"' though (I should know better!) but still there is no change in the 3d acceleration, i.e. Neverball is still slow. Now all that shows-up as warning messages in the Xorg log are:

```
(WW) Open ACPI failed (/var/run/acpid.socket) (No such file or directory)

(WW) RADEONHD: No matching Device section for instance (BusID PCI:1:0:1) found

(WW) RADEONHD(0): rhdAtomAllocateFbScratch: FW FB scratch area 536850432 (size: 20480) extends beyond available framebuffer size 268435456
```

I seem to get slightly faster glxgears (>1000 fps).

dq

----------

## DirtyHairy

Unless the glxinfo output has changed, acceleration is NOT enabled for you yet; glxgears FPS are no indicator (modern CPUs can give you quite high glxgears FPS). Also take a look at http://www.x.org/wiki/radeonhd, unless you are running the latest git version (and at least unstable mesa), you won't get 3D out of it. Also, afaik 3D is still in flux for radeonhd, so your mileage may vary.

3D support in x11-drivers/xf86-video-ati is alot better, so you also might want to try this. However, still, as ATI only released the docs less than a year ago, this support is still very fresh and bugs lurk around, so you should be again sure to use unstable video-ati/X.org/mesa etc.

What about fglrx; did you retry if it works after enable USE=dri and loading the dri module in xorg.conf correctly?

----------

## don quixada

I did try fglrx again once the 'Load "dri"' was included in xorg.conf but no dice. What is the x11-drivers/xf86-video-ati driver name in xorg.conf? If it is 'ati' then I can tell you right now that it didn't work back in December when I built this machine. I can try it again though.

I'll try the ~ version of mesa/ video-ati, I'm a little leary of going to the unstable Xorg though-- who knows how many other programs it'll affect and what other programs it is dependant on need to be at ~ too...

dq

----------

## DirtyHairy

Try it; "ati" has only gotten R500 3D support over the last 10 months. Regarding fglrx: is the kernel module loaded; what's the output of 

```
lsmod
```

If it isn't: does it load when doing 

```
modprobe fglrx
```

If it doesn't: what's the error (if any, see dmesg), and did you build the module for your current kernel? If you are in doubt on this one, reemerge ati-drivers, ensuring that /usr/src/linux points to the correct sources. If this fails, make sure that you are running a kernel version supported by the module.

Also, you can't use fglrx if you build another DRM driver into the kernel.

----------

## don quixada

Ok, I solved it, but it was silly! (Really, I think I'm losing it!) Anyway, I had upgraded to a new kernel in order to try and fix this, but I forgot to change the /usr/src/linux symlink when I rebuilt ati-drivers. Argh! So now it works!! Thanks very much for all of your help! 

I'm still curious though at what all these warning messages are:

```
(WW) Open ACPI failed (/var/run/acpid.socket) (No such file or directory)

(WW) fglrx: No matching Device section for instance (BusID PCI:1:0:1) found

(WW) fglrx: No matching Device section for instance (BusID PCI:1:0:1) found

(WW) fglrx(0): board is an unknown third party board, chipset is supported

(WW) fglrx(0): Only one display is connnected,so single mode is enabled

(WW) AIGLX: 3D driver claims to not support visual 0x23

(WW) AIGLX: 3D driver claims to not support visual 0x24

(WW) AIGLX: 3D driver claims to not support visual 0x25

(WW) AIGLX: 3D driver claims to not support visual 0x26

(WW) AIGLX: 3D driver claims to not support visual 0x27

(WW) AIGLX: 3D driver claims to not support visual 0x28

(WW) AIGLX: 3D driver claims to not support visual 0x29

(WW) AIGLX: 3D driver claims to not support visual 0x2a

(WW) AIGLX: 3D driver claims to not support visual 0x2b

(WW) AIGLX: 3D driver claims to not support visual 0x2c

(WW) AIGLX: 3D driver claims to not support visual 0x2d

(WW) AIGLX: 3D driver claims to not support visual 0x2e

(WW) AIGLX: 3D driver claims to not support visual 0x2f

(WW) AIGLX: 3D driver claims to not support visual 0x30

(WW) AIGLX: 3D driver claims to not support visual 0x31

(WW) AIGLX: 3D driver claims to not support visual 0x32

(WW) AIGLX: 3D driver claims to not support visual 0x33

(WW) AIGLX: 3D driver claims to not support visual 0x34

(WW) AIGLX: 3D driver claims to not support visual 0x35

(WW) AIGLX: 3D driver claims to not support visual 0x36

(WW) AIGLX: 3D driver claims to not support visual 0x37

(WW) AIGLX: 3D driver claims to not support visual 0x38

(WW) AIGLX: 3D driver claims to not support visual 0x39

(WW) AIGLX: 3D driver claims to not support visual 0x3a

(WW) AIGLX: 3D driver claims to not support visual 0x3b

(WW) AIGLX: 3D driver claims to not support visual 0x3c

(WW) AIGLX: 3D driver claims to not support visual 0x3d

(WW) AIGLX: 3D driver claims to not support visual 0x3e

(WW) AIGLX: 3D driver claims to not support visual 0x3f

(WW) AIGLX: 3D driver claims to not support visual 0x40

(WW) AIGLX: 3D driver claims to not support visual 0x41

(WW) AIGLX: 3D driver claims to not support visual 0x42

(WW) AIGLX: 3D driver claims to not support visual 0x43

(WW) AIGLX: 3D driver claims to not support visual 0x44

(WW) AIGLX: 3D driver claims to not support visual 0x45

(WW) AIGLX: 3D driver claims to not support visual 0x46

(WW) AIGLX: 3D driver claims to not support visual 0x47

(WW) AIGLX: 3D driver claims to not support visual 0x48

(WW) AIGLX: 3D driver claims to not support visual 0x49

(WW) AIGLX: 3D driver claims to not support visual 0x4a

(WW) AIGLX: 3D driver claims to not support visual 0x4b

(WW) AIGLX: 3D driver claims to not support visual 0x4c

(WW) AIGLX: 3D driver claims to not support visual 0x4d

(WW) AIGLX: 3D driver claims to not support visual 0x4e

(WW) AIGLX: 3D driver claims to not support visual 0x4f

(WW) AIGLX: 3D driver claims to not support visual 0x50

(WW) AIGLX: 3D driver claims to not support visual 0x51

(WW) AIGLX: 3D driver claims to not support visual 0x52

(WW) AIGLX: 3D driver claims to not support visual 0x53

(WW) AIGLX: 3D driver claims to not support visual 0x54

(WW) AIGLX: 3D driver claims to not support visual 0x55

(WW) AIGLX: 3D driver claims to not support visual 0x56

(WW) AIGLX: 3D driver claims to not support visual 0x57

(WW) AIGLX: 3D driver claims to not support visual 0x58

(WW) AIGLX: 3D driver claims to not support visual 0x59

(WW) AIGLX: 3D driver claims to not support visual 0x5a

(WW) AIGLX: 3D driver claims to not support visual 0x5b

(WW) AIGLX: 3D driver claims to not support visual 0x5c

(WW) AIGLX: 3D driver claims to not support visual 0x5d

(WW) AIGLX: 3D driver claims to not support visual 0x5e

(WW) AIGLX: 3D driver claims to not support visual 0x5f

(WW) AIGLX: 3D driver claims to not support visual 0x60

(WW) AIGLX: 3D driver claims to not support visual 0x61

(WW) AIGLX: 3D driver claims to not support visual 0x62

(WW) AIGLX: 3D driver claims to not support visual 0x63

(WW) AIGLX: 3D driver claims to not support visual 0x64

(WW) AIGLX: 3D driver claims to not support visual 0x65

(WW) AIGLX: 3D driver claims to not support visual 0x66

(WW) AIGLX: 3D driver claims to not support visual 0x67

(WW) AIGLX: 3D driver claims to not support visual 0x68

(WW) AIGLX: 3D driver claims to not support visual 0x69

(WW) AIGLX: 3D driver claims to not support visual 0x6a

(WW) AIGLX: 3D driver claims to not support visual 0x6b

(WW) AIGLX: 3D driver claims to not support visual 0x6c

(WW) AIGLX: 3D driver claims to not support visual 0x6d

(WW) AIGLX: 3D driver claims to not support visual 0x6e

(WW) AIGLX: 3D driver claims to not support visual 0x6f

(WW) AIGLX: 3D driver claims to not support visual 0x70

(WW) AIGLX: 3D driver claims to not support visual 0x71

(WW) AIGLX: 3D driver claims to not support visual 0x72
```

Also, just FYI. I tried the 'ati' driver but it still didn't work. And RadeonHD the drivers still don't really work, so I'm wondering what's up there. But at least I now have 3D acceleration!

Thanks.

dq

----------

## DirtyHairy

You're welcome!

Dunno about the error messages, I guess they are harmless. If you are interested in the current state of the two opensource drivers, you can find a lot of information in the relavant thread in the www.phoronix.com forum.

----------

