Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
LEFEBVREJP email
radix
Commits
2f0e652e
Commit
2f0e652e
authored
Dec 06, 2018
by
LEFEBVREJP email
Browse files
Updating the size of the mergesort test to reduce overhead. Removed duplicate print.
parent
08a6ca0a
Pipeline
#20000
failed with stages
in 6 minutes and 30 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
radixalgorithm/tests/tstMergeSort.f90
View file @
2f0e652e
...
...
@@ -8,9 +8,11 @@
real
,
allocatable
::
indices
(:)
call
DATE_AND_TIME
(
d1
,
d2
,
d3
,
time
)
dtime1
=
time
(
6
)
*
60.
+
time
(
7
)
+
time
(
8
)/
1000.
n
=
1000
00000
n
=
1000
allocate
(
a
(
n
))
allocate
(
indices
(
n
))
! avoid unitialised value warning
indices
=
0
do
i
=
1
,
time
(
7
)
call
RANDOM_NUMBER
(
dtime2
)
end
do
...
...
@@ -28,8 +30,6 @@
print
"(10f12.3/10f12.0)"
,
(
a
(
i
),
i
=
1
,
10
),
(
indices
(
i
),
i
=
1
,
10
)
print
"(10f12.3/10f12.0)"
,
(
a
(
i
),
i
=
n
-9
,
n
),
(
indices
(
i
),
i
=
n
-9
,
n
)
call
merge_sort
(
n
,
a
,
indices
)
print
"(10f12.3/10f12.0)"
,
(
a
(
i
),
i
=
1
,
10
),
(
indices
(
i
),
i
=
1
,
10
)
print
"(10f12.3/10f12.0)"
,
(
a
(
i
),
i
=
n
-9
,
n
),
(
indices
(
i
),
i
=
n
-9
,
n
)
call
DATE_AND_TIME
(
d1
,
d2
,
d3
,
time
)
print
*
,
"First/Last 10 elements after sorting"
print
"(10f12.3/10f12.0)"
,
(
a
(
i
),
i
=
1
,
10
),
(
indices
(
i
),
i
=
1
,
10
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment