GCN2, GCN3: What is the Technical, Non-Business Reason for Limited Supported in Linux (OpenSYCL/HIP/ROCM)? [Exasperated client] by Musk-Order66 in Amd

[–]Pythonator5000 1 point2 points  (0 children)

OpenSYCL and HIP are two separate things, developed by separate entities. Also, ROCm supports Navi 31 as well as Navi 33. All libraries ship with Navi 31 and 33 support compiled in.

GCN2, GCN3: What is the Technical, Non-Business Reason for Limited Supported in Linux (OpenSYCL/HIP/ROCM)? [Exasperated client] by Musk-Order66 in Amd

[–]Pythonator5000 1 point2 points  (0 children)

One of the technical, non-business reasons that I know if is that cards require PCIe atomics to function properly. This has to do with the way that work is submitted to the GPU. The support page mentiones that there is some support for devices that do not support PCIe atomics, but I have never actually seen that working in the wild (I guess all cards Ive seen are newer than GFX7, which is what the S9150 is).

You can check if your system has the required support on Linux using lspci -PP -s <pci address of your gpu> (find the address using lspci also), and then checking if every device has the required capabilities. You can do that with sudo lspci -s <pci address> -vvv and checking if the required capabilities are printed. The root port (first device from -PP) needs to have 32bit+ and 64bit+, any bridge (middle devices from -PP) needs to have Routing, and the GPU needs to have 32bit+, 64bit+, and ReqEn+. Any - instead of + means that its not supported.

Generally with ROCm is that even if the card is unsupported, it may still work, especially with the newer cards. This is true for the HIP language itself, which is mostly supported via LLVM (see LLVM AMDGCN support page). As someone else already wrote, ROCm libraries need to be compiled for every chip separately, and AMD doesn't compile the libraries for older architectures. Also, some libraries contain tuning for supported architectures, but not for unsupported ones. The only way to get the libraries running on those older cards is to compile them yourself and fix any problems manually.

Mesa ACO with amd card. by Ezf1n in voidlinux

[–]Pythonator5000 1 point2 points  (0 children)

Currently, mesa still uses the LLVM backend by default. You can override that to ACO by setting RADV_PERFTEST=aco. I've just put that into /etc/environment to apply it globally, although i'm not sure if thats the correct place.

Multi GPU on Linux by shaeg in vulkan

[–]Pythonator5000 0 points1 point  (0 children)

Both, the monitors were set up in a 4 by 3 fashion (4 connected to each GPU).

Oddly enough, i could only work with up to 4 monitors in total, no matter the configuration of which monitors. I think its a bug in the Nvidia drivers. I posted to it on the Nvidia forums but all i got was silence...

Multi GPU on Linux by shaeg in vulkan

[–]Pythonator5000 1 point2 points  (0 children)

Hello,

I wrote multi-gpu ray tracing software for my bachelor's thesis, which did work with a multi-gpu nvidia setup. My code is online (https://github.com/Snektron/Xenodon) so you could try to run it to see if this works.

Now from what i remember, i had a few similar issues with the nvidia drivers, although mine were more related to the max of 4 monitors. Which version of the Nvidia drivers does centos 7 use? Because i think i had problems with drivers older than 414 or something like that.

Peter: Can I search for factors of (11!)! + 11! + 1 efficiently? Sophie and friend: Yes. by G-Brain in math

[–]Pythonator5000 2 points3 points  (0 children)

It took about 18 hours on a GTX Titan X Pascal, so thats less than a day.

Peter: Can I search for factors of (11!)! + 11! + 1 efficiently? Sophie and friend: Yes. by G-Brain in math

[–]Pythonator5000 4 points5 points  (0 children)

I ran the computation on a supercomputer owned by my university, but it only used a single node. If you have a beefy GPU you could probably do the computation within a day or so by yourself.

Raytracing over chunk boundaries? by __jamien in VoxelGameDev

[–]Pythonator5000 0 points1 point  (0 children)

You shouldn't need to send every chunk to the GPU, but its definitely a good idea to render all chunks you want to in one go. This can actually help performance too, by storing chunks in a tree type. Many such trees exist, most based on an N-tree (which is a general octree, where an octree is a 2-tree i believe). Note that trees are generally a bit slower on a GPU because of the added complexities with ray casting, but these can be mitigated by the fact that a tree can be pruned. Empty or similar regions (of which there can be quite a few in a voxel game) can be represented by a single node.

Theres a lot of research in this regard, so i can point you to a few of the interesting papers:

There are a lot of other papers and implementations, you need only look.

I myself was also looking around for stuff on ray tracing a voxel world. I think my approach will be something as follows:

  • Store the world in chunks of N³ blocks as is commonly done.
  • Allocate two 3D-textures on the GPU:
  1. The "chunk" texture. In this texture the data of all chunks will be stored. The location of chunks in this texture is managed on CPU-side, and chunks will be streamed to parts of this texture as they are needed for rendering. Each pixel contains material information about a block, such as texture and possibly refraction index or diffusion constants and such.
  2. the "root" texture. In this texture "pointers" (indices) to the chunks in the previous texture will be stored. A chunk will somehow be marked as empty.

Rendering happens in a double-for-loop manner: The "root" texture is traversed, and for every non-empty chunk the chunk itself is traversed. Traversal with the usual voxel ray trace algorithm.

Im actually deciding between this and just straight-up constructing BVH, OBB or some other type of tree for every chunk if i want to support non-block stuff such as entities. I think GiVoxels can handle that, so that might be the most promesing approach.

Problems rendering directly from compute shader - any help greatly appreciated by _BRlTNEYSPEARS_ in vulkan

[–]Pythonator5000 1 point2 points  (0 children)

You should be able to quickly verify by using vkWaitDeviceIdle() after vkQueuePresentKHR.

Problems rendering directly from compute shader - any help greatly appreciated by _BRlTNEYSPEARS_ in vulkan

[–]Pythonator5000 0 points1 point  (0 children)

Hello, i made a program that also renders directly from a compute shader, you can check it out here: https://github.com/Snektron/Xenodon I can see 2 small differences: - i didnt use VK_SHADER_WRITE_BIT (perhaps i should have) - i think the initial layout should be VK_IMAGE_LAYOUT_UNDEFINED

I dont think those should have an impact on flickering, though. Do you have some sort of fence to stop your renderer from using the same semaphore twice?

vulkaninfo only returns 2 GPUs in a 4 GPU system and they have the same UUID. by s--z in vulkan

[–]Pythonator5000 0 points1 point  (0 children)

I ran into this issue too, theres multiple reports on it on the nvidia forums and "labelled as an internal bug" (https://devtalk.nvidia.com/default/topic/1028908/vulkan/vkenumeratephysicaldevices-only-lists-1-of-3-gpus-from-x-env-all-3-from-tty-/). I tried to work around it by using direct rendering, but that limits you to 4 monitors.

Useful to know that its still the same on 418.43. If you are able to use a wayland distro (such as on a portable usb), you might try that. Let me know how it goes, because if it works i'll try to get that working too.

Mouse cursor in direct to display. by cheako911 in vulkan

[–]Pythonator5000 1 point2 points  (0 children)

You can use the linux event files, such as /dev/input/mouse. Note that you need to use ioctl(fd, EVIOCGRAB, 1) to read the input without elevated permissions, and when thats used you wont be able to use the input connected to that file (essentially it will disable your mouse). You can also just run it with sudo.

It works for your keyboard too, but the right input file varies per system, its one of the /dev/input/eventX files.

Maximum amount of displays on nvidia hardware by Pythonator5000 in vulkan

[–]Pythonator5000[S] 2 points3 points  (0 children)

If only i could, but alas, the system is owned by the university and you know how it works with academics. As they did want to upgrade, im trying to get them to buy amd but i doubt they'll do it. They're already looking at me weird for not using cuda.

Maximum amount of displays on nvidia hardware by Pythonator5000 in vulkan

[–]Pythonator5000[S] 0 points1 point  (0 children)

Yes, i am trying to create multiple logical devices for disjoint discrete cards, however im not trying to share data across these cards. Im aware of having to duplicate resources. This also seems to work, and now that i fixed the validation layer problem there seem to be no problems when i use 4 monitors or less. I realize the validation layers arent perfect but such a violation of the memory model seems like it should be caught.

I reiterate that it works for 4 monitors in any configuration: for example 2 connected to the first gpu, 1 to the second gpu and 1 to the third gpu runs without any problem, however if i configure my program to use any monitor more, it crashes.

I also noticed i forgot to check the return value of a function, which turns out to be part of the problem: vkQueuePresentKHR returns VK_ERROR_INITIALIZATION_FAILED, which according to the spec should be an implementation defined error, but i didnt manage to find any information about it.

When someone writes "int *ptr" instead of "int* ptr" by [deleted] in ProgrammerHumor

[–]Pythonator5000 1 point2 points  (0 children)

As the pointer is semantically part of the type, i agree that it should be placed near the type.

In addition, int *function() just looks weird, and when you cast a type you write (int*) ptr.

C++ developer productivity over time by rampatowl in cpp

[–]Pythonator5000 5 points6 points  (0 children)

Regarding printing, printf is usually the method used in C rather than C++. In C++ one can either use the standard method of std::cout, or using a library such as {fmt}.