Cool VL Viewer forum

View unanswered posts | View active topics It is currently 2024-03-19 10:33:39



This topic is locked, you cannot edit posts or make further replies.  [ 21 posts ]  Go to page Previous  1, 2, 3  Next
Observations on framerate 
Author Message

Joined: 2020-07-08 23:18:37
Posts: 34
Henri Beauchamp wrote:
KJ_Eno wrote:
"__GL_THREADED_OPTIMIZATIONS=auto" has an equivalent function in Mesa called "__mesa_glthread=true". The result appears to cause the frame rate to be more stable. I didn't notice any loss in frame rate, but it wasn't more than a 1 or 2 fps improvement at best.
I found no reference whatsoever about a "__mesa_glthread" environment variable for Mesa, but I found multiple references on the Web to "mesa_glthread"... But only for Wine games !... Be careful about placebo effects (which would be the case with__mesa_glthread) ! :lol:

See the Mesa environment variables chapter from its official documentation.

I'm glad you caught my mistake. I looked at the information available again, tested with and without "export mesa_glthread=true". I had to come to the conclusion that there was no difference either way. And that is how we learn sometimes! :)


2020-07-27 12:08:22
Profile

Joined: 2020-07-08 23:18:37
Posts: 34
KJ_Eno wrote:
Henri Beauchamp wrote:
Please be aware that whatever the viewer in use under Linux, they all are X11 applications, not Wayland ones (and AFAIK Gnome 3+ is fond of Wayland)... Be also wary of compositors, that are known to ruin OpenGL drivers (it's best not using one at all !).

I logged into a Wayland session for Ubuntu (Gnome). It was a different experience. I may need to experiment more with it [...]

KDE's Plasma has a Wayland session option. The version of Plasma in Open Mandriva Lx 4.1 is rather recent and more representative of the current state of the technology than Ubuntu 18.04 (Gnome) was. Nvidia users have no way to confirm this, but Cool VL Viewer (and Second Life viewers in general) run under Wayland just fine. I'm using Cool VL Viewer right now, without any issues.


2020-07-31 22:33:37
Profile

Joined: 2009-03-17 18:42:51
Posts: 5523
KJ_Eno wrote:
KJ_Eno wrote:
Cool VL Viewer (and Second Life viewers in general) run under Wayland just fine. I'm using Cool VL Viewer right now, without any issues.
I doubt the primary clipboard (left-click and drag on text to "copy" and middle-click to paste) would work under Wayland (it's a Xlib protocol that, AFAIK, Wayland does not emulate). I also doubt Xlib would be successfully initialized in a thread-safe state (easy to check with the Cool VL Viewer since there is a log message for it), meaning NVIDIA drivers would fail to run in multi-threaded mode, causing a 20-30% frame rate loss compared with genuine X11, supposing you would be at all able to use OpenGL under Wayland with NVIDIA drivers...


2020-07-31 23:10:13
Profile WWW

Joined: 2020-07-08 23:18:37
Posts: 34
Middle-click paste only works within an application. However, CTRL-c & v work between applications. For example, I click the button "Copy this information to the clipboard" in Cool VL Viewer and CTRL-v here:

Cool VL Viewer v1.28.0.3, 64 bits, Jul 19 2020 11:25:08
RestrainedLove viewer v2.09.27.23
Release Notes

You are at 156845.5, 318114.9, 21.7 in Alexanderia located at
sim10084.agni.lindenlab.com (216.82.48.150:13000)
Second Life Server 2020-07-10T18:46:54.544832
Release Notes

CPU: AMD Ryzen 3 1300X Quad-Core Processor (3336.55 MHz)
Memory: 16026MB
OS version: Linux-x86_64 v5.5.12-desktop-1omv4001 #1 SMP Fri Mar 27 17:10:50 UTC 2020
Memory manager: jemalloc v5.2.1-20200716
Graphics card vendor: X.Org
Graphics card: Radeon RX 580 Series (POLARIS10, DRM 3.36.0, 5.5.12-desktop-1omv4001, LLVM 9.0.1)
OpenGL version: 4.6 (Compatibility Profile) Mesa 20.0.7
Detected VRAM: 7596MB
J2C decoder: OpenJPEG: 1.4.0.635f
Audio driver: FMOD Studio v2.01.02 (PulseAudio)
Networking backend: libcurl/7.47.0 OpenSSL/1.0.2u zlib/1.2.11
Embedded browser: CEF3 plugin v74.1.19+gb62bacf+chromium-74.0.3729.157
Packets lost: 0/12962 (0.0%)

Built with: GCC v9.3.0
Compiler-generated maths: AVX2.

Compile flags used for this build:
-O3 -fno-delete-null-pointer-checks -falign-functions=16 -falign-jumps=16 -fno-align-labels -fno-align-loops -fno-ipa-cp-clone -fsched-pressure -frename-registers -fweb -fira-hoist-pressure -DNDEBUG -march=native -std=c++11 -fPIC -pipe -g -gdwarf-2 -gstrict-dwarf -fno-var-tracking-assignments -fexceptions -fno-strict-aliasing -fvisibility=hidden -fsigned-char -m64 -mfpmath=sse -fno-math-errno -fno-trapping-math -pthread -fno-stack-protector -Wall -Wno-reorder -Wno-unused-local-typedefs -Wno-deprecated-declarations -Wno-unused-variable -Wno-placement-new -Wno-parentheses -DLL_LINUX=1 -D_REENTRANT -D_GLIBCXX_USE_CXX11_ABI=0 -DXML_STATIC -DLL_USE_JEMALLOC=1 -DLL_ELFBIN=1 -DLL_LUA=1 -DOV_EXCLUDE_STATIC_CALLBACKS -DLL_FMOD=1 -DLL_OPENAL=1 -DLL_SDL=1 -DLIB_NDOF=1 -DLL_X11=1

And no, I wouldn't expect Nvidia drivers to work with Wayland. I was simply saying that the current state of open source has reached a point where viewers for Second Life can work with XWayland.


2020-08-01 02:25:38
Profile

Joined: 2009-03-17 18:42:51
Posts: 5523
KJ_Eno wrote:
Middle-click paste only works within an application. However, CTRL-c & v work between applications. For example, I click the button "Copy this information to the clipboard" in Cool VL Viewer and CTRL-v
This is the secondary clipboard (akin do Windows' clipboard), and it is normal that it works ! As for the "only works within an application" primary clipboard, it is probably because the Cool VL Viewer is automatically falling back to a pseudo-primary clipboard (that only works within the viewer text areas), that I precisely implemented for OSes without a genuine primary clipboard...

Having two independent clipboards under Linux (and one that works with just the mouse) is an immense advantage that I'm using dozens of times every single day (and of course, between applications, not just within each single application) !... Not having it available would be an unacceptable impairment to my workflow.

Quote:
And no, I wouldn't expect Nvidia drivers to work with Wayland. I was simply saying that the current state of open source has reached a point where viewers for Second Life can work with XWayland.
XWayland is still, far, far, far away from an even acceptable status... In any case, I won't provide any support for bugs found while running the viewer under it, for they would likely be XWayland bugs !


2020-08-01 08:14:11
Profile WWW

Joined: 2020-07-08 23:18:37
Posts: 34
I don't want to go off topic on the EEP thread in the SL community forum, so I'll put my observations here.

I went to a rezzed prim at 3600m in a sim not connected to the mainland. Within the draw distance of 128 meters there were only 2 prims and my avatar. I turned off shadows, and to my knowledge I'm using as close to the same settings for rendering in both Cool VL Viewer 1.28.0.6 and Firestorm 6.4.8, both compiled with Ubuntu 16.04 (the compiling instructions for Firestorm on Linux now recommend that distribution). I'm still running both viewers on OpenMandriva Lx 4.1 Zen/Rock KDE (no Wayland).

Under these conditions, I get 123 fps in Firestorm and 95 (115) fps in Cool VL Viewer with cull water enabled (disabled). Enabling shadows reduces the framerate in both to a proportional degree with midday environment settings. I find that this difference between the viewers scales proportionally in most other locations. I really want to have a solution to this because there are many situations where I prefer to be using Cool VL Viewer. Any thoughts? :?:

Code:
Cool VL Viewer v1.28.0.6, 64 bits, Aug 22 2020 07:22:24
RestrainedLove viewer v2.09.27.23
Release Notes

You are at 246505.6, 336315.9, 3601.3  in Paradise Hills located at
sim10356.agni.lindenlab.com (216.82.50.78:12035)
Second Life Server 2020-08-08T03:54:43.546455
Release Notes

CPU: AMD Ryzen 3 1300X Quad-Core Processor (3271.32 MHz)
Memory: 16026MB
OS version: Linux-x86_64 v5.5.12-desktop-1omv4001 #1 SMP Fri Mar 27 17:10:50 UTC 2020
Memory manager: jemalloc v5.2.1-20200807
Graphics card vendor: X.Org
Graphics card: Radeon RX 580 Series (POLARIS10, DRM 3.36.0, 5.5.12-desktop-1omv4001, LLVM 9.0.1)
OpenGL version: 4.6 (Compatibility Profile) Mesa 20.0.7
Detected VRAM: 7910MB
J2C decoder: OpenJPEG: 1.4.0.635f
Audio driver: FMOD Studio v2.01.03 (PulseAudio)
Networking backend: libcurl/7.47.0 OpenSSL/1.0.2u zlib/1.2.11
Embedded browser: CEF3 plugin v74.1.19+gb62bacf+chromium-74.0.3729.157
Packets lost: 0/1567 (0.0%)

Built with: GCC v5.4.0
Compiler-generated maths: AVX2.

Compile flags used for this build:
-O3 -fno-delete-null-pointer-checks -falign-functions=16 -falign-jumps=16 -fno-align-labels -fno-align-loops -fno-ipa-cp-clone -fsched-pressure -frename-registers -fweb -fira-hoist-pressure -DNDEBUG -march=native -std=c++11 -fPIC -pipe -g -gdwarf-2 -gstrict-dwarf -fno-var-tracking-assignments -fexceptions -fno-strict-aliasing -fvisibility=hidden -fsigned-char -m64 -mfpmath=sse -fno-math-errno -fno-trapping-math -pthread -fno-stack-protector -Wall -Wno-reorder -Wno-unused-local-typedefs -Wno-deprecated-declarations -Wno-unused-variable -DLL_LINUX=1 -D_REENTRANT -D_GLIBCXX_USE_CXX11_ABI=0 -DXML_STATIC -DLL_USE_JEMALLOC=1 -DLL_ELFBIN=1 -DLL_LUA=1 -DOV_EXCLUDE_STATIC_CALLBACKS -DLL_FMOD=1 -DLL_OPENAL=1 -DLL_SDL=1 -DLIB_NDOF=1 -DLL_X11=1


Code:
Firestorm 6.4.8 (61751) Aug 19 2020 17:31:05 (64bit) (Firestorm-private)
Release Notes

You are at 233.6, 187.9, 3601.3 in Paradise Hills located at sim10356.agni.lindenlab.com (216.82.50.78:12035)
SLURL: http://maps.secondlife.com/secondlife/Paradise%20Hills/234/188/3601
(global coordinates 246506.0, 336316.0, 3601.3)
Second Life Server 2020-08-08T03:54:43.546455
Release Notes

CPU: AMD Ryzen 3 1300X Quad-Core Processor (1664.32 MHz)
Memory: 16026 MB
OS Version: Linux 5.5.12-desktop-1omv4001 #1 SMP Fri Mar 27 17:10:50 UTC 2020 x86_64
Graphics Card Vendor: X.Org
Graphics Card: Radeon RX 580 Series (POLARIS10, DRM 3.36.0, 5.5.12-desktop-1omv4001, LLVM 9.0.1)

OpenGL Version: 4.6 (Compatibility Profile) Mesa 20.0.7

RestrainedLove API: RLV v3.3.3 / RLVa v2.3.0.61751
libcurl Version: libcurl/7.54.1 OpenSSL/1.0.2l zlib/1.2.8 nghttp2/1.25.0
J2C Decoder Version: OpenJPEG runtime: 1.5.1
Audio Driver Version: FMOD Studio 2.01.03
Dullahan: 1.8.0.202007201635
  CEF: 81.3.10+gb223419+chromium-81.0.4044.138
  Chromium: 81.0.4044.138
LibVLC Version: 2.2.3
Voice Server Version: Vivox 4.6.0017.22050

Settings mode: Firestorm
Viewer Skin: Firestorm (High Contrast)
Window size: 1920x1048 px
Font Used: Deja Vu (96 dpi)
Font Size Adjustment: 0 pt
UI Scaling: 1
Draw distance: 128 m
Bandwidth: 1500 kbit/s
LOD factor: 2
Render quality: High-Ultra (6/7)
Advanced Lighting Model: Yes
Texture memory: 2048 MB (1)
VFS (cache) creation time (UTC): 2020-8-19T1:4:1
Built with GCC version 50400
Packets Lost: 5/4366 (0.1%)
August 23 2020 09:48:26 SLT


2020-08-23 16:56:39
Profile

Joined: 2009-03-17 18:42:51
Posts: 5523
With my main system (9700K @ 5GHz, GTX 1070 Ti), in my skybox (600m altitude in mainland, i.e. with surrounding sims), 256m DD, and 3 avatars on screen, I get 650fps with the Cool VL Viewer in WL mode, 600fps in EE mode. Firestorm v6.3 (WL) barely runs at 400fps and v6.4 (EE) at 250fps in the same conditions... I do not know what is the problem with your system, but I certainly do not get the same results (and your system seems especially (and surprisingly) weak, for 120fps at 3600m and 128m DD (i.e. without anything to render) is something I'd get with one of my old PCs, a Q6600 @ 3.4GHz with a GTX 460 !)...

This said, you are using an AMD card, and there are some work-arounds for AMD OpenGL driver bugs that have been implemented in LL's viewers over years (and that are also in the Cool VL Viewer)... Such work-arounds usually mean lower frame rates. It is possible that the Firestorm team identified some, now useless workarounds and removed them, gaining better frame rates with modern AMD cards/drivers...
You could grep the sources for "AMD" and "ATI" and see in the comments/code if you could disable some of the existing workarounds in the Cool VL Viewer without breaking it for AMD cards (I can't do it myself because I banned AMD/ATI GPUs from all my PCs years ago, and can't therefore test the validity of such changes)...

Also check the VBO settings (VBO streaming and such) and see if they make any difference.

Finally, please bear in mind that the EE renderer is still a work in progress... The difference you get is not huge and could also (but not only) be the result of slightly different shaders/code: the Cool VL Viewer closely tracks LL's latest code, while Firestorm lags behind by weeks if not months: performances may vary with various changes in the shaders and/or render pipeline...

EDIT: oh, one more observation: the two "about" texts report a different frequency for your CPU: do check the CPU frequency while the viewers run: it should be maxed out on the core the viewer is using. If it's not, then it's probably an issue with your frequency/power governor (different loads may trigger different stepping: perhaps the Cool VL Viewer is also making the CPU throttle...). For a fair benchmarking, you should lock all your CPU cores to the max frequency when comparing the viewers (and check that you are not throttling during the benchmark, which would denote a bad cooling of your system)...


2020-08-23 17:45:59
Profile WWW

Joined: 2020-07-08 23:18:37
Posts: 34
Thank you for your observations. I doubt the issue is with the video card. Your CPU runs at 5 GHz and mine is set at 3.575 GHz all cores max in BIOS, a manual overclock of about 75 MHz. I did not win the silicon lottery, but the CPU only cost me US$100 at the time of purchase. Also, Intel IPC is better than that of AMD. Both viewers were running with Gamemode, which automatically adjusts the CPU to performance mode while running, and back to the default (balanced or on-demand in my case) after the program terminates. Firestorm's "About" showed a lower clock rate than Cool VL Viewer's "About," despite showing higher framerates for me, which means that it's a [mostly] useless indicator of system performance. I have KDE panel widgets that show me the current CPU clock, load, temperature, and system RAM usage. I know when the CPU is running in performance mode.

Measurements I made in my previous post were still using Advanced Lighting model, anisotropic filtering, antialiasing, etc., even when the shadows were off. I can provide more detail if needed. My avatar's [probably useless] complexity information is: 58687, 1 rank, VisTris 443.15K, EstMaxTris 424.57K, 102 m^2.

I logged in with Kokua. Framerate in Kokua 6.4.6 RLV (from the official Kokua release, not compiled by me): ~120 fps using ALM (no shadows), anisotropic filtering, antialiasing, etc.
Code:
Kokua Release RLV 6.4.6.48941 (64bit)
Release Notes

You are at 233.6, 187.9, 3601.3 in Paradise Hills located at sim10356.agni.lindenlab.com (216.82.50.78:12035)
SLURL: http://maps.secondlife.com/secondlife/Paradise%20Hills/234/188/3601
(global coordinates 246506.0, 336316.0, 3601.3)
Second Life Server 2020-08-08T03:54:43.546455
Release Notes

CPU: AMD Ryzen 3 1300X Quad-Core Processor (3472.33 MHz)
Memory: 16026 MB
OS Version: Linux 5.5.12-desktop-1omv4001 #1 SMP Fri Mar 27 17:10:50 UTC 2020 x86_64
Graphics Card Vendor: X.Org
Graphics Card: Radeon RX 580 Series (POLARIS10, DRM 3.36.0, 5.5.12-desktop-1omv4001, LLVM 9.0.1)

OpenGL Version: 4.6 (Compatibility Profile) Mesa 20.0.7

Window size: 1920x1048
Font Size Adjustment: 96pt
UI Scaling: 1
Draw distance: 128m
Bandwidth: 3000kbit/s
LOD factor: 3
Render quality: 5
Advanced Lighting Model: Enabled
Texture memory: 2048MB
VFS (cache) creation time: August 23 2020 14:29:51

RestrainedLove API: RestrainedLove viewer v2.09.27.00 (6.4.6)
J2C Decoder Version: KDU v8.0.5
Audio Driver Version: FMOD Studio 2.01.01
CEF-Version: Dullahan: 1.1.1320
  CEF: 3.3626.1895.g7001d56
  Chromium: 72.0.3626.121
LibVLC Version: 2.2.3
Voice Server Version: Vivox

Built with GCC version 50400
Packets Lost: 0/12374 (0.0%)
August 23 2020 14:30:20

Aside from comparing hardware, kernels, drivers, desktop environments, window managers, etc., what about Kokua and Firestorm allow them to run faster than Cool VL Viewer? Kokua uses KDU v8.0.5, and my compiled Firestorm uses OpenJPEG 1.5.1. Cool VL Viewer uses OpenJPEG 1.4.0. Does that matter? Are there any other precompiled libraries that might have an effect on performance?


2020-08-23 22:47:55
Profile

Joined: 2009-03-17 18:42:51
Posts: 5523
KJ_Eno wrote:
Thank you for your observations. I doubt the issue is with the video card.
It is a possibility. Especially with Mesa as the drivers... Did you try AMD's proprietary drivers ?

But the more I look at it, the more I think your problem is with the CPU frequency scaling, since you see a difference opposite to what it should be when the rendering load is low (FYI I tried your method in an empty sim (on Aditi) and 3600m high and 256m DD: the Cool VL Viewer runs at 1000+ fps when Firestorm is at 500 !...).

Quote:
Your CPU runs at 5 GHz and mine is set at 3.575 GHz all cores max in BIOS, a manual overclock of about 75 MHz.
Linux overrides the BIOS settings for the CPU frequency scaling (only the max frequency/multiplier set in the BIOS is used for the max frequency). In order to lock my cores permanently at 5GHz under Linux, I must pass special options in the kernel command line (for Intel, they are: "intel_idle.max_cstate=0 processor.max_cstate=1"), else it's the CPU frequency (or power) governor which imposes the frequency, regardless of the BIOS settings... For some CPUs you may also use the /sys filesystem (e.g. for a Pentium Silver J5005, in my Linux firewall, I use "echo 1 >/sys/devices/system/cpu/cpuN/cpuidle/state2/disable" to disable all C-states but C0 and C1 and force it to run at its turbo-frequency, even though there are no OC settings available in the BIOS for this motherboard).

Quote:
Both viewers were running with Gamemode, which automatically adjusts the CPU to performance mode while running, and back to the default (balanced or on-demand in my case) after the program terminates.
Aha !... That might well be the problem... AGAIN: lock your CPU frequency yourself and do NOT use any special mode ("game mode" is not a Linux thing... Probably an Ubuntu idiosyncrasy): C-states and P-states switching can kill your frame rate (e.g., if some power throttling comes into scene). Also, the power settings in the BIOS might be relevant (since the Cool VL Viewer main loop is so much faster, it could well pump more current than when running a slower viewer, and cause throttling).

Quote:
Firestorm's "About" showed a lower clock rate than Cool VL Viewer's "About," despite showing higher framerates for me, which means that it's a [mostly] useless indicator of system performance.
This shows that there is a problem with your governor, since as soon as the viewer is running, the turbo frequency should be in force and kept as high as possible: obviously, it is not "stable" (and the fact it was higher in a viewer than in the other might just depend on when you opened the floater).

Quote:
I have KDE panel widgets that show me the current CPU clock, load, temperature, and system RAM usage. I know when the CPU is running in performance mode.
Use the Linux kernel "turbostat" command line tool instead: it will report the precise figures for each core: when running with all cores locked in turbo, it should report almost 100% in "Busy" for active cores and 0% in C2+ states for all cores.

Quote:
Aside from comparing hardware, kernels, drivers, desktop environments, window managers, etc., what about Kokua and Firestorm allow them to run faster than Cool VL Viewer?
Nothing... They are all slower (just made a test of all Linux viewers, and even Singularity is slower than the Cool VL Viewer).

Quote:
Kokua uses KDU v8.0.5, and my compiled Firestorm uses OpenJPEG 1.5.1. Cool VL Viewer uses OpenJPEG 1.4.0. Does that matter? Are there any other precompiled libraries that might have an effect on performance?
This is totally irrelevant. The JPEG2000 decoder is only used while rezzing textures, and the decoding is made in another thread (it won't affect the frame rate the least, unless you are running on a mono-core CPU). Plus, this is not v1.4.0 that I use, but 1.4.0.635f, which is a personal, patched (sixth release, thus the "f") and optimized version (with security and bug fixes, optimized integer encode/decode and backported optimized SSE encoding/decoding from OpenJPEG v2).


2020-08-24 00:19:37
Profile WWW

Joined: 2009-03-17 18:42:51
Posts: 5523
Oh... I also just noticed: you are using a custom viewer build, with AVX2 optimizations... If AMD's CPUs are as bad as Intel's, using AVX2 might decrease the turbo frequency; for the 9700K, I have to set a special option in the BIOS to avoid that, else I'd loose 500MHz or so, even with light AVX2 loads, meaning even the Linux kernel itself (which uses AVX2 for software RAID, for example) would cause the slow down !

Please, try with the official build of the Cool VL Viewer (it's built with SSE2 only)...


2020-08-24 00:46:40
Profile WWW
Display posts from previous:  Sort by  
This topic is locked, you cannot edit posts or make further replies.   [ 21 posts ]  Go to page Previous  1, 2, 3  Next

Who is online

Users browsing this forum: No registered users and 5 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group
Designed by ST Software.