[clang] [clang] Implement __builtin_rotate{left,right}g (PR #160259)
Timm Baeder via cfe-commits
cfe-commits at lists.llvm.org
Tue Sep 23 02:25:45 PDT 2025
================
@@ -767,12 +767,24 @@ def RotateLeft : BitInt8_16_32_64BuiltinsTemplate, Builtin {
let Prototype = "T(T, T)";
}
+def RotateLeftg : Builtin {
+ let Spellings = ["__builtin_rotateleftg"];
+ let Attributes = [NoThrow, Const, Constexpr, CustomTypeChecking];
+ let Prototype = "void(...)";
+}
+
def RotateRight : BitInt8_16_32_64BuiltinsTemplate, Builtin {
let Spellings = ["__builtin_rotateright"];
let Attributes = [NoThrow, Const, Constexpr];
let Prototype = "T(T, T)";
}
+def RotateRightg : Builtin {
+ let Spellings = ["__builtin_rotaterightg"];
+ let Attributes = [NoThrow, Const, Constexpr, CustomTypeChecking];
----------------
tbaederr wrote:
There's no constexpr implementation in this patch.
https://github.com/llvm/llvm-project/pull/160259
More information about the cfe-commits
mailing list