Bug 96495

Summary: [radeonsi] can't compile shaders with pow(10.0, x)
Product: Mesa Reporter: Vladislav Egorov <vegorov180>
Component: Drivers/Gallium/radeonsiAssignee: Default DRI bug account <dri-devel>
Status: RESOLVED FIXED QA Contact: Default DRI bug account <dri-devel>
Severity: normal    
Priority: medium    
Version: git   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:

Description Vladislav Egorov 2016-06-11 14:07:18 UTC
For example https://www.shadertoy.com/view/MddGzf LLVM somewhere optimizes it into exp10f:

56126: message: shader compiler issue 2: LLVM diagnostic (error): <unknown>:0:0: in function main <{ i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, float, float, float, float, float, float, float, float, float, float, float, float, float, float }> ([17 x <16 x i8>] addrspace(2)*, [16 x <16 x i8>] addrspace(2)*, [32 x <8 x i32>] addrspace(2)*, [16 x <8 x i32>] addrspace(2)*, [16 x <4 x i32>] addrspace(2)*, float, i32, <2 x i32>, <2 x i32>, <2 x i32>, <3 x i32>, <2 x i32>, <2 x i32>, <2 x i32>, float, float, float, float, float, i32, i32, float, i32): unsupported call to function exp10f
LLVM triggered Diagnostic Handler: <unknown>:0:0: in function main <{ i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, float, float, float, float, float, float, float, float, float, float, float, float, float, float }> ([17 x <16 x i8>] addrspace(2)*, [16 x <16 x i8>] addrspace(2)*, [32 x <8 x i32>] addrspace(2)*, [16 x <8 x i32>] addrspace(2)*, [16 x <4 x i32>] addrspace(2)*, float, i32, <2 x i32>, <2 x i32>, <2 x i32>, <3 x i32>, <2 x i32>, <2 x i32>, <2 x i32>, float, float, float, float, float, i32, i32, float, i32): unsupported call to function exp10f

56126: message: shader compiler issue 3: LLVM compile failed
LLVM failed to compile shader
radeonsi: can't create a shader
Comment 1 Nicolai Hähnle 2016-06-13 08:45:25 UTC
Hi Vladislav, thanks for the report. I'm looking into it.
Comment 2 Nicolai Hähnle 2016-06-13 09:06:52 UTC
The patch at http://reviews.llvm.org/D21282 fixes this for me.
Comment 3 Daniel Scharrer 2016-10-03 12:38:55 UTC
The patch linked in comment #2 has been merged and the shadertoy testcase works for me with git Mesa & LLVM.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.