This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Two suggestions for gcc C compiler to extend C language (by WD Smith)
- From: Joseph Myers <joseph at codesourcery dot com>
- To: Warren D Smith <warren dot wds at gmail dot com>
- Cc: <gcc at gcc dot gnu dot org>
- Date: Tue, 26 Jul 2016 14:49:05 +0000
- Subject: Re: Two suggestions for gcc C compiler to extend C language (by WD Smith)
- Authentication-results: sourceware.org; auth=none
- References: <CAAJP7Y3cHYEOpdhZUXF1PZAJ=vkKoozRiPgwm2V_jH_T63XTKw@mail.gmail.com>
On Tue, 26 Jul 2016, Warren D Smith wrote:
> However, why not provide access to double-precision multiply and
> add-with-carry (subtract with borrow? shift-left?) in the same fashion?
> twofer x = mul(a,b); would cause x.hi and x.lo to be computed.
> twofer x = addwithcarry(a,b) ditto.
If add-with-carry were provided then it would be appropriate to provide
Clang-compatible __builtin_addc* (in addition to any type-generic form
provided to allow the functionality to be used with types such unsigned
__int128). (I don't see Clang built-ins to be compatible with for
double-precision multiply.)
--
Joseph S. Myers
joseph@codesourcery.com