RELATIONALFUNCTIONS(3clc)
π RELATIONAL BUILT-IN π
okay bestie, welcome to the relational built-in page of the OpenCL Manual β this is RELATIONAL BUILT-IN(3clc), and it's basically a little link menu: click an item in the table below for details about that function. π«Ά
Every single one of these is component-wise coded, so let's get into it. π
β¨ NAME β¨
Relational_Built-In_Functions β click an item in the table below for details about that function. π
The original table was a whole grid moment, so here it is as the same list of entries with the exact same tea:
isequal(3clc)β Component-wise compare ofx == y.isnotequal(3clc)β Component-wise compare ofx != y.isgreater(3clc)β Component-wise compare ofx > y.isgreaterequal(3clc)β Component-wise compare ofx >= y.isless(3clc)β Component-wise compare ofx < y.islessequal(3clc)β Component-wise compare ofx <= y.islessgreater(3clc)β Component-wise compare of(x < y) || (x > y).isfinite(3clc)β Test for finite value.isinf(3clc)β Test for positive or negative infinity.isnan(3clc)β Test for a NaN.isnormal(3clc)β Test for a normal value.isordered(3clc)β Test if arguments are ordered.isunordered(3clc)β Test if arguments are unordered.signbit(3clc)β Test for sign bit.any(3clc)β 1 if MSB in any component ofxis set; else 0.any(3clc)β 1 if MSB in all components ofxis set; else 0. (no bestie, that's not me glitching β the table really does sayany(3clc)again here, i'm just relaying it π)bitselect(3clc)β Each bit of result is corresponding bit ofaif corresponding bit ofcis 0.select(3clc)β For each component of a vector type,result[i] = if MSB of c[i] is set ? b[i] : a[i]For scalar type,result = c ? b : a.
πΈ DESCRIPTION πΈ
okay so here's the one detail that actually matters, no cap: if an implementation extends this specification to support IEEE-754 flags or exceptions, then all built-in relational functions shall proceed without raising the invalid floating-point exception when one or more of the operands are NaNs. β¨
likeβ¦ NaN showing up is not a crisis, it's just Tuesday. no invalid exception drama. π
π SPECIFICATION π
OpenCL Specification[1] π
π AUTHORS π
The Khronos Group π
π COPYRIGHT π
Copyright Β© 2007-2011 The Khronos Group Inc.
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and/or associated documentation files (the "Materials"), to deal in the Materials without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Materials, and to permit persons to whom the Materials are furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Materials.
π§ NOTES π§
- OpenCL Specification page 264, section 6.12.6 - Relational Functions
and that's the whole page, bestie!! π¦ this one came straight from The Khronos Group, dated 01/14/2021, and it's the RELATIONAL BUILT-IN(3clc) page from the OpenCL Manual β go forth and compare component-wise, you absolute icon. ππ₯
π¦ where this page comes from
- ubuntu jammy: opencl-1.2-man-doc 1.0~svn33624-5 Β· other
- ubuntu noble: opencl-1.2-man-doc 1.0~svn33624-5 Β· other
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms