Commit d3c579c7 authored by Joachim Breitner's avatar Joachim Breitner

Call arity testcase for #3924

nice numbers coming from these micro-benchmarks.
parent f347bfea
TOP=../../..
include $(TOP)/mk/boilerplate.mk
include $(TOP)/mk/test.mk
f2 :: Int -> Int -> Int
f2 x1 = if x1 == 0 then (\x0 -> x0) else let
y = x1 - 1
in f3 y y
f3 :: Int -> Int -> Int -> Int
f3 x2 = if x2 == 0 then f2 else let
y = x2 - 1
in f4 y y
f4 :: Int -> Int -> Int -> Int -> Int
f4 x3 = if x3 == 0 then f3 else let
y = x3 - 1
in \x2 x1 x0 -> f4 y x2 x1 (y + x0)
main = print (f2 100 0)
test('T3924',
[stats_num_field('bytes allocated', (51480, 5)),
# previously, without call-arity: 22326544
# 2014-01-18: 51480 (amd64/Linux)
only_ways(['normal'])
],
compile_and_run,
['-O'])
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment