diff --git a/include/sirit/sirit.h b/include/sirit/sirit.h index bdd42c6..34f9b93 100644 --- a/include/sirit/sirit.h +++ b/include/sirit/sirit.h @@ -793,6 +793,9 @@ public: /// Result is the reciprocal of sqrt x. Result is undefined if x <= 0. Id OpInverseSqrt(Id result_type, Id x); + /// Result is a floating-point number from x and the corresponding integral exponent of two in exp. + Id OpLdexp(Id result_type, Id x, Id exp); + /// Result is y if y < x; otherwise result is x. Which operand is the result is undefined if one /// of the operands is a NaN. Id OpFMin(Id result_type, Id x, Id y); diff --git a/src/instructions/extension.cpp b/src/instructions/extension.cpp index bd61caa..44dc691 100644 --- a/src/instructions/extension.cpp +++ b/src/instructions/extension.cpp @@ -54,6 +54,7 @@ DEFINE_UNARY(OpExp2, GLSLstd450Exp2) DEFINE_UNARY(OpLog2, GLSLstd450Log2) DEFINE_UNARY(OpSqrt, GLSLstd450Sqrt) DEFINE_UNARY(OpInverseSqrt, GLSLstd450InverseSqrt) +DEFINE_BINARY(OpLdexp, GLSLstd450Ldexp) DEFINE_BINARY(OpFMin, GLSLstd450FMin) DEFINE_BINARY(OpUMin, GLSLstd450UMin) DEFINE_BINARY(OpSMin, GLSLstd450SMin)