Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 246513 - x11-drivers/nvidia-drivers + >=kernel-2.6.26 - X86_PAT yields terrible performance on nvidia G80 and newer cards
Summary: x11-drivers/nvidia-drivers + >=kernel-2.6.26 - X86_PAT yields terrible perfor...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Unspecified (show other bugs)
Hardware: AMD64 Linux
: High minor (vote)
Assignee: Ricardo Mendoza (RETIRED)
URL: http://www.nvnews.net/vbulletin/showt...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-11-12 16:58 UTC by nick
Modified: 2009-08-03 03:53 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description nick 2008-11-12 16:58:44 UTC
disable pat from kernel via nopat kernel command OR

simply put 

 NVreg_UsePageAttributeTable=0  in /etc/modprobe.conf  in nvidia section


Posting here so people can find this easily, its been documented on nvnews since august, but it still took me and others 3 months to find.

Reproducible: Always

Steps to Reproduce:
1. 2.6.26 kernel or newer
2. enable X86_PAT
3. build nvidia-drivers normally

Actual Results:  
Terrible GL performance, terrible


DISABLE X86_PAT or put the  NVreg_UsePageAttributeTable=0 in modprobe.conf to overcome this.


I know this isnt gentoo related, but since nvidia won't comment on it, here you can overcome it.
Comment 1 nick 2008-11-12 17:01:23 UTC
Portage 2.2_rc13 (default-linux/amd64/2007.0, gcc-4.3.1, glibc-2.8_p20080602-r0, 2.6.26-gentoo x86_64)
=================================================================
System uname: Linux-2.6.26-gentoo-x86_64-AMD_Phenom-tm-_8400_Triple-Core_Processor-with-glibc2.2.5
Timestamp of tree: Thu, 06 Nov 2008 03:50:01 +0000
app-shells/bash:     3.2_p39
dev-java/java-config: 1.3.7, 2.1.6
dev-lang/python:     2.4.4-r6, 2.5.2-r7
dev-python/pycrypto: 2.0.1-r6
dev-util/cmake:      2.4.8
sys-apps/baselayout: 2.0.0
sys-apps/openrc:     0.2.4-r1
sys-apps/sandbox:    1.2.18.1-r3
sys-devel/autoconf:  2.13, 2.62-r1
sys-devel/automake:  1.5, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.1-r1
sys-devel/binutils:  2.18-r3
sys-devel/gcc-config: 1.4.0-r4
sys-devel/libtool:   2.2.4
virtual/os-headers:  2.6.25-r4
ACCEPT_KEYWORDS="amd64 ~amd64"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=k8 -O2 -pipe -fomit-frame-pointer"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/kde/4.0/env /usr/kde/4.0/share/config /usr/kde/4.0/shutdown /usr/share/config"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/terminfo /etc/udev/rules.d"
CXXFLAGS="-march=k8 -O2 -pipe -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="distlocks parallel-fetch preserve-libs protect-owned sandbox sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS="http://gentoo.osuosl.org/ ftp://ftp.gtlib.gatech.edu/pub/gentoo http://www.gtlib.gatech.edu/pub/gentoo ftp://mirror.iawnet.sandia.gov/pub/gentoo/ ftp://ftp.ussg.iu.edu/pub/linux/gentoo ftp://ftp.ucsb.edu/pub/mirrors/linux/gentoo/ http://ftp.ucsb.edu/pub/mirrors/linux/gentoo/ http://cudlug.cudenver.edu/gentoo/ http://gentoo.mirrors.pair.com/ ftp://gentoo.mirrors.pair.com/ http://gentoo.mirrors.tds.net/gentoo ftp://gentoo.mirrors.tds.net/gentoo http://gentoo.netnitco.net ftp://gentoo.netnitco.net/pub/mirrors/gentoo/source/ http://mirror.espri.arizona.edu/gentoo/ http://open-systems.ufl.edu/mirrors/gentoo http://gentoo.llarian.net/ ftp://gentoo.llarian.net/pub/gentoo http://gentoo.binarycompass.org http://mirror.datapipe.net/gentoo ftp://mirror.datapipe.net/gentoo http://prometheus.cs.wmich.edu/gentoo http://mirror.usu.edu/mirrors/gentoo/ http://mirror.mcs.anl.gov/pub/gentoo/ "
LDFLAGS=""
MAKEOPTS="-j4"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/portage/local/layman/armagetron /usr/portage/local/layman/enlightenment"
SYNC="rsync://rsync.namerica.gentoo.org/gentoo-portage"
USE="3dnow X a52 aac aalib acl acpi alsa amd64 bash-completion berkdb bzip2 chroot cli cracklib crypt css cups dbus dga dhcp dri dv dvdr dvdread encode exif ffmpeg firefox flac fortran fping gdbm ghmod gif glew gpac gpm gstreamer gtk guitarhero hal iconv ipod ipv6 isdnlog jack jpeg kde kdehiddenvisibility lame libcaca libsamplerate libwww logitech-mouse logrotate md5sum midi mmx mng mp3 mp4 mpeg mplayer mudflap ncurses nls nptl nptlonly nsplugin nvidia ogg opengl openmp oss pam pcre pdf perl png pppd python qt3 qt4 quicktime readline reflection samba sdl session smp sndfile sox spell spl sqlite3 sse sse2 ssl subtitles svg syslog tcpd threads tiff tk truetype unicode v4l vcd vorbis wavpack wma wmf x264 xcomposite xine xinerama xml xorg xv xvid xvmc yv12 zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x 	ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 	trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" USERLAND="GNU" VIDEO_CARDS="nvidia"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LANG, LC_ALL, LINGUAS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 2 mkzelda 2008-11-17 21:29:46 UTC
Thank you! I've been pulling my hair out trying to figure out why my gl performance was terrible, terrible. While getting 1000fps my games were unplayable due to choppiness. I have been searching all the forums for a while now but I couldn't find anything because I didn't know what I was looking for.

I can confirm this fixes my problems on two machines.
1 AMD FX-53, Asus A8NSLI-32 Deluxe, nvidia 7800gt
1 AMD Phenom 9550, ASRock K10N780SLIX3-WiFi, nvidia 9800gt

It might not be a benchmark, but glxgears goes from stuttering, fluctuating 6000-9000 FPS, to a consistent 17800 FPS on the 9800gt.

The 7800gt is unaffected by the problem (cant use PAT I presume), but I previously had the 9800gt on the Asus motherboard, and had the problem. I actually bought the phenom rig because I thought the problem was a pci-e 2 card on a 1 board. I've tested the 9800gt on the Asus board since with PAT disabled and it works nicely.

I wasn't aware that this was the place to find my fix but I'll take it. 

* Perhaps an ebuild post install message could be added for others to benefit from this knowledge until problems with PAT are resolved?
 
Comment 3 Søren Færløv 2008-11-18 10:12:09 UTC
I suspect maybe only AMD systems are affected by this unwanted behaviour.

I haven't noticed this choppiness on my Intel systems. All problems reported on nvnews' forums has been on AMD systems as well (IIRC).

I just thought I'd mention this to help locate the problem.
Comment 4 Doug Goldstein (RETIRED) gentoo-dev 2009-08-03 03:53:47 UTC
This was caused by the way the kernel handles the x86 PAT and handles the workarounds for different errata. With kernel 2.6.30 and nvidia-drivers-185.x.y, the issue should be resolved.... FINALLY.

Sorry it took so long to get some resolution on this.