Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
installing amdgpu-pro and getting vulkan
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
newin
n00b
n00b


Joined: 27 Oct 2012
Posts: 27

PostPosted: Mon Sep 12, 2016 8:27 pm    Post subject: installing amdgpu-pro and getting vulkan Reply with quote

Hi all !
Well I'm opening this thread because it seems that almost no-one talk about that on the forum and I had a "pretty bad" experience with those drivers to say the least.
First it seems that there is no support from AMD to get other distros than ubuntu/steamOS. As fas as I know they will not try to make any portability effort as long as the driver isn't "good enough". I learned at my last GDC europe that the support of Vulkan in Redhat OSes are done by the redhat guy, not AMD.

On the gentoo side it seems that some wizard tried to make it possible: https://github.com/Lucretia/vulkan-overlay
But it didn't really worked for me. The overlay doesn't work (it is so broken that I used the ebuild as a "tutorial"...). After applying every patch by hand and fixing problem after problem I finally made the dkms part "work".
When I startX I get this: https://github.com/farmboy0/portage-overlay/issues/4
It seems that "AMDGPUPTR" could not get the pointer it wanted in this code: https://github.com/freedesktop-unofficial-mirror/xorg__driver__xf86-video-amdgpu/blob/master/src/amdgpu_kms.c

So I'm here to ask if someone achieved (or tried?) to make amdgpu-pro work on a gentoo 4.7 with a carrizo card.
If the driver is just "no yet ready" then I could help, if it works and I'm dumb then it will produce a basic knowledge for guys like me, if the overlay just needs a little patch then we can fix it and produce a tutorial here.
_________________
uname -a: Linux legion 4.12.0-rc7 #2 SMP Sun Jul 2 22:07:50 CEST 2017 x86_64 Intel(R) Core(TM) i7-4870HQ CPU @ 2.50GHz GenuineIntel GNU/Linux
gcc : gcc (Gentoo 5.4.0-r3 p1.3, pie-0.6.5) 5.4.0
window manager : dwm 6.1
web browser : Vivaldi 1.10.867.42
Back to top
View user's profile Send private message
newin
n00b
n00b


Joined: 27 Oct 2012
Posts: 27

PostPosted: Fri Sep 30, 2016 9:15 am    Post subject: Reply with quote

I'm replying to myself to update the status of vulkan on AMD systems but this time it is not related to amdgpu-pro.

I just learned that there is a openSource initiative to get vulkan on AMD system called "RADV":
it seems to work pretty well:
http://www.phoronix.com/scan.php?page=news_item&px=RADV-Renders-Talos-Principle
and have good overall performance:
https://www.phoronix.com/scan.php?page=article&item=radeon-vulkan-radv&num=1

but I cannot find anything about it on gentoo's documentation or any documentation. I have no more information than "hey it works :D " which is good but now I want to install it :cry: .
I would like to get Vulkan, I don't mind if it's from amdgpu-pro or RADV but both seems really hard to get.
If anyone can give me a hint or help...

If I achieve to get Vulkan using amdgpu-pro or RADV (or any other way) I will write a full tutorial here.
_________________
uname -a: Linux legion 4.12.0-rc7 #2 SMP Sun Jul 2 22:07:50 CEST 2017 x86_64 Intel(R) Core(TM) i7-4870HQ CPU @ 2.50GHz GenuineIntel GNU/Linux
gcc : gcc (Gentoo 5.4.0-r3 p1.3, pie-0.6.5) 5.4.0
window manager : dwm 6.1
web browser : Vivaldi 1.10.867.42
Back to top
View user's profile Send private message
paraw
Tux's lil' helper
Tux's lil' helper


Joined: 07 Jan 2005
Posts: 138
Location: Coventry (UK)

PostPosted: Sat Oct 01, 2016 1:37 pm    Post subject: Reply with quote

I did something similar, but it works for me, on an overclocked Sapphire Nitro+ RX480 8GB. I'm using kernel 4.4.21.
I first installed vulkan, modifying Luke's ebuild. The modification I did is pretty much the same he also introduced about a week ago, i.e., installing also the header files.
Then I adapted his ebuild to install the latest version of the proprietary driver files (except the module).
Then I installed dkms from farmboy0's overlay, unpacked the dkms source by hand, and fixed that code in a certain number of points. Some of these patches, but not all of them, are the same as Luke's. Some of his I found were actually not needed, while I had to fix other things as well.
Then I built and installed the module, rebooted and all is fine.
Vulkan works, direct rendering works, no crashes, all is fine. I figured I didn't need a kernel > 4.4, since the module is written for Winbuntu 16.04, that uses a 4.4 kernel.
As for kernel options, I found you need CONFIG_VGA_SWITCHEROO, CONFIG_DRM, CONFIG_DRM_FBDEV_EMULATION, CONFIG_FB, CONFIG_FB_MODE_HELPERS, CONFIG_FB_VESA, CONFIG_FRAMEBUFFER_CONSOLE and CONFIG_FRAMEBUFFER_CONSOLE_DETECT_PRIMARY, some of which may be automatically selected. Also, you need CONFIG_DRM_AMDGPU built as a module with CONFIG_DRM_AMDGPU_USERPTR, and CONFIG_FB_RADEON, also built as a module, with CONFIG_FB_RADEON_I2C and CONFIG_FB_RADEON_BACKLIGHT. Note that you need these options even if you are not building for a laptop because the pro module needs them anyway.
As I wrote, all works fine for me.
Back to top
View user's profile Send private message
newin
n00b
n00b


Joined: 27 Oct 2012
Posts: 27

PostPosted: Tue Oct 04, 2016 5:38 pm    Post subject: Reply with quote

I'm curious to know which version of Xorg you have. After installing it X is complaining :
Code:
(EE) ABI major version (8) doesn't match the server's version (9)
(EE) ABI major version (15) doesn't match the server's version (20)

and I have no idea that version is he talking about.

Did I miss something or I should downgrade X ?

[edit] the "version 8.0" is the the "ABI class : X.Org Server Extension version 8.0" of the module and Xorg seems to ask for 9.0. And this is the exact same problem for amdgpu which is "X.Org Video Driver, version 15" and Xorg ask for "20"...

[edit 2] I also would like to see your xorg.conf to know how you enable amdgpu-pro
_________________
uname -a: Linux legion 4.12.0-rc7 #2 SMP Sun Jul 2 22:07:50 CEST 2017 x86_64 Intel(R) Core(TM) i7-4870HQ CPU @ 2.50GHz GenuineIntel GNU/Linux
gcc : gcc (Gentoo 5.4.0-r3 p1.3, pie-0.6.5) 5.4.0
window manager : dwm 6.1
web browser : Vivaldi 1.10.867.42


Last edited by newin on Tue Oct 04, 2016 7:13 pm; edited 1 time in total
Back to top
View user's profile Send private message
Roman_Gruber
Advocate
Advocate


Joined: 03 Oct 2006
Posts: 3806
Location: Austro Bavaria

PostPosted: Tue Oct 04, 2016 6:41 pm    Post subject: Reply with quote

your kernel looks very old
Back to top
View user's profile Send private message
asturm
Developer
Developer


Joined: 05 Apr 2007
Posts: 7206
Location: Austria

PostPosted: Tue Oct 04, 2016 7:19 pm    Post subject: Reply with quote

Roman_Gruber wrote:
your kernel looks very old

Roughly four weeks.
_________________
backend.cpp:92:2: warning: #warning TODO - this error message is about as useful as a cooling unit in the arctic


Last edited by asturm on Tue Oct 04, 2016 8:18 pm; edited 1 time in total
Back to top
View user's profile Send private message
newin
n00b
n00b


Joined: 27 Oct 2012
Posts: 27

PostPosted: Tue Oct 04, 2016 7:26 pm    Post subject: Reply with quote

Roman_Gruber wrote:
your kernel looks very old


My kernel is a 4.7.2 which is fairly recent, it's not even flagged as "stable" by gentoo... I'm updating to 4.8 as I'm writing because it seems that amdgpu was updated pretty heavily those 3 last version ( 4.6 4.7 and 4.8 ).

PS: the "3.18" you are seeing in my signature is on my desktop and I'm trying to install amdgpu-pro on one of my 2 laptop.




[update] I am trying using the patches of "Lucretia": https://github.com/Lucretia/vulkan-overlay/tree/master/sys-kernel/amdgpu-pro-dkms it seems to be more up-to date but I ran into some problems and I had to make some "I-don't-know-what-I'm-doing" patches like deleting a "if" statement and things like that... I explained everything here if you want more details: https://github.com/Lucretia/vulkan-overlay/issues/18
At the end my kernel module crash when I startx with this dmesg: http://pastebin.com/raw/50r5HvgS
And optionally when I try to switch between TTY (CTRL+ALT+F2) my screen is freezing (I don't know if it's a full kernel panic or if the driver don't want to refresh my screen but I have to hard-reset my PC after doing this)
_________________
uname -a: Linux legion 4.12.0-rc7 #2 SMP Sun Jul 2 22:07:50 CEST 2017 x86_64 Intel(R) Core(TM) i7-4870HQ CPU @ 2.50GHz GenuineIntel GNU/Linux
gcc : gcc (Gentoo 5.4.0-r3 p1.3, pie-0.6.5) 5.4.0
window manager : dwm 6.1
web browser : Vivaldi 1.10.867.42
Back to top
View user's profile Send private message
paraw
Tux's lil' helper
Tux's lil' helper


Joined: 07 Jan 2005
Posts: 138
Location: Coventry (UK)

PostPosted: Sat Oct 29, 2016 8:19 pm    Post subject: Reply with quote

Sorry for the long absence. I just got the latest driver to work. Had to change the dkms source code, and made an ebuild for the rest of the driver. Works fine for me, including Vulkan. Screenshot of the Vulkan smoketest at http://www2.warwick.ac.uk/fac/cross_fac/complexity/people/staff/delgenio/Screenshot_20161029_210132.png. I'm a bit tired now, but at this point I'm thinking I should write a quick guide or something.
Back to top
View user's profile Send private message
newin
n00b
n00b


Joined: 27 Oct 2012
Posts: 27

PostPosted: Fri Nov 04, 2016 8:47 pm    Post subject: Reply with quote

I am finally getting something like look close to work !
I forgot the Idea of using amdgpu-pro it create too much problems so I'm trying to get RADV:
I updated my kernel to 4.9 (with sys-kernel/git-sources) and I switched to mesa 13 with media-libs/mesa-9999
for some weird reason I'm stuck to opengl 3.0 but I have shading language 4.30 which does not make any sense (mainly because glsl 430 is linked to opengl 4.3: https://en.wikipedia.org/wiki/OpenGL_Shading_Language )

Code:
glxinfo | grep opengl -i
OpenGL vendor string: X.Org
OpenGL renderer string: Gallium 0.4 on AMD CARRIZO (DRM 3.8.0 / 4.9.0-rc3, LLVM 3.9.0)
OpenGL core profile version string: 4.3 (Core Profile) Mesa 13.1.0-devel (git-bc4c09d)
OpenGL core profile shading language version string: 4.30
OpenGL core profile context flags: (none)
OpenGL core profile profile mask: core profile
OpenGL core profile extensions:
OpenGL version string: 3.0 Mesa 13.1.0-devel (git-bc4c09d)
OpenGL shading language version string: 1.30
OpenGL context flags: (none)
OpenGL extensions:
OpenGL ES profile version string: OpenGL ES 3.1 Mesa 13.1.0-devel (git-bc4c09d)
OpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.10
OpenGL ES profile extensions:


but anyway that is not the question here
but good news I can compile against Vulkan it find a driver without any problem except that the driver does not work:

Code:
vulkaninfo
===========
VULKAN INFO
===========

Vulkan API Version: 1.0.29

INFO: [loader] Code 0 : Found manifest file /usr/share/vulkan/explicit_layer.d/VkLayer_unique_objects.json, version "1.0.0"
INFO: [loader] Code 0 : Found manifest file /usr/share/vulkan/explicit_layer.d/VkLayer_threading.json, version "1.0.0"
INFO: [loader] Code 0 : Found manifest file /usr/share/vulkan/explicit_layer.d/VkLayer_swapchain.json, version "1.0.0"
INFO: [loader] Code 0 : Found manifest file /usr/share/vulkan/explicit_layer.d/VkLayer_parameter_validation.json, version "1.0.0"
INFO: [loader] Code 0 : Found manifest file /usr/share/vulkan/explicit_layer.d/VkLayer_object_tracker.json, version "1.0.0"
INFO: [loader] Code 0 : Found manifest file /usr/share/vulkan/explicit_layer.d/VkLayer_image.json, version "1.0.0"
INFO: [loader] Code 0 : Found manifest file /usr/share/vulkan/explicit_layer.d/VkLayer_core_validation.json, version "1.0.0"
INFO: [loader] Code 0 : Found manifest file /etc/vulkan/icd.d/amd_icd64.json, version "1.0.0"
vulkaninfo: symbol lookup error: /usr/lib/x86_64-linux-gnu/amdvlk64.so: undefined symbol: amdgpu_get_marketing_name


I get the error about "amdgpu_get_marketing_name" for every binary that use vulkan (obviously)
duckduckgo google (like 3 result and not about radv) aren't really helpful I have no idea where is should come from :(
any guess here ?
_________________
uname -a: Linux legion 4.12.0-rc7 #2 SMP Sun Jul 2 22:07:50 CEST 2017 x86_64 Intel(R) Core(TM) i7-4870HQ CPU @ 2.50GHz GenuineIntel GNU/Linux
gcc : gcc (Gentoo 5.4.0-r3 p1.3, pie-0.6.5) 5.4.0
window manager : dwm 6.1
web browser : Vivaldi 1.10.867.42
Back to top
View user's profile Send private message
newfuntek
n00b
n00b


Joined: 28 Jun 2006
Posts: 30
Location: Poland

PostPosted: Wed Nov 23, 2016 7:09 pm    Post subject: Reply with quote

The libdrm and xf86-amdgpu from AMD is missing, I think. :?:
_________________
gcc 8.1.0 lto graphite, rpi3 gcc 7.3.0
Tools for easy installation of Gentoo Linux (comments in Polish)
https://github.com/pwasiewi/gentools
Back to top
View user's profile Send private message
DHermit
n00b
n00b


Joined: 12 Dec 2016
Posts: 1

PostPosted: Mon Dec 12, 2016 7:55 pm    Post subject: Reply with quote

Any news as the driver now left the beta state and reached version 16.50?
Back to top
View user's profile Send private message
newin
n00b
n00b


Joined: 27 Oct 2012
Posts: 27

PostPosted: Wed Dec 21, 2016 2:51 pm    Post subject: Reply with quote

Hey guys I'm coming back with a lot of test and news,
After everything I tried amdgpu-pro is by far the most complex to get vulkan. The easiest is by using Radv.

I did update to the kernel 4.9 and mesa 13.0.2 which leaded to a problem due to how portage is building llvm ( https://bugs.gentoo.org/show_bug.cgi?id=602850 )

Quote:
CommandLine Error: Option 'asan-instrument-assembly' registered more
than once!
LLVM ERROR: inconsistency in registered CommandLine options


According to a mesa developper there is 2 ways to fix this problem:
1) using this patch: https://lists.freedesktop.org/archives/mesa-dev/2016-December/137277.html
2) "Compile LLVM using LLVM_BUILD_LLVM_DYLIB=ON mode instead of
BUILD_SHARED_LIBS=ON (requires a change in llvm ebuild or building
your own LLVM). If you go with the ebuild change, you will probably
have to rebuild everything that uses LLVM (I have not tried this;
there might be some problems in other packages due to this option,
though most other distributions apart from gentoo build LLVM in this
mode)." to quote the mail he sent to me.

(I choose to apply his patch to not broke the rest of my gentoo)
And that's it !
my vulkaninfo: http://pastebin.com/raw/jHrrcXcW
Now I'm having trouble running some vulkan example code because of an ERROR_EXTENSION_NOT_PRESENT error on VK_KHR_XCB_SURFACE_EXTENSION_NAME.

I also have a mid-2015 macbook-pro (which have a cape verde GCN 1.0 card) and the amdgpu driver black screen on my TTY (before startx) with 4.9 kernel without any error or warning in my dmesg. I will inform you if it works better in 4.10...
_________________
uname -a: Linux legion 4.12.0-rc7 #2 SMP Sun Jul 2 22:07:50 CEST 2017 x86_64 Intel(R) Core(TM) i7-4870HQ CPU @ 2.50GHz GenuineIntel GNU/Linux
gcc : gcc (Gentoo 5.4.0-r3 p1.3, pie-0.6.5) 5.4.0
window manager : dwm 6.1
web browser : Vivaldi 1.10.867.42
Back to top
View user's profile Send private message
lost-distance
n00b
n00b


Joined: 10 Apr 2003
Posts: 73

PostPosted: Wed Dec 21, 2016 11:25 pm    Post subject: Reply with quote

Hi all,

I just got the amdgpu-pro-16.50 driver to successfully run the Vulkan cube demo program on my AMD A10-7800 (Kaveri) desktop PC.

My kernel version is linux-4.9, built with the AMDGPU (CONFIG_DRM_AMDGPU) driver.
My LLVM package is sys-devel/llvm-3.9.0-r1
My X11 server package is x11-base/xorg-server-1.18.4
My Mesa package is media-libs/mesa-13.0.2 (built with -vulkan USE flag)

The steps to install the amdgpu-pro-16.50 driver are these:

1. emerge media-libs/vulkan-loader-1.0.30.0
2. Download amdgpu-pro-16.50-362463.tar.xz from AMD.
3. Extract vulkan-amdgpu-pro_16.50-362463_amd64.deb from the download.
4. Extract the contents of vulkan-amdgpu-pro_16.50-362463_amd64.deb into a local directory.
5. Extract libdrm-amdgpu-pro-amdgpu1_2.4.70-362463_amd64.deb from the download.
6. Extract the contents of libdrm-amdgpu-pro-amdgpu1_2.4.70-362463_amd64.deb into the same local directory
7. Copy the following from the local directory to the root directory (/):

Code:
/etc
/etc/vulkan
/etc/vulkan/icd.d
/etc/vulkan/icd.d/amd_icd64.json
/opt
/opt/amdgpu-pro
/opt/amdgpu-pro/lib
/opt/amdgpu-pro/lib/x86_64-linux-gnu
/opt/amdgpu-pro/lib/x86_64-linux-gnu/amdvlk64.so
/opt/amdgpu-pro/lib/x86_64-linux-gnu/libdrm_amdgpu.so.1
/opt/amdgpu-pro/lib/x86_64-linux-gnu/libdrm_amdgpu.so.1.0.0

I built the cube demo program by hand from the latest Khronos Vulkan-LoaderAndValidationLayers software. I had to hack cube.c to ignore the return value of vkWaitForFences(), which was failing with VK_ERROR_INITIALIZATION_FAILED. After that it ran flawlessly.
Back to top
View user's profile Send private message
newin
n00b
n00b


Joined: 27 Oct 2012
Posts: 27

PostPosted: Wed Feb 08, 2017 4:48 pm    Post subject: Reply with quote

Hi all.
Like I said in my last post I cannot get any surface extension, which is a bit inconvenient for a API that aim to display things... I first thought I forgot to install something but trying to compile and install "Vulkan-LoaderAndValidationLayers" did not fix my problem...
when using RADV I get:

Code:
Presentable Surfaces:
=====================
None found

-> I must say that I coudn't use the ebuild "media-libs/vulkan-loader". It was trying to compile it with the wayland and mir support...

So I decided to return to amdgpu-pro. After installing amdgpu-pro following the steps given by lost-distance I get a SEGV:

Code:
Presentable Surfaces:
=====================
GPU id       : 0 (AMD RADV CARRIZO)
Surface type : VK_KHR_xcb_surface
Segmentation fault


Strangely when I use gdb to find where it come from, I get this

Code:
Presentable Surfaces:
=====================
GPU id       : 0 (AMD RADV CARRIZO)
Surface type : VK_KHR_xcb_surface

Program received signal SIGSEGV, Segmentation fault.
0x00007fffebd09c75 in radv_GetPhysicalDeviceSurfaceFormatsKHR (physicalDevice=0xdd2380, _surface=0xfa79b0, pSurfaceFormatCount=0x7fffffffe014, pSurfaceFormats=0x0)
    at radv_wsi.c:120
120      return iface->get_formats(surface, &device->wsi_device, pSurfaceFormatCount,


The name of the function show that it come from radv which does not make any sense after installing amdgpu-pro.

There is some clue in vulkaninfo that show both driver work at same time (I guess). There is new layers/extensions (that disappear when I "mv /opt/amdgpu-pro /root")

Code:

Layers: count = 8
=======
VK_LAYER_GOOGLE_unique_objects (Google Validation Layer) Vulkan version 1.0.29, layer version 1
        Layer Extensions        count = 0
        Devices         count = 3
                GPU id       : 0 (AMD RADV CARRIZO)
                Layer-Device Extensions count = 0
                GPU id       : 1 (AMD RADV CARRIZO)
                Layer-Device Extensions count = 0
                GPU id       : 2 (Unknown AMD GPU)
                Layer-Device Extensions count = 0


I've installed it like this:

cat /etc/X11/xorg.conf | tail -n 10
Code:
Section "OutputClass"
   Identifier "amdgpu-pro"
   MatchDriver "amdgpu"
   Driver "amdgpu"
EndSection

Section "Files"
   ModulePath "/opt/amdgpu-pro/lib/xorg/modules"
   ModulePath "/usr/lib/xorg/modules"
EndSection


And I also have mesa installed with radv because it seems mandatory for it to have vulkan support.

find /opt/amdgpu-pro/
Code:
/opt/amdgpu-pro/
/opt/amdgpu-pro/lib
/opt/amdgpu-pro/lib/x86_64-linux-gnu
/opt/amdgpu-pro/lib/x86_64-linux-gnu/amdvlk64.so
/opt/amdgpu-pro/lib/x86_64-linux-gnu/libdrm_amdgpu.so.1.0.0
/opt/amdgpu-pro/lib/x86_64-linux-gnu/libdrm_amdgpu.so.1
/opt/amdgpu-pro/lib/x86_64-linux-gnu/libkms.so.1
/opt/amdgpu-pro/lib/x86_64-linux-gnu/libkms.so.1.0.0
/opt/amdgpu-pro/lib/x86_64-linux-gnu/libdrm.so.2
/opt/amdgpu-pro/lib/x86_64-linux-gnu/libdrm.so.2.4.0
/opt/amdgpu-pro/lib/x86_64-linux-gnu/libomxil-bellagio0
/opt/amdgpu-pro/lib/x86_64-linux-gnu/libomxil-bellagio0/libomx_mesa.so
/opt/amdgpu-pro/lib/x86_64-linux-gnu/libdrm_radeon.so.1
/opt/amdgpu-pro/lib/x86_64-linux-gnu/libdrm_radeon.so.1.0.1
/opt/amdgpu-pro/lib/x86_64-linux-gnu/libdrm.a
/opt/amdgpu-pro/lib/x86_64-linux-gnu/libdrm_amdgpu.a
/opt/amdgpu-pro/lib/x86_64-linux-gnu/libdrm_amdgpu.so
/opt/amdgpu-pro/lib/x86_64-linux-gnu/libdrm_radeon.a
/opt/amdgpu-pro/lib/x86_64-linux-gnu/libdrm_radeon.so
/opt/amdgpu-pro/lib/x86_64-linux-gnu/libdrm.so
/opt/amdgpu-pro/lib/x86_64-linux-gnu/libkms.so
/opt/amdgpu-pro/lib/xorg
/opt/amdgpu-pro/lib/xorg/modules
/opt/amdgpu-pro/lib/xorg/modules/drivers
/opt/amdgpu-pro/lib/xorg/modules/drivers/amdgpu_drv.so
/opt/amdgpu-pro/bin
/opt/amdgpu-pro/bin/kms-universal-planes
/opt/amdgpu-pro/bin/vbltest
/opt/amdgpu-pro/bin/proptest
/opt/amdgpu-pro/bin/modetest
/opt/amdgpu-pro/bin/kms-steal-crtc
/opt/amdgpu-pro/bin/modeprint
/opt/amdgpu-pro/bin/kmstest
/opt/amdgpu-pro/bin/amdgpu_test

_________________
uname -a: Linux legion 4.12.0-rc7 #2 SMP Sun Jul 2 22:07:50 CEST 2017 x86_64 Intel(R) Core(TM) i7-4870HQ CPU @ 2.50GHz GenuineIntel GNU/Linux
gcc : gcc (Gentoo 5.4.0-r3 p1.3, pie-0.6.5) 5.4.0
window manager : dwm 6.1
web browser : Vivaldi 1.10.867.42
Back to top
View user's profile Send private message
EoD
n00b
n00b


Joined: 30 May 2008
Posts: 35

PostPosted: Mon May 01, 2017 12:50 am    Post subject: Reply with quote

newin wrote:
I did update to the kernel 4.9 and mesa 13.0.2 which leaded to a problem due to how portage is building llvm ( https://bugs.gentoo.org/show_bug.cgi?id=602850 )

Quote:
CommandLine Error: Option 'asan-instrument-assembly' registered more
than once!
LLVM ERROR: inconsistency in registered CommandLine options


According to a mesa developper there is 2 ways to fix this problem:
1) using this patch: https://lists.freedesktop.org/archives/mesa-dev/2016-December/137277.html
2) "Compile LLVM using LLVM_BUILD_LLVM_DYLIB=ON mode instead of
BUILD_SHARED_LIBS=ON (requires a change in llvm ebuild or building
your own LLVM)...

FYI I created a bug report for this issue: https://bugs.gentoo.org/show_bug.cgi?id=617154
_________________
Sun Blade 100 (UltraSPARC IIe) server with multilib and Java
----
Gentoo/SPARC, Gentoo/AMD64, Gentoo/x86
Back to top
View user's profile Send private message
newin
n00b
n00b


Joined: 27 Oct 2012
Posts: 27

PostPosted: Tue Jul 04, 2017 1:01 am    Post subject: Reply with quote

Hi ! that's me again !

I'm back on this thread because I tried to install vulkan on my CapeVerde card (R9 M370X, the MacBook pro 2015's GPU)
And everything that could go wrong with it did wrong with install. I even mistakenly deleted /etc in the process because of a typo but that's another story...

I'm posting here to say that:
Code:

the "CommandLine Error: Option 'asan-instrument-assembly' registered more"

is still not fixed so you still need to patch mesa or llvm.

"amdgpu" doesn't work with this card and will never work, If you are using a 2015 MBP believe me when I said "I tried everything" and in addition fglrx was apparently deleted from portage so your only option is radeon if you want a graphical acceleration (opengl or vulkan).

So, after fixing the same problems I had with the carrizo GPU I had a brand new problem:

Code:

===========
VULKAN INFO
===========

Vulkan API Version: 1.0.51

INFO: [loader] Code 0 : Found ICD manifest file /usr/share/vulkan/icd.d/radeon_icd.x86_64.json, version "1.0.0"

Instance Extensions:
====================
Instance Extensions     count = 5
        VK_KHR_surface                      : extension revision 25
        VK_KHR_xcb_surface                  : extension revision  6
        VK_KHR_xlib_surface                 : extension revision  6
        VK_KHR_get_physical_device_properties2: extension revision  1
        VK_EXT_debug_report                 : extension revision  8
/var/lib/jenkins/workspace/Create-Linux-VulkanSDK/Vulkan-LoaderAndValidationLayers/demos/vulkaninfo.c:1464: failed with VK_ERROR_INITIALIZATION_FAILED



I have "media-libs/mesa-17.1.4"(patched) "Linux 4.12.0-rc7" "sys-devel/llvm-4.0.1" "sys-devel/clang-4.0.1" "x11-base/xorg-server-1.19.3" "x11-drivers/xf86-video-ati-7.9.0" "media-libs/vulkan-loader-1.0.51.0" and the LunarG Vulkan SDK 1.0.51.0

According to this file: https://github.com/KhronosGroup/Vulkan-LoaderAndValidationLayers/blob/a0cd07209eef7aaaac689c0b2c3ce1b2b4651c24/demos/vulkaninfo.c the fail seems to come from "err = vkEnumeratePhysicalDevices(inst.instance, &gpu_count, NULL);" and I don't know why. My GPU isn't compatible with vulkan ? Do you think it's a bug and I should talk with a RADV dev ? I failed something in the install ?

Note: I noticed that some vulkan-related files given by mesa are also present in the lunarG SDK but I don't which I should keep (in doubt I trusted the mesa ones because they are compiled on my machine...).
_________________
uname -a: Linux legion 4.12.0-rc7 #2 SMP Sun Jul 2 22:07:50 CEST 2017 x86_64 Intel(R) Core(TM) i7-4870HQ CPU @ 2.50GHz GenuineIntel GNU/Linux
gcc : gcc (Gentoo 5.4.0-r3 p1.3, pie-0.6.5) 5.4.0
window manager : dwm 6.1
web browser : Vivaldi 1.10.867.42
Back to top
View user's profile Send private message
pcmaster
Advocate
Advocate


Joined: 04 Dec 2003
Posts: 2160
Location: Barcelona

PostPosted: Sun Jul 30, 2017 8:01 am    Post subject: Reply with quote

Try with this: https://github.com/volumetricsteve/AMDGPU-INSTALL
_________________
pcmaster
Back to top
View user's profile Send private message
newin
n00b
n00b


Joined: 27 Oct 2012
Posts: 27

PostPosted: Sun Jul 30, 2017 9:33 pm    Post subject: Reply with quote

pcmaster wrote:
Try with this: https://github.com/volumetricsteve/AMDGPU-INSTALL


AMDGPU-pro driver is a user-land driver that need amdgpu kernel-land driver to work. And like I said before amdgpu is giving a black-screen BEFORE startx (so the X11 user-land driver didn't even started yet) so I cannot use this solution.
_________________
uname -a: Linux legion 4.12.0-rc7 #2 SMP Sun Jul 2 22:07:50 CEST 2017 x86_64 Intel(R) Core(TM) i7-4870HQ CPU @ 2.50GHz GenuineIntel GNU/Linux
gcc : gcc (Gentoo 5.4.0-r3 p1.3, pie-0.6.5) 5.4.0
window manager : dwm 6.1
web browser : Vivaldi 1.10.867.42
Back to top
View user's profile Send private message
EoD
n00b
n00b


Joined: 30 May 2008
Posts: 35

PostPosted: Mon Jul 31, 2017 9:51 am    Post subject: Reply with quote

newin wrote:
pcmaster wrote:
Try with this: https://github.com/volumetricsteve/AMDGPU-INSTALL


AMDGPU-pro driver is a user-land driver that need amdgpu kernel-land driver to work. And like I said before amdgpu is giving a black-screen BEFORE startx (so the X11 user-land driver didn't even started yet) so I cannot use this solution.


If your kernel does not work for your hardware, you should report this upstream at https://bugs.freedesktop.org/enter_bug.cgi?product=DRI

You could try using one of the bleeding-edge kernels from AMD https://cgit.freedesktop.org/~agd5f/linux for example. Just get one of the active branches like "amd-staging-drm-next" or "drm-next-4.13" or whatever you see fit.

It might also be a good idea to ask in #radeon on freenode if any of those branches might fix the issue.
_________________
Sun Blade 100 (UltraSPARC IIe) server with multilib and Java
----
Gentoo/SPARC, Gentoo/AMD64, Gentoo/x86
Back to top
View user's profile Send private message
bill7
n00b
n00b


Joined: 07 Nov 2017
Posts: 1

PostPosted: Tue Nov 07, 2017 3:05 am    Post subject: llvm, clang with BUILD_SHARED_LIBS Reply with quote

Hi Folks,

Does anyone know why llvm and clang are (gentoo default) compiled with BUILD_SHARED_LIBS rather than with LLVM_BUILD_LLVM_DYLIB?

From what I've seen it is not generally recommended
https://releases.llvm.org/5.0.0/docs/CMake.html

And leads to problems like:
https://bugs.gentoo.org/617154

When configured with LLVM_BUILD_LLVM_DYLIB, media-libs/mesa-17.3.0_rc2 installs successfully (provided the shared libs are disabled with --disable-llvm-shared-libs), then the runtime error mentioned in bug 61754 no longer exists.

I'm guessing that building with BUILD_SHARED_LIBS might be required by other packages? Tried a few like dev-libs/libclc, but this builds cleanly as well.

Any ideas?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
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 vote in polls in this forum