https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88303

--- Comment #4 from Steve Kargl <sgk at troutmask dot apl.washington.edu> ---
On Mon, Dec 03, 2018 at 08:37:32AM +0000, jakub at gcc dot gnu.org wrote:
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88303
> 
> --- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
> Libgomp certainly does respect RUNTESTFLAGS, I use
> make check-target-libgomp RUNTESTFLAGS=c.exp=atomic-2.c
> and similar very often.
> 
> Isn't the problem that toplevel check-fortran depends on
> check-target-libgomp-fortran which does:
> check-target-libgomp-fortran:
>         $(MAKE) RUNTESTFLAGS="$(RUNTESTFLAGS) fortran.exp" 
> check-target-libgomp
> and thus checks all fortran?
> 

I don't know what the problem is other than it appears to have arrived
with 

------------------------------------------------------------------------
r261717 | ebotcazou | 2018-06-18 15:01:58 -0700 (Mon, 18 Jun 2018) | 4 lines

        * Makefile.def (fortran): Add check-target-libgomp-fortran.
        * Makefile.tpl (check-target-libgomp-fortran): New phony target.
        * Makefile.in: Regenerate.

So, prior to this commit, exactly 5 tests were compiled, which takes
on the order of 3 seconds on this old hardware (see below).  Now, with
libgomp not respecting RUNTESTFLAGS (or not receiving RUNTESTFLAGS from
make in obj/), building all libgomp takes 15 minutes.

% time gmake check-fortran RUNTESTFLAGS="dg.exp=pr88249.f90"
     886.46 real       746.40 user       132.63 sys

> I have no idea what to change it to support what you want though, I'd suggest
> just do
> make -C gcc check-gfortran RUNTESTFLAGS="dg.exp=pr88269.f90" if you want to
> check something in the GCC testsuite, not use the toplevel check-fortran.

I have no idea how to fix the problem, but your suggested workaround
seems to work.

% time gmake -C gcc check-fortran RUNTESTFLAGS="dg.exp=pr88249.f90"
...
      === gfortran Summary ===

# of expected passes            5
/usr/home/kargl/gcc/obj/gcc/gfortran  version 9.0.0 20181202 \
(experimental) (GCC) 

gmake[1]: Leaving directory '/usr/home/kargl/gcc/obj/gcc'
gmake: Leaving directory '/usr/home/kargl/gcc/obj/gcc'
        2.56 real         1.72 user         0.76 sys

Reply via email to