Spaces
Explore
Communities
Statistics
Reports
Cluster
Status
Help
Haskell 2019-04-01 06.52 pair #433317021
details
property
value
status
complete
benchmark
FiniteMap_intersectFM_C_6.hs
ran by
Akihisa Yamada
cpu timeout
1200 seconds
wallclock timeout
300 seconds
memory limit
137438953472 bytes
execution host
n115.star.cs.uiowa.edu
space
full_haskell
run statistics
property
value
solver
AProVE
configuration
standard
runtime (wallclock)
156.173 seconds
cpu usage
201.628
user time
197.688
system time
3.93939
max virtual memory
1.8285568E7
max residence set size
7033964.0
stage attributes
key
value
starexec-result
MAYBE
output
197.11/154.96 MAYBE 200.19/155.78 proof of /export/starexec/sandbox/benchmark/theBenchmark.hs 200.19/155.78 # AProVE Commit ID: 48fb2092695e11cc9f56e44b17a92a5f88ffb256 marcel 20180622 unpublished dirty 200.19/155.78 200.19/155.78 200.19/155.78 H-Termination with start terms of the given HASKELL could not be shown: 200.19/155.78 200.19/155.78 (0) HASKELL 200.19/155.78 (1) LR [EQUIVALENT, 0 ms] 200.19/155.78 (2) HASKELL 200.19/155.78 (3) CR [EQUIVALENT, 0 ms] 200.19/155.78 (4) HASKELL 200.19/155.78 (5) IFR [EQUIVALENT, 0 ms] 200.19/155.78 (6) HASKELL 200.19/155.78 (7) BR [EQUIVALENT, 0 ms] 200.19/155.78 (8) HASKELL 200.19/155.78 (9) COR [EQUIVALENT, 0 ms] 200.19/155.78 (10) HASKELL 200.19/155.78 (11) LetRed [EQUIVALENT, 0 ms] 200.19/155.78 (12) HASKELL 200.19/155.78 (13) NumRed [SOUND, 3 ms] 200.19/155.78 (14) HASKELL 200.19/155.78 200.19/155.78 200.19/155.78 ---------------------------------------- 200.19/155.78 200.19/155.78 (0) 200.19/155.78 Obligation: 200.19/155.78 mainModule Main 200.19/155.78 module FiniteMap where { 200.19/155.78 import qualified Main; 200.19/155.78 import qualified Maybe; 200.19/155.78 import qualified Prelude; 200.19/155.78 data FiniteMap a b = EmptyFM | Branch a b Int (FiniteMap a b) (FiniteMap a b) ; 200.19/155.78 200.19/155.78 instance (Eq a, Eq b) => Eq FiniteMap a b where { 200.19/155.78 (==) fm_1 fm_2 = sizeFM fm_1 == sizeFM fm_2 && fmToList fm_1 == fmToList fm_2; 200.19/155.78 } 200.19/155.78 addToFM :: Ord b => FiniteMap b a -> b -> a -> FiniteMap b a; 200.19/155.78 addToFM fm key elt = addToFM_C (\old new ->new) fm key elt; 200.19/155.78 200.19/155.78 addToFM_C :: Ord a => (b -> b -> b) -> FiniteMap a b -> a -> b -> FiniteMap a b; 200.19/155.78 addToFM_C combiner EmptyFM key elt = unitFM key elt; 200.19/155.78 addToFM_C combiner (Branch key elt size fm_l fm_r) new_key new_elt | new_key < key = mkBalBranch key elt (addToFM_C combiner fm_l new_key new_elt) fm_r 200.19/155.78 | new_key > key = mkBalBranch key elt fm_l (addToFM_C combiner fm_r new_key new_elt) 200.19/155.78 | otherwise = Branch new_key (combiner elt new_elt) size fm_l fm_r; 200.19/155.78 200.19/155.78 deleteMax :: Ord b => FiniteMap b a -> FiniteMap b a; 200.19/155.78 deleteMax (Branch key elt _ fm_l EmptyFM) = fm_l; 200.19/155.78 deleteMax (Branch key elt _ fm_l fm_r) = mkBalBranch key elt fm_l (deleteMax fm_r); 200.19/155.78 200.19/155.78 deleteMin :: Ord a => FiniteMap a b -> FiniteMap a b; 200.19/155.78 deleteMin (Branch key elt _ EmptyFM fm_r) = fm_r; 200.19/155.78 deleteMin (Branch key elt _ fm_l fm_r) = mkBalBranch key elt (deleteMin fm_l) fm_r; 200.19/155.78 200.19/155.78 emptyFM :: FiniteMap b a; 200.19/155.78 emptyFM = EmptyFM; 200.19/155.78 200.19/155.78 findMax :: FiniteMap a b -> (a,b); 200.19/155.78 findMax (Branch key elt _ _ EmptyFM) = (key,elt); 200.19/155.78 findMax (Branch key elt _ _ fm_r) = findMax fm_r; 200.19/155.78 200.19/155.78 findMin :: FiniteMap b a -> (b,a); 200.19/155.78 findMin (Branch key elt _ EmptyFM _) = (key,elt); 200.19/155.78 findMin (Branch key elt _ fm_l _) = findMin fm_l; 200.19/155.78 200.19/155.78 fmToList :: FiniteMap a b -> [(a,b)]; 200.19/155.78 fmToList fm = foldFM (\key elt rest ->(key,elt) : rest) [] fm; 200.19/155.78 200.19/155.78 foldFM :: (c -> b -> a -> a) -> a -> FiniteMap c b -> a; 200.19/155.78 foldFM k z EmptyFM = z; 200.19/155.78 foldFM k z (Branch key elt _ fm_l fm_r) = foldFM k (k key elt (foldFM k z fm_r)) fm_l; 200.19/155.78 200.19/155.78 glueBal :: Ord a => FiniteMap a b -> FiniteMap a b -> FiniteMap a b; 200.19/155.78 glueBal EmptyFM fm2 = fm2; 200.19/155.78 glueBal fm1 EmptyFM = fm1; 200.19/155.78 glueBal fm1 fm2 | sizeFM fm2 > sizeFM fm1 = mkBalBranch mid_key2 mid_elt2 fm1 (deleteMin fm2) 200.19/155.78 | otherwise = mkBalBranch mid_key1 mid_elt1 (deleteMax fm1) fm2 where { 200.19/155.78 mid_elt1 = (\(_,mid_elt1) ->mid_elt1) vv2; 200.19/155.78 mid_elt2 = (\(_,mid_elt2) ->mid_elt2) vv3; 200.19/155.78 mid_key1 = (\(mid_key1,_) ->mid_key1) vv2; 200.19/155.78 mid_key2 = (\(mid_key2,_) ->mid_key2) vv3; 200.19/155.78 vv2 = findMax fm1; 200.19/155.78 vv3 = findMin fm2; 200.19/155.78 }; 200.19/155.78 200.19/155.78 glueVBal :: Ord a => FiniteMap a b -> FiniteMap a b -> FiniteMap a b; 200.19/155.78 glueVBal EmptyFM fm2 = fm2; 200.19/155.78 glueVBal fm1 EmptyFM = fm1; 200.19/155.78 glueVBal fm_l@(Branch key_l elt_l _ fm_ll fm_lr) fm_r@(Branch key_r elt_r _ fm_rl fm_rr) | sIZE_RATIO * size_l < size_r = mkBalBranch key_r elt_r (glueVBal fm_l fm_rl) fm_rr 200.19/155.78 | sIZE_RATIO * size_r < size_l = mkBalBranch key_l elt_l fm_ll (glueVBal fm_lr fm_r) 200.19/155.78 | otherwise = glueBal fm_l fm_r where { 200.19/155.78 size_l = sizeFM fm_l; 200.19/155.78 size_r = sizeFM fm_r; 200.19/155.78 }; 200.19/155.78 200.19/155.78 intersectFM_C :: Ord b => (d -> c -> a) -> FiniteMap b d -> FiniteMap b c -> FiniteMap b a; 200.19/155.78 intersectFM_C combiner fm1 EmptyFM = emptyFM; 200.19/155.78 intersectFM_C combiner EmptyFM fm2 = emptyFM; 200.19/155.78 intersectFM_C combiner fm1 (Branch split_key elt2 _ left right) | Maybe.isJust maybe_elt1 = mkVBalBranch split_key (combiner elt1 elt2) (intersectFM_C combiner lts left) (intersectFM_C combiner gts right)
popout
output may be truncated. 'popout' for the full output.
job log
popout
actions
all output
return to Haskell 2019-04-01 06.52