This is the mail archive of the
fortran@gcc.gnu.org
mailing list for the GNU Fortran project.
Re: [libgfortran, patch] Remove runtime clz() and ctz() bit intrisic functions
- From: Janne Blomqvist <blomqvist dot janne at gmail dot com>
- To: FX <fxcoudert at gmail dot com>
- Cc: GCC-Fortran-ML <fortran at gcc dot gnu dot org>, gcc-patches <gcc-patches at gcc dot gnu dot org>
- Date: Mon, 19 Dec 2016 17:44:21 +0200
- Subject: Re: [libgfortran, patch] Remove runtime clz() and ctz() bit intrisic functions
- Authentication-results: sourceware.org; auth=none
- References: <212488F8-4C9A-45E8-A4F8-E9B6A54C465A@gmail.com>
On Mon, Dec 19, 2016 at 4:48 PM, FX <fxcoudert@gmail.com> wrote:
> We implement the LEADZ and TRAILZ intrinsics in terms of the built-in clz() and ctz() functions. Since these are not available for 128-bit integer types, we used to have support functions _gfortran_clz128() and _gfortran_ctz128() in libgfortran. In 2010, I applied a patch to avoid this and emit the necessary arithmetic directly from the front-end (https://gcc.gnu.org/ml/fortran/2010-09/msg00181.html). The support functions were kept in libgfortran for backward compatibility, but we can now remove them as we break the ABI.
>
> Attached patch is bootstrapped and regtested on x86_64-apple-darwin13.6.0.
> OK to commit?
Hmm, I distinctly remember that this was part of my big-ish patch I
just committed, but on closer inspection, no, maybe I just had it
queued up in my own branch..
So yes, Ok!
--
Janne Blomqvist