aboutsummaryrefslogtreecommitdiff
path: root/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.h
diff options
context:
space:
mode:
authorFraser Cormack <fraser@codeplay.com>2025-01-16 11:44:09 +0000
committerGitHub <noreply@github.com>2025-01-16 11:44:09 +0000
commitb7e20147ad7c29f9624d2a071bd348a7acd63461 (patch)
treeabc944af8510508317ea60795710ab12963986f2 /lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.h
parent628976c8345e235d4f71a0715f1990ad8b5bbcf7 (diff)
downloadllvm-b7e20147ad7c29f9624d2a071bd348a7acd63461.zip
llvm-b7e20147ad7c29f9624d2a071bd348a7acd63461.tar.gz
llvm-b7e20147ad7c29f9624d2a071bd348a7acd63461.tar.bz2
[libclc] Move smoothstep to CLC and optimize its codegen (#123183)
This commit moves the implementation of the smoothstep function to the CLC library, whilst optimizing the codegen. This commit also adds support for 'half' versions of smoothstep, which were previously missing. The CLC smoothstep implementation now keeps everything in vectors, rather than recursively splitting vectors by half down to the scalar base form. This should result in more optimal codegen across the board. This commit also removes some non-standard overloads of smoothstep with mixed types, such as 'double smoothstep(float, float, float)'. There aren't any mixed-(element )type versions of smoothstep as far as I can see: gentype smoothstep(gentype edge0, gentype edge1, gentype x) gentypef smoothstep(float edge0, float edge1, gentypef x) gentyped smoothstep(double edge0, double edge1, gentyped x) gentypeh smoothstep(half edge0, half edge1, gentypeh x) The CLC library only defines the first type, for simplicity; the OpenCL layer is responsible for handling the scalar/scalar/vector forms. Note that the scalar/scalar/vector forms now splat the scalars to the vector type, rather than recursively split vectors as before. The macro that used to 'vectorize' smoothstep in this way has been moved out of the shared clcmacro.h header as it was only used for the smoothstep builtin. Note that the CLC clamp function is now built for both SPIR-V targets. This is to help build the CLC smoothstep function for the Mesa SPIR-V target.
Diffstat (limited to 'lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.h')
0 files changed, 0 insertions, 0 deletions