New functions (added by #3561) _Add_overflow<Int> and _Multiply_overflow<Int> could be much faster when Int is:
-
Standard integer type. MSVC should consider implementing Clang's checked arithmetic builtins (__builtin_add_overflow and __builtin_mul_overflow). This would vastly improve performance and codegen.
Also tracked by DevCom-10326281.
-
Integer-class type. I believe that it is possible to implement those checked operations directly in _Signed128 and _Unsigned128, for example by modifying already existing functions (overflow could be detected during addition/multiplication?).
This requires further investigation.
New functions (added by #3561)
_Add_overflow<Int>and_Multiply_overflow<Int>could be much faster whenIntis:Standard integer type. MSVC should consider implementing Clang's checked arithmetic builtins (
__builtin_add_overflowand__builtin_mul_overflow). This would vastly improve performance and codegen.Also tracked by DevCom-10326281.
Integer-class type. I believe that it is possible to implement those checked operations directly in
_Signed128and_Unsigned128, for example by modifying already existing functions (overflow could be detected during addition/multiplication?).This requires further investigation.