2 ! { dg-options "-fdump-tree-original" }
5 ! MERGE was not properly compile-time simplified
7 ! Contributed by Bill Long
12 integer, parameter :: int32
= 4
17 integer,private
,parameter :: dik
= kind(0)
18 type(MPI_Datatype
),parameter,private
:: MPIx_I4
= MPI_Datatype( 1275069467)
19 type(MPI_Datatype
),parameter,private
:: MPIx_I8
= MPI_Datatype( 1275070491)
20 type(MPI_Datatype
),parameter :: MPI_INTEGER
= merge(MPIx_I4
, MPIx_I8
, &
25 check1
= MPI_INTEGER
%i
31 integer, parameter :: int32
= 4
36 integer,private
,parameter :: dik
= kind(0)
37 type(MPI_Datatype
),parameter,private
:: MPIx_I4
= MPI_Datatype( 1275069467)
38 type(MPI_Datatype
),parameter,private
:: MPIx_I8
= MPI_Datatype( 1275070491)
39 type(MPI_Datatype
),parameter :: MPI_INTEGER(1) = merge([MPIx_I4
], [MPIx_I8
], &
44 check2
= MPI_INTEGER(1)%i
== 1275069467
50 character(len
=3) :: one
, two
, three
51 logical, parameter :: true
= .true
.
52 three
= merge (one
, two
, true
)
55 ! { dg-final { scan-tree-dump-times "check1 = 1275069467;" 1 "original" } }
56 ! { dg-final { scan-tree-dump-times "check2 = 1;" 1 "original" } }
57 ! { dg-final { scan-tree-dump-times "__builtin_memmove ..void .. &three, .void .. &one, 3.;" 1 "original" } }
58 ! { dg-final { cleanup-tree-dump "original" } }