GCC Bugzilla – Bug 17631
libfortran: intrinsic subroutine MVBITS not implemented
Last modified: 2004-10-04 21:19:15 UTC
Hi, MVBITS appears to not to be implemented. program gfcbug13 implicit none integer :: to to = 0 call mvbits (from=1, frompos=0, len=1, to=to, topos=1) if (to /= 2) then print *, "Error, TO =", to end if end program gfcbug13 The example fails to link with error message: gfcbug13.f90: undefined reference to `__gfortran_mvbits' collect2: ld returned 1 exit status Cheers, -ha
Confirmed.
Patch here: <http://gcc.gnu.org/ml/gcc-patches/2004-09/msg02414.html>.
Patch as posted is wrong, but the followup has the fix.
Subject: Bug 17631 CVSROOT: /cvs/gcc Module name: gcc Changes by: tobi@gcc.gnu.org 2004-10-04 20:49:39 Modified files: gcc/fortran : ChangeLog intrinsic.c intrinsic.h iresolve.c libgfortran : ChangeLog Makefile.am Makefile.in gcc/testsuite : ChangeLog Added files: gcc/testsuite/gfortran.fortran-torture/execute: intrinsic_mvbits.f90 Log message: PR fortran/17631 fortran/ * intrinsic.c (add_sym_5): Remove. (add_subroutines): Add resolution function for MVBITS. * intrinsic.h (gfc_resolve_mvbits): Declare resolution function for MVBITS * iresolve.c (gfc_resolve_mvbits): New function. (gfc_resolve_random_number): Remove empty line at end of function. libgfortran/ * Makefile.am (gfor_helper_src): Add intrinsics/mvbits.h. * intrinsics/mvbits.h: New file. testsuite/ * gfortran.fortran-torture/execute/intrinsic_mvbits.f90: New test. Patches: http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/fortran/ChangeLog.diff?cvsroot=gcc&r1=1.223&r2=1.224 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/fortran/intrinsic.c.diff?cvsroot=gcc&r1=1.23&r2=1.24 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/fortran/intrinsic.h.diff?cvsroot=gcc&r1=1.16&r2=1.17 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/fortran/iresolve.c.diff?cvsroot=gcc&r1=1.18&r2=1.19 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libgfortran/ChangeLog.diff?cvsroot=gcc&r1=1.97&r2=1.98 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libgfortran/Makefile.am.diff?cvsroot=gcc&r1=1.18&r2=1.19 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libgfortran/Makefile.in.diff?cvsroot=gcc&r1=1.18&r2=1.19 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&r1=1.4383&r2=1.4384 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gfortran.fortran-torture/execute/intrinsic_mvbits.f90.diff?cvsroot=gcc&r1=NONE&r2=1.1
Fixed.