支持大整数的 LLVM 前端
LLVM frontend supporting large integers
我目前正在寻找支持大整数的 LLVM 前端,例如 i128
、i256
和 i512
。据我所知,rust 和 clang 支持 i128
,但上面没有。
这样的前端是否已经存在,还是我必须自己制作?
最近添加到 clang(在即将推出的 Clang 12 中)的是 _ExtInt(N)
,在 C 和 C++ 中实现 N2472。
基本上,_ExtInt(N)
和 unsigned _ExtInt(N)
类型为 llvm 中的任意 N 公开 iN
。所以你可以使用这些:
typedef _ExtInt(256) i256;
typedef _ExtInt(512) i512;
在 C 或 C++ 前端中。
我目前正在寻找支持大整数的 LLVM 前端,例如 i128
、i256
和 i512
。据我所知,rust 和 clang 支持 i128
,但上面没有。
这样的前端是否已经存在,还是我必须自己制作?
最近添加到 clang(在即将推出的 Clang 12 中)的是 _ExtInt(N)
,在 C 和 C++ 中实现 N2472。
基本上,_ExtInt(N)
和 unsigned _ExtInt(N)
类型为 llvm 中的任意 N 公开 iN
。所以你可以使用这些:
typedef _ExtInt(256) i256;
typedef _ExtInt(512) i512;
在 C 或 C++ 前端中。