News for hackers. Stuff that matters.
Re:Cybercriminals who breached Nvidia issue one of the most ... by modeless on Friday March 04, 2022 @02:51AM (#30551869)
Despite my complaints, for casual gaming on a desktop you shouldn't have too many issues with Nvidia's drivers these days as long as you can use the ones packaged by your distro instead of Nvidia's installer. My troubles have mostly been associated with laptops that have both Intel and Nvidia graphics, or desktops used for ML training where the distro-packaged drivers wouldn't work for one reason or another.

I've heard AMD's drivers are OK these days but haven't tried them myself because I care about ML.

Re:Cybercriminals who breached Nvidia issue one of the most ... by ChuckNorris89 on Friday March 04, 2022 @04:27AM (#30552469)
>I've heard AMD's drivers are OK these days but haven't tried them myself because I care about ML.

They are OK but with some caveats like VP9 HW decode not being available in Linux AMD iGPU drivers for reasons, which won't be a problem if you're running an AMD desktop tower PC, but if you're gonna watch Youtube on your AMD laptop, your battery will take a hit along with possible extra fan noise, which is unacceptable for a great media content consumption experience in Linux when even no-name Android phones and tablets have VP9 HW decode in Youtube out of the box. No bueno.

This is such a mess, as VP9 & AV1 HW video decode is not an issue under linux for Intel iGPUs, but AMD seems to not give a shit to expose VP9 decode on linux for their iGPUs. Also, unlike with Intel iGPUs, under linux, radeon-top does not show GPU decode usage for easy diagnostic purposes. I assume it's because AMD bought the video codec engine IP from some third party fabless IP vendor and they don't have the permission to open source the drivers for the video engine block as part of the licensing agreement, like they do for their in house developed GPU block. But still, regardless of the reason, it sucks for the linux end-users.

And another important issue nobody seems to talk about but one should be aware of, AMD APUs (at least to 5000 series) don't have unified memory between CPU and iGPU like Intel and Apple do, so you have to configure in your laptop BIOS how much of your system RAM you want allocated to your iGPU (512MB/1GB/2GB/4GB), with the rest remaining for the CPU. This sucks big time if you're switching between productivity where you need more memory for applications, and playing video games where you need as much memory as possible for the GPU, so you need to keep rebooting and changing in the BIOS the amount of memory you allocate to your iGPU, vs on Intel chips where the whole system memory is unified and shared dynamically between the CPU and iGPU, and it boils my blood as the whole marketing gimmick of AMD's APUs was the seamless merger between CPU and GPU resources together, while in practice their (5000 series) APUs are just a Ryzen CPU with a Vega GPU glued on the same die without them actually sharing any of the resources properly. Maybe the new 6000 series with RDNA2 changed that but I couldn't find any detailed info.

Honestly, as a laptop owner with AMD APU, if you're planning to go Linux, just get one with an Intel chip instead. Much less head aches as Intel Linux drivers and apps are second to none and have a unified memory model.

The performance and efficiency of AMD APUs is still great though, especially under Windows, but the overall implementation as a whole package seems poorly thought out and rushed out the door, especially under Linux compared to Intel.

Re:Cybercriminals who breached Nvidia issue one of the most ... by vetinari on Friday March 04, 2022 @09:06AM (#30554871)
Isn't this some distro-specific problem?

VP9 should be available since Mesa 18.1 (or so) for VCN-based GPUs (i.e. Raven Ridge and newer). VP9 is not supported in hardware on UVD-based GPUs (i.e. discrete Vega).

VCN 3.0-based GPUs (i.e. RDNA2, the 6000-series APUs) also support AV1 decoding.

Re:Cybercriminals who breached Nvidia issue one of the most ... by ChuckNorris89 on Friday March 04, 2022 @09:56AM (#30555685)
>VP9 should be available since Mesa 18.1 (or so) for VCN-based GPUs (i.e. Raven Ridge and newer).

Yeah, in theory it's available, but good luck actually getting your browser to use it to HW decode YouTube videos under linux out of the box.

It usually works fine with video players like mplayer but not in browsers.

There are endless threads online about this not working. I for one, never managed to get it to work in any browser. What a mess.

Re:Cybercriminals who breached Nvidia issue one of the most ... by vetinari on Friday March 04, 2022 @10:28AM (#30556095)
> It usually works fine with video players like mplayer but not in browsers.

Chrome doesn't support VA-API, so do not bother trying.

Some distributions do have Chromium builds with VA-API support enabled, but YMMV. Chromium uses X11 only and libva requires dri2, so it doesn't work under XWayland, which supports only dri3. (=> Chromium with VA-API works only in native X11 session)

Firefox does support VA-API. There was a period of time, when it did only under Wayland, but nowadays both X11 and Wayland should work. When running under Wayland, use the native version and /not/ via XWayland, because the same thing as with Chromium applies.

Re:Cybercriminals who breached Nvidia issue one of the most ... by mrkstu on Saturday March 05, 2022 @11:03AM (#30568600)
The above is a fair summation of Linux's failure as a desktop in a single post.
Re:Cybercriminals who breached Nvidia issue one of the most ... by vetinari on Saturday March 05, 2022 @11:16AM (#30568731)
Maybe it is, but keep in mind, that Chrome is a proprietary application - the Linux community and the desktop communities have exactly zero input, what will and what will be not supported.

On the Firefox side, Redhat and Suse people did the work to support video acceleration.

Re:Cybercriminals who breached Nvidia issue one of the most ... by JonChesterfield on Friday March 04, 2022 @06:10AM (#30553167)
Minor point. That bios setting does dedicate some amount of ram to the GPU, so the rest of the system can't use it. The GPU can allocate more than that though if the program makes a slightly different allocate call to request it.

Seamlessly sharing memory between the two chips works fine with the compute toolchain (rocm), I don't know how transparent it is for games.

Re:Cybercriminals who breached Nvidia issue one of the most ... by ChuckNorris89 on Friday March 04, 2022 @06:27AM (#30553289)
>The GPU can allocate more than that though if the program makes a slightly different allocate call to request it.

Maybe in ROCM, but not in generic Windows and Linux apps and video games that I've tried. They all cap out at whatever you set in BIOS for the iGPU VRAM reservation and don't go beyond that into system RAM. If ROCM has this ability how come AMD's driver, at least in Windows, doesn't do this memory overflow thing for VRAM hungry apps like video games, as that would certainly alleviate this issue.

IMHO, still a worse implementation than the unified model of Intel. Having a large chunk of memory constantly blocked for a HW component, regardless if it's currently needed or not is just horribly inefficient, especially when you're on a mobile device and have 16GB of RAM or less to play with.

Disappointing.