Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 685286 - media-libs/mesa-19.1.0_rc2[vulkan-overlay] fails to compile with: src/vulkan/overlay-layer/overlay.cpp:2036:18: error: invalid conversion from ‘VkQueryPool’ {aka ‘long long unsigned int’} to ‘void*’ [-fpermissive]
Summary: media-libs/mesa-19.1.0_rc2[vulkan-overlay] fails to compile with: src/vulkan/...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo X packagers
URL:
Whiteboard:
Keywords:
: 685478 (view as bug list)
Depends on:
Blocks:
 
Reported: 2019-05-07 21:25 UTC by mercuriete
Modified: 2019-05-22 17:26 UTC (History)
2 users (show)

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


Attachments
build.log (build.tar.gz,24.01 KB, application/gzip)
2019-05-07 21:25 UTC, mercuriete
Details
emerge_info (emerge_info,5.93 KB, text/plain)
2019-05-07 21:28 UTC, mercuriete
Details

Note You need to log in before you can comment on or make changes to this bug.
Description mercuriete 2019-05-07 21:25:20 UTC
Created attachment 575476 [details]
build.log

media-libs/mesa-19.1.0_rc1 vulkan overlay fails to compile

probably in x86_32 build

partial output:

----------

-c ../mesa-19.1.0-rc1/src/vulkan/overlay-layer/overlay.cpp
../mesa-19.1.0-rc1/src/vulkan/overlay-layer/overlay.cpp: In function ‘VkResult overlay_AllocateCommandBuffers(VkDevice, const VkCommandBufferAllocateInfo*, VkCommandBuffer_T**)’:
../mesa-19.1.0-rc1/src/vulkan/overlay-layer/overlay.cpp:2014:18: error: invalid conversion from ‘VkQueryPool’ {aka ‘long long unsigned int’} to ‘void*’ [-fpermissive]
       map_object(pipeline_query_pool, (void *)(uintptr_t) pAllocateInfo->commandBufferCount);
                  ^~~~~~~~~~~~~~~~~~~
../mesa-19.1.0-rc1/src/vulkan/overlay-layer/overlay.cpp:227:30: note:   initializing argument 1 of ‘void map_object(void*, void*)’
 static void map_object(void *obj, void *data)
                        ~~~~~~^~~
../mesa-19.1.0-rc1/src/vulkan/overlay-layer/overlay.cpp:2016:18: error: invalid conversion from ‘VkQueryPool’ {aka ‘long long unsigned int’} to ‘void*’ [-fpermissive]
       map_object(timestamp_query_pool, (void *)(uintptr_t) pAllocateInfo->commandBufferCount);
                  ^~~~~~~~~~~~~~~~~~~~
../mesa-19.1.0-rc1/src/vulkan/overlay-layer/overlay.cpp:227:30: note:   initializing argument 1 of ‘void map_object(void*, void*)’
 static void map_object(void *obj, void *data)
                        ~~~~~~^~~
../mesa-19.1.0-rc1/src/vulkan/overlay-layer/overlay.cpp: In function ‘void overlay_FreeCommandBuffers(VkDevice, VkCommandPool, uint32_t, VkCommandBuffer_T* const*)’:
../mesa-19.1.0-rc1/src/vulkan/overlay-layer/overlay.cpp:2033:40: error: invalid conversion from ‘VkQueryPool’ {aka ‘long long unsigned int’} to ‘void*’ [-fpermissive]
          unmap_object(cmd_buffer_data->pipeline_query_pool);
                       ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~
../mesa-19.1.0-rc1/src/vulkan/overlay-layer/overlay.cpp:235:32: note:   initializing argument 1 of ‘void unmap_object(void*)’
 static void unmap_object(void *obj)
                          ~~~~~~^~~
../mesa-19.1.0-rc1/src/vulkan/overlay-layer/overlay.cpp:2037:38: error: invalid conversion from ‘VkQueryPool’ {aka ‘long long unsigned int’} to ‘void*’ [-fpermissive]
          map_object(cmd_buffer_data->pipeline_query_pool, (void *)(uintptr_t)(count - 1));
                     ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~
../mesa-19.1.0-rc1/src/vulkan/overlay-layer/overlay.cpp:227:30: note:   initializing argument 1 of ‘void map_object(void*, void*)’
 static void map_object(void *obj, void *data)
                        ~~~~~~^~~
../mesa-19.1.0-rc1/src/vulkan/overlay-layer/overlay.cpp:2041:40: error: invalid conversion from ‘VkQueryPool’ {aka ‘long long unsigned int’} to ‘void*’ [-fpermissive]
          unmap_object(cmd_buffer_data->timestamp_query_pool);
                       ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~
../mesa-19.1.0-rc1/src/vulkan/overlay-layer/overlay.cpp:235:32: note:   initializing argument 1 of ‘void unmap_object(void*)’
 static void unmap_object(void *obj)
                          ~~~~~~^~~
../mesa-19.1.0-rc1/src/vulkan/overlay-layer/overlay.cpp:2045:38: error: invalid conversion from ‘VkQueryPool’ {aka ‘long long unsigned int’} to ‘void*’ [-fpermissive]
          map_object(cmd_buffer_data->timestamp_query_pool, (void *)(uintptr_t)(count - 1));
                     ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~
../mesa-19.1.0-rc1/src/vulkan/overlay-layer/overlay.cpp:227:30: note:   initializing argument 1 of ‘void map_object(void*, void*)’
 static void map_object(void *obj, void *data)
                        ~~~~~~^~~
ninja: build stopped: subcommand failed.

------------------------

* ERROR: media-libs/mesa-19.1.0_rc1::gentoo failed (compile phase):
 *   ninja -v -j1 -l0 -C /var/tmp/portage/media-libs/mesa-19.1.0_rc1/work/mesa-19.1.0-rc1-abi_x86_32.x86 failed

----------------------------
Comment 1 mercuriete 2019-05-07 21:28:56 UTC
Created attachment 575478 [details]
emerge_info
Comment 2 mercuriete 2019-05-07 21:29:23 UTC
sudo emerge --oneshot --ask --verbose mesa                                       

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild     U ~] media-libs/mesa-19.1.0_rc1::gentoo [19.0.3::gentoo] USE="classic dri3 egl gallium gbm gles2 llvm lm_sensors vaapi vulkan vulkan-overlay%* wayland -d3d9 -debug -gles1 (-libglvnd) -opencl -osmesa -pax_kernel -pic (-selinux) -test -unwind -valgrind -vdpau -xa -xvmc" ABI_X86="32 (64) (-x32)" VIDEO_CARDS="radeon radeonsi (-freedreno) -i915 -i965 -intel -iris% -nouveau -r100 -r200 -r300 -r600 (-vc4) -virgl (-vivante) -vmware (-imx%)" 0 KiB

Total: 1 package (1 upgrade), Size of downloads: 0 KiB

Would you like to merge these packages? [Yes/No] n
Comment 3 mercuriete 2019-05-07 21:35:59 UTC
I can confirm that if I disable vulkan-overlay use flag it compiles perfect and I can use vkcube as usual.
Comment 4 mercuriete 2019-05-08 17:20:14 UTC
Im not sure if is an upstream bug or is a gentoo bug.

But I read the documentation about 
invalid conversion from x to ‘void*’ [-fpermissive]

and for me seems an upstream bug but I dont have enough knowledge for creating a patch.

Thanks for your work in advance :)
Comment 5 mercuriete 2019-05-10 16:54:22 UTC
I can confirm that puting this patch from upstream:

https://cgit.freedesktop.org/mesa/mesa/patch/?id=2d2927938f074f402cab28aa5322567a76cbde58

in /etc/portage/patches/media-libs/mesa-19.1.0_rc1


the problems goes away but then another problem appears.


n/overlay-layer/overlay.cpp
../mesa-19.1.0-rc1/src/vulkan/overlay-layer/overlay.cpp:42:10: fatal error: vk_enum_to_str.h: No such file or directory
 #include "vk_enum_to_str.h"


So I will wait until next RC.
Comment 6 Matt Turner gentoo-dev 2019-05-15 17:34:09 UTC
*** Bug 685478 has been marked as a duplicate of this bug. ***
Comment 7 Matt Turner gentoo-dev 2019-05-15 17:42:52 UTC
(In reply to mercuriete from comment #5)
> I can confirm that puting this patch from upstream:
> 
> https://cgit.freedesktop.org/mesa/mesa/patch/
> ?id=2d2927938f074f402cab28aa5322567a76cbde58
> 
> in /etc/portage/patches/media-libs/mesa-19.1.0_rc1
> 
> 
> the problems goes away but then another problem appears.
> 
> 
> n/overlay-layer/overlay.cpp
> ../mesa-19.1.0-rc1/src/vulkan/overlay-layer/overlay.cpp:42:10: fatal error:
> vk_enum_to_str.h: No such file or directory
>  #include "vk_enum_to_str.h"
> 
> 
> So I will wait until next RC.

Thanks, that's very helpful.

I've pinged people to see if we can cherry-pick that into the 19.1 RCs.
Comment 8 mercuriete 2019-05-15 18:47:35 UTC
Same happen to rc2:

Not sure whats going on because but it seems another people could reproduce.

Can you change the status to confirmed?

I will try to change the name of the bug to rc2.

thanks for your work :)


-----

-c ../mesa-19.1.0-rc2/src/vulkan/overlay-layer/overlay.cpp
../mesa-19.1.0-rc2/src/vulkan/overlay-layer/overlay.cpp: In function ‘VkResult overlay_AllocateCommandBuffers(VkDevice, const VkCommandBufferAllocateInfo*, VkCommandBuffer_T**)’:
../mesa-19.1.0-rc2/src/vulkan/overlay-layer/overlay.cpp:2036:18: error: invalid conversion from ‘VkQueryPool’ {aka ‘long long unsigned int’} to ‘void*’ [-fpermissive]
       map_object(pipeline_query_pool, (void *)(uintptr_t) pAllocateInfo->commandBufferCount);
                  ^~~~~~~~~~~~~~~~~~~
../mesa-19.1.0-rc2/src/vulkan/overlay-layer/overlay.cpp:232:30: note:   initializing argument 1 of ‘void map_object(void*, void*)’
 static void map_object(void *obj, void *data)
                        ~~~~~~^~~
../mesa-19.1.0-rc2/src/vulkan/overlay-layer/overlay.cpp:2038:18: error: invalid conversion from ‘VkQueryPool’ {aka ‘long long unsigned int’} to ‘void*’ [-fpermissive]
       map_object(timestamp_query_pool, (void *)(uintptr_t) pAllocateInfo->commandBufferCount);
                  ^~~~~~~~~~~~~~~~~~~~
../mesa-19.1.0-rc2/src/vulkan/overlay-layer/overlay.cpp:232:30: note:   initializing argument 1 of ‘void map_object(void*, void*)’
 static void map_object(void *obj, void *data)
                        ~~~~~~^~~
../mesa-19.1.0-rc2/src/vulkan/overlay-layer/overlay.cpp: In function ‘void overlay_FreeCommandBuffers(VkDevice, VkCommandPool, uint32_t, VkCommandBuffer_T* const*)’:
../mesa-19.1.0-rc2/src/vulkan/overlay-layer/overlay.cpp:2055:40: error: invalid conversion from ‘VkQueryPool’ {aka ‘long long unsigned int’} to ‘void*’ [-fpermissive]
          unmap_object(cmd_buffer_data->pipeline_query_pool);
                       ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~
../mesa-19.1.0-rc2/src/vulkan/overlay-layer/overlay.cpp:240:32: note:   initializing argument 1 of ‘void unmap_object(void*)’
 static void unmap_object(void *obj)
                          ~~~~~~^~~
../mesa-19.1.0-rc2/src/vulkan/overlay-layer/overlay.cpp:2059:38: error: invalid conversion from ‘VkQueryPool’ {aka ‘long long unsigned int’} to ‘void*’ [-fpermissive]
          map_object(cmd_buffer_data->pipeline_query_pool, (void *)(uintptr_t)(count - 1));
                     ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~
../mesa-19.1.0-rc2/src/vulkan/overlay-layer/overlay.cpp:232:30: note:   initializing argument 1 of ‘void map_object(void*, void*)’
 static void map_object(void *obj, void *data)
                        ~~~~~~^~~
../mesa-19.1.0-rc2/src/vulkan/overlay-layer/overlay.cpp:2063:40: error: invalid conversion from ‘VkQueryPool’ {aka ‘long long unsigned int’} to ‘void*’ [-fpermissive]
          unmap_object(cmd_buffer_data->timestamp_query_pool);
                       ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~
../mesa-19.1.0-rc2/src/vulkan/overlay-layer/overlay.cpp:240:32: note:   initializing argument 1 of ‘void unmap_object(void*)’
 static void unmap_object(void *obj)
                          ~~~~~~^~~
../mesa-19.1.0-rc2/src/vulkan/overlay-layer/overlay.cpp:2067:38: error: invalid conversion from ‘VkQueryPool’ {aka ‘long long unsigned int’} to ‘void*’ [-fpermissive]
          map_object(cmd_buffer_data->timestamp_query_pool, (void *)(uintptr_t)(count - 1));
                     ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~
../mesa-19.1.0-rc2/src/vulkan/overlay-layer/overlay.cpp:232:30: note:   initializing argument 1 of ‘void map_object(void*, void*)’
 static void map_object(void *obj, void *data)
Comment 9 Matt Turner gentoo-dev 2019-05-15 18:54:55 UTC
From the upstream patch, it seems that this code compiles with gcc-8.3.0 and fails with some older version of gcc... but you're using gcc-8.3.0, so I'm not sure what's going on.
Comment 10 Mike Lothian 2019-05-15 21:05:56 UTC
The issue was 32bit casting not the compiler, fixed upstream
Comment 11 Dennis Schridde 2019-05-15 21:16:41 UTC
Could the bug summary please be adjusted to include the error message and the actual name of the use flag? For an example see bug #685478.
Comment 12 Mike Lothian 2019-05-16 10:41:17 UTC
The fix is in master

https://gitlab.freedesktop.org/mesa/mesa/commit/877b371cbb2c51cd569d8e5bb3f00ef6d9724336

And as of 2 hours ago it's in the 19.1 branch, so should be in the next RC
Comment 13 mercuriete 2019-05-16 17:37:08 UTC
I can confirm that

mesa-9999 compiles fine.

I can confirm as well that the overlay is working on dota2 but not sure if dota2 is a 32 bit application or 64 bit.


So they messed up some patches from master to staging-19.1

From my side I can wait to mesa 19.2 because is a feature not too much important.

I can try to check the differences between overlay folder from 19.1 and master but not sure how to do it.



Thanks for your work :)
Comment 14 mercuriete 2019-05-16 17:40:35 UTC
ok, I didn't read the previuous comments.

I will wait to rc3

thanks :)
Comment 15 Matt Turner gentoo-dev 2019-05-22 03:53:05 UTC
Fixed with rc3.
Comment 16 mercuriete 2019-05-22 17:26:26 UTC
Can confirm rc3 fixes this issue.
vulkan-overlay tested with vkcube and it works.


Thank you for your amazing work :)

---

glxinfo |grep "core profile version string"
OpenGL core profile version string: 4.5 (Core Profile) Mesa 19.1.0-rc3