Skip to content

Instantly share code, notes, and snippets.

@davisp
Created March 21, 2022 18:42
Show Gist options
  • Save davisp/486ea8ace392a104aa9959008da42a4b to your computer and use it in GitHub Desktop.
Save davisp/486ea8ace392a104aa9959008da42a4b to your computer and use it in GitHub Desktop.
--- couch_key_tree.opt.S 2022-03-21 13:44:37.000000000 -0500
+++ couch_key_tree.no-opt.S 2022-03-21 13:44:58.000000000 -0500
@@ -26,7 +26,7 @@
{attributes, []}.
-{labels, 269}.
+{labels, 303}.
{function, multi_merge, 2, 2}.
@@ -37,8 +37,7 @@
{allocate,2,2}.
{move,{x,1},{y,0}}.
{move,{x,0},{y,1}}.
- {make_fun2,{f,268},0,0,0}.
- {'%',{var_info,{x,0},[{fun_type,{t_list,any,nil}}]}}.
+ {make_fun2,{f,301},0,0,0}.
{swap,{y,0},{x,0}}.
{line,[{location,"couch_key_tree.erl",51}]}.
{call_ext,1,{extfunc,lists,sort,1}}.
@@ -57,14 +56,9 @@
{allocate_zero,1,2}.
{move,nil,{x,2}}.
{line,[{location,"couch_key_tree.erl",58}]}.
- {call,3,{f,6}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 => {t_list,any,nil},
- 2 => {t_atom,[internal_node,new_branch,new_leaf]}}}}]}}.
+ {call,3,{f,7}}.
+ {test,is_tuple,{f,5},[{x,0}]}.
+ {test,test_arity,{f,5},[{x,0},2]}.
{get_tuple_element,{x,0},0,{x,1}}.
{get_tuple_element,{x,0},1,{y,0}}.
{move,{x,1},{x,0}}.
@@ -74,181 +68,155 @@
{put_tuple2,{x,0},{list,[{x,0},{y,0}]}}.
{deallocate,1}.
return.
+ {label,5}.
+ {line,[{location,"couch_key_tree.erl",58}]}.
+ {badmatch,{x,0}}.
-{function, merge_tree, 3, 6}.
- {label,5}.
+{function, merge_tree, 3, 7}.
+ {label,6}.
{line,[{location,"couch_key_tree.erl",67}]}.
{func_info,{atom,couch_key_tree},{atom,merge_tree},3}.
- {label,6}.
- {'%',{var_info,{x,2},[{type,{t_list,{t_tuple,2,true,#{}},nil}}]}}.
- {test,is_nonempty_list,{f,8},[{x,0}]}.
+ {label,7}.
+ {test,is_nonempty_list,{f,9},[{x,0}]}.
{get_list,{x,0},{x,3},{x,4}}.
- {test,is_tuple,{f,5},[{x,3}]}.
- {test,test_arity,{f,5},[{x,3},2]}.
- {test,is_tuple,{f,5},[{x,1}]}.
- {test,test_arity,{f,5},[{x,1},2]}.
- {get_tuple_element,{x,3},0,{x,0}}.
- {get_tuple_element,{x,1},0,{x,5}}.
+ {test,is_tuple,{f,6},[{x,3}]}.
+ {test,test_arity,{f,6},[{x,3},2]}.
+ {get_tuple_element,{x,3},0,{x,5}}.
+ {get_tuple_element,{x,3},1,{x,6}}.
+ {test,is_tuple,{f,6},[{x,1}]}.
+ {test,test_arity,{f,6},[{x,1},2]}.
+ {get_tuple_element,{x,1},0,{x,0}}.
+ {get_tuple_element,{x,1},1,{x,7}}.
{line,[{location,"couch_key_tree.erl",84}]}.
- {gc_bif,'-',{f,0},6,[{x,0},{x,5}],{x,6}}.
- {allocate_heap,7,4,7}.
- {init,{y,0}}.
+ {gc_bif,'-',{f,0},8,[{x,5},{x,0}],{x,8}}.
+ {allocate_heap,6,4,9}.
+ {move,{x,0},{y,0}}.
{move,{x,5},{y,1}}.
- {move,{x,0},{y,2}}.
- {move,{x,3},{y,3}}.
- {move,{x,4},{y,4}}.
- {move,{x,2},{y,5}}.
- {move,{x,1},{y,6}}.
- {get_tuple_element,{x,1},1,{x,0}}.
- {get_tuple_element,{x,3},1,{x,1}}.
- {put_list,{x,1},nil,{x,1}}.
- {put_list,{x,0},nil,{x,2}}.
- {move,{x,1},{x,0}}.
- {move,{x,6},{x,1}}.
+ {move,{x,3},{y,2}}.
+ {move,{x,4},{y,3}}.
+ {move,{x,2},{y,4}}.
+ {move,{x,1},{y,5}}.
+ {put_list,{x,6},nil,{x,0}}.
+ {put_list,{x,7},nil,{x,2}}.
+ {move,{x,8},{x,1}}.
{line,[{location,"couch_key_tree.erl",84}]}.
- {call,3,{f,12}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_union,
- {t_atom,[fail]},
- none,none,
- {t_tuple,2,true,
- #{1 => {t_cons,any,any},
- 2 => {t_atom,[internal_node,new_branch,new_leaf]}}},
- none}}]}}.
- {move,{x,0},{y,0}}.
- {test,is_tuple,{f,7},[{x,0}]}.
- {get_tuple_element,{x,0},0,{x,0}}.
- {get_list,{x,0},{y,6},{x,0}}.
- {test,is_nil,{f,10},[{x,0}]}.
- {move,{y,1},{x,1}}.
- {move,{y,2},{x,0}}.
- {move,{y,0},{y,3}}.
- {trim,3,4}.
+ {call,3,{f,13}}.
+ {test,is_tuple,{f,8},[{x,0}]}.
+ {test,test_arity,{f,11},[{x,0},2]}.
+ {get_tuple_element,{x,0},0,{x,1}}.
+ {get_tuple_element,{x,0},1,{y,5}}.
+ {test,is_nonempty_list,{f,11},[{x,1}]}.
+ {get_list,{x,1},{y,2},{x,1}}.
+ {test,is_nil,{f,11},[{x,1}]}.
+ {move,{y,0},{x,1}}.
+ {move,{y,1},{x,0}}.
+ {trim,2,4}.
{call_ext,2,{extfunc,erlang,min,2}}.
{test_heap,5,1}.
- {put_tuple2,{x,0},{list,[{x,0},{y,3}]}}.
+ {put_tuple2,{x,0},{list,[{x,0},{y,0}]}}.
{put_list,{x,0},{y,2},{x,1}}.
{move,{y,1},{x,0}}.
- {move,{y,0},{y,3}}.
{trim,3,1}.
{line,[{location,"couch_key_tree.erl",87}]}.
{call_ext,2,{extfunc,erlang,'++',2}}.
{test_heap,3,1}.
- {get_tuple_element,{y,0},1,{x,1}}.
- {put_tuple2,{x,0},{list,[{x,0},{x,1}]}}.
+ {put_tuple2,{x,0},{list,[{x,0},{y,0}]}}.
{deallocate,1}.
return.
- {label,7}.
- {test_heap,2,0}.
- {put_list,{y,3},{y,5},{x,2}}.
- {move,{y,6},{x,1}}.
- {move,{y,4},{x,0}}.
- {call_last,3,{f,6},7}.
{label,8}.
- {test,is_nil,{f,5},[{x,0}]}.
- {test,is_nil,{f,9},[{x,2}]}.
+ {test,is_eq_exact,{f,11},[{x,0},{atom,fail}]}.
+ {test_heap,2,0}.
+ {put_list,{y,2},{y,4},{x,2}}.
+ {move,{y,5},{x,1}}.
+ {move,{y,3},{x,0}}.
+ {call_last,3,{f,7},6}.
+ {label,9}.
+ {test,is_nil,{f,6},[{x,0}]}.
+ {test,is_nil,{f,10},[{x,2}]}.
{test_heap,5,2}.
{put_list,{x,1},nil,{x,0}}.
{put_tuple2,{x,0},{list,[{x,0},{atom,new_leaf}]}}.
return.
- {label,9}.
+ {label,10}.
{test_heap,5,3}.
{put_list,{x,1},{x,2},{x,0}}.
{put_tuple2,{x,0},{list,[{x,0},{atom,new_branch}]}}.
return.
- {label,10}.
+ {label,11}.
{line,[{location,"couch_key_tree.erl",84}]}.
- {case_end,{y,0}}.
+ {case_end,{x,0}}.
-{function, merge_at, 3, 12}.
- {label,11}.
+{function, merge_at, 3, 13}.
+ {label,12}.
{line,[{location,"couch_key_tree.erl",100}]}.
{func_info,{atom,couch_key_tree},{atom,merge_at},3}.
- {label,12}.
- {'%',{var_info,{x,1},[{type,number}]}}.
- {'%',{var_info,{x,2},[{type,{t_cons,any,any}}]}}.
- {test,is_ne_exact,{f,19},[{x,0},nil]}.
+ {label,13}.
+ {test,is_ne_exact,{f,21},[{x,2},nil]}.
+ {test,is_ne_exact,{f,21},[{x,0},nil]}.
+ {test,is_nonempty_list,{f,16},[{x,2}]}.
{get_list,{x,2},{x,3},{x,4}}.
- {test,is_tuple,{f,14},[{x,3}]}.
- {test,test_arity,{f,14},[{x,3},3]}.
- {get_tuple_element,{x,3},2,{x,5}}.
- {test,is_nonempty_list,{f,13},[{x,5}]}.
- {get_tl,{x,5},{x,6}}.
- {test,is_nil,{f,14},[{x,6}]}.
- {test,is_nil,{f,14},[{x,4}]}.
- {test,is_lt,{f,14},[{integer,0},{x,1}]}.
+ {test,is_tuple,{f,16},[{x,3}]}.
+ {test,test_arity,{f,16},[{x,3},3]}.
+ {get_tuple_element,{x,3},0,{x,5}}.
+ {get_tuple_element,{x,3},1,{x,6}}.
+ {get_tuple_element,{x,3},2,{x,3}}.
+ {test,is_nonempty_list,{f,15},[{x,3}]}.
+ {get_list,{x,3},{x,7},{x,7}}.
+ {test,is_nil,{f,16},[{x,7}]}.
+ {test,is_nil,{f,16},[{x,4}]}.
+ {test,is_lt,{f,16},[{integer,0},{x,1}]}.
{line,[{location,"couch_key_tree.erl",107}]}.
- {gc_bif,'-',{f,0},6,[{x,1},{integer,1}],{x,1}}.
- {allocate,1,6}.
- {move,{x,3},{y,0}}.
- {move,{x,5},{x,2}}.
+ {gc_bif,'-',{f,0},7,[{x,1},{integer,1}],{x,1}}.
+ {allocate,2,7}.
+ {move,{x,5},{y,0}}.
+ {move,{x,6},{y,1}}.
+ {move,{x,3},{x,2}}.
{line,[{location,"couch_key_tree.erl",107}]}.
- {call,3,{f,12}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_union,
- {t_atom,[fail]},
- none,none,
- {t_tuple,2,true,
- #{1 => {t_cons,any,any},
- 2 => {t_atom,[internal_node,new_branch,new_leaf]}}},
- none}}]}}.
- {test,is_tuple,{f,21},[{x,0}]}.
+ {call,3,{f,13}}.
+ {test,is_tuple,{f,14},[{x,0}]}.
+ {test,test_arity,{f,24},[{x,0},2]}.
{test_heap,9,1}.
- {get_tuple_element,{y,0},0,{x,1}}.
- {get_tuple_element,{y,0},1,{x,2}}.
- {get_tuple_element,{x,0},0,{x,3}}.
+ {get_tuple_element,{x,0},0,{x,1}}.
{get_tuple_element,{x,0},1,{x,0}}.
- {put_tuple2,{x,1},{list,[{x,1},{x,2},{x,3}]}}.
+ {put_tuple2,{x,1},{list,[{y,0},{y,1},{x,1}]}}.
{put_list,{x,1},nil,{x,1}}.
{put_tuple2,{x,0},{list,[{x,1},{x,0}]}}.
- {deallocate,1}.
+ {deallocate,2}.
return.
- {label,13}.
- {test,is_nil,{f,14},[{x,5}]}.
- {test,is_nil,{f,14},[{x,4}]}.
- {test,is_ge,{f,19},[{integer,0},{x,1}]}.
{label,14}.
- {test,is_nonempty_list,{f,11},[{x,0}]}.
- {get_list,{x,0},{x,5},{x,6}}.
- {test,is_tuple,{f,20},[{x,5}]}.
- {test,test_arity,{f,20},[{x,5},3]}.
- {get_tuple_element,{x,5},0,{x,7}}.
- {get_tuple_element,{x,5},1,{x,8}}.
- {get_tuple_element,{x,5},2,{x,9}}.
- {test,is_lt,{f,17},[{x,1},{integer,0}]}.
+ {test,is_eq_exact,{f,24},[{x,0},{atom,fail}]}.
+ {deallocate,2}.
+ return.
+ {label,15}.
+ {test,is_nil,{f,16},[{x,3}]}.
+ {test,is_nil,{f,16},[{x,4}]}.
+ {test,is_ge,{f,21},[{integer,0},{x,1}]}.
+ {label,16}.
+ {test,is_nonempty_list,{f,12},[{x,0}]}.
+ {get_list,{x,0},{x,3},{x,4}}.
+ {test,is_tuple,{f,22},[{x,3}]}.
+ {test,test_arity,{f,22},[{x,3},3]}.
+ {get_tuple_element,{x,3},0,{x,5}}.
+ {get_tuple_element,{x,3},1,{x,6}}.
+ {get_tuple_element,{x,3},2,{x,7}}.
+ {test,is_lt,{f,19},[{x,1},{integer,0}]}.
{line,[{location,"couch_key_tree.erl",118}]}.
- {gc_bif,'+',{f,0},10,[{x,1},{integer,1}],{x,0}}.
- {allocate,6,10}.
- {move,{x,7},{y,0}}.
- {move,{x,8},{y,1}}.
- {move,{x,5},{y,2}}.
- {move,{x,6},{y,3}}.
+ {gc_bif,'+',{f,0},8,[{x,1},{integer,1}],{x,0}}.
+ {allocate,6,8}.
+ {move,{x,5},{y,0}}.
+ {move,{x,6},{y,1}}.
+ {move,{x,3},{y,2}}.
+ {move,{x,4},{y,3}}.
{move,{x,2},{y,4}}.
{move,{x,1},{y,5}}.
{move,{x,0},{x,1}}.
- {move,{x,9},{x,0}}.
+ {move,{x,7},{x,0}}.
{line,[{location,"couch_key_tree.erl",118}]}.
- {call,3,{f,12}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_union,
- {t_atom,[fail]},
- none,none,
- {t_tuple,2,true,
- #{1 => {t_cons,any,any},
- 2 => {t_atom,[internal_node,new_branch,new_leaf]}}},
- none}}]}}.
- {test,is_tuple,{f,15},[{x,0}]}.
+ {call,3,{f,13}}.
+ {test,is_tuple,{f,17},[{x,0}]}.
+ {test,test_arity,{f,26},[{x,0},2]}.
{test_heap,9,1}.
{get_tuple_element,{x,0},0,{x,1}}.
{get_tuple_element,{x,0},1,{x,0}}.
@@ -257,7 +225,8 @@
{put_tuple2,{x,0},{list,[{x,1},{x,0}]}}.
{deallocate,6}.
return.
- {label,15}.
+ {label,17}.
+ {test,is_eq_exact,{f,26},[{x,0},{atom,fail}]}.
{move,{y,4},{x,2}}.
{move,{y,5},{x,1}}.
{move,{y,3},{x,0}}.
@@ -267,19 +236,9 @@
{kill,{y,4}}.
{kill,{y,5}}.
{line,[{location,"couch_key_tree.erl",125}]}.
- {call,3,{f,12}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_union,
- {t_atom,[fail]},
- none,none,
- {t_tuple,2,true,
- #{1 => {t_cons,any,any},
- 2 => {t_atom,[internal_node,new_branch,new_leaf]}}},
- none}}]}}.
- {test,is_tuple,{f,16},[{x,0}]}.
+ {call,3,{f,13}}.
+ {test,is_tuple,{f,18},[{x,0}]}.
+ {test,test_arity,{f,25},[{x,0},2]}.
{test_heap,5,1}.
{get_tuple_element,{x,0},0,{x,1}}.
{get_tuple_element,{x,0},1,{x,0}}.
@@ -287,72 +246,64 @@
{put_tuple2,{x,0},{list,[{x,1},{x,0}]}}.
{deallocate,6}.
return.
- {label,16}.
- {move,{atom,fail},{x,0}}.
+ {label,18}.
+ {test,is_eq_exact,{f,25},[{x,0},{atom,fail}]}.
{deallocate,6}.
return.
- {label,17}.
- {test,is_eq_exact,{f,11},[{x,1},{integer,0}]}.
- {test,is_tuple,{f,20},[{x,3}]}.
- {test,test_arity,{f,20},[{x,3},3]}.
- {test,is_nil,{f,20},[{x,4}]}.
- {get_tuple_element,{x,3},0,{x,4}}.
- {test,is_eq_exact,{f,18},[{x,4},{x,7}]}.
- {allocate,4,10}.
- {move,{x,3},{y,0}}.
- {move,{x,7},{y,1}}.
- {move,{x,8},{y,2}}.
- {move,{x,6},{y,3}}.
- {get_tuple_element,{x,3},2,{x,1}}.
- {move,{x,9},{x,0}}.
+ {label,19}.
+ {test,is_eq_exact,{f,22},[{x,1},{integer,0}]}.
+ {test,is_nonempty_list,{f,22},[{x,2}]}.
+ {get_list,{x,2},{x,8},{x,9}}.
+ {test,is_tuple,{f,22},[{x,8}]}.
+ {test,test_arity,{f,22},[{x,8},3]}.
+ {get_tuple_element,{x,8},0,{x,10}}.
+ {get_tuple_element,{x,8},1,{x,11}}.
+ {get_tuple_element,{x,8},2,{x,8}}.
+ {test,is_nil,{f,22},[{x,9}]}.
+ {test,is_eq_exact,{f,20},[{x,10},{x,5}]}.
+ {allocate,6,12}.
+ {init,{y,0}}.
+ {init,{y,1}}.
+ {move,{x,11},{y,2}}.
+ {move,{x,5},{y,3}}.
+ {move,{x,6},{y,4}}.
+ {move,{x,4},{y,5}}.
+ {move,{x,8},{x,1}}.
+ {move,{x,7},{x,0}}.
{line,[{location,"couch_key_tree.erl",133}]}.
- {call,2,{f,23}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{2 => {t_atom,[internal_node,new_branch,new_leaf]}}}}]}}.
- {get_tuple_element,{y,0},1,{x,1}}.
- {move,{y,2},{x,2}}.
- {move,{x,0},{y,2}}.
- {trim,1,3}.
- {move,{x,2},{x,0}}.
+ {call,2,{f,30}}.
+ {test,is_tuple,{f,27},[{x,0}]}.
+ {test,test_arity,{f,27},[{x,0},2]}.
+ {get_tuple_element,{x,0},0,{y,1}}.
+ {get_tuple_element,{x,0},1,{y,0}}.
+ {move,{y,2},{x,1}}.
+ {move,{y,4},{x,0}}.
+ {kill,{y,2}}.
+ {move,{y,0},{y,4}}.
+ {trim,1,5}.
{line,[{location,"couch_key_tree.erl",134}]}.
- {call,2,{f,162}}.
+ {call,2,{f,186}}.
{test_heap,9,1}.
- {get_tuple_element,{y,1},0,{x,1}}.
- {get_tuple_element,{y,1},1,{x,2}}.
- {put_tuple2,{x,0},{list,[{y,0},{x,0},{x,1}]}}.
- {put_list,{x,0},{y,2},{x,0}}.
- {put_tuple2,{x,0},{list,[{x,0},{x,2}]}}.
- {deallocate,3}.
+ {put_tuple2,{x,0},{list,[{y,2},{x,0},{y,0}]}}.
+ {put_list,{x,0},{y,4},{x,0}}.
+ {put_tuple2,{x,0},{list,[{x,0},{y,3}]}}.
+ {deallocate,5}.
return.
- {label,18}.
- {test,is_lt,{f,20},[{x,4},{x,7}]}.
- {label,19}.
+ {label,20}.
+ {test,is_lt,{f,22},[{x,10},{x,5}]}.
+ {label,21}.
{move,{atom,fail},{x,0}}.
return.
- {label,20}.
- {test,is_eq_exact,{f,11},[{x,1},{integer,0}]}.
- {allocate,1,7}.
- {move,{x,5},{y,0}}.
+ {label,22}.
+ {test,is_eq_exact,{f,12},[{x,1},{integer,0}]}.
+ {allocate,1,5}.
+ {move,{x,3},{y,0}}.
{move,{integer,0},{x,1}}.
- {move,{x,6},{x,0}}.
+ {move,{x,4},{x,0}}.
{line,[{location,"couch_key_tree.erl",140}]}.
- {call,3,{f,12}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_union,
- {t_atom,[fail]},
- none,none,
- {t_tuple,2,true,
- #{1 => {t_cons,any,any},
- 2 => {t_atom,[internal_node,new_branch,new_leaf]}}},
- none}}]}}.
- {test,is_tuple,{f,21},[{x,0}]}.
+ {call,3,{f,13}}.
+ {test,is_tuple,{f,23},[{x,0}]}.
+ {test,test_arity,{f,28},[{x,0},2]}.
{test_heap,5,1}.
{get_tuple_element,{x,0},0,{x,1}}.
{get_tuple_element,{x,0},1,{x,0}}.
@@ -360,144 +311,155 @@
{put_tuple2,{x,0},{list,[{x,1},{x,0}]}}.
{deallocate,1}.
return.
- {label,21}.
- {move,{atom,fail},{x,0}}.
+ {label,23}.
+ {test,is_eq_exact,{f,28},[{x,0},{atom,fail}]}.
{deallocate,1}.
return.
+ {label,24}.
+ {line,[{location,"couch_key_tree.erl",107}]}.
+ {case_end,{x,0}}.
+ {label,25}.
+ {line,[{location,"couch_key_tree.erl",125}]}.
+ {case_end,{x,0}}.
+ {label,26}.
+ {line,[{location,"couch_key_tree.erl",118}]}.
+ {case_end,{x,0}}.
+ {label,27}.
+ {line,[{location,"couch_key_tree.erl",133}]}.
+ {badmatch,{x,0}}.
+ {label,28}.
+ {line,[{location,"couch_key_tree.erl",140}]}.
+ {case_end,{x,0}}.
-{function, merge_extend, 2, 23}.
- {label,22}.
+{function, merge_extend, 2, 30}.
+ {label,29}.
{line,[{location,"couch_key_tree.erl",147}]}.
{func_info,{atom,couch_key_tree},{atom,merge_extend},2}.
- {label,23}.
- {test,is_nil,{f,24},[{x,0}]}.
- {test,is_ne_exact,{f,25},[{x,1},nil]}.
+ {label,30}.
+ {test,is_nil,{f,31},[{x,0}]}.
+ {test,is_ne_exact,{f,31},[{x,1},nil]}.
{test_heap,3,2}.
{put_tuple2,{x,0},{list,[{x,1},{atom,new_leaf}]}}.
return.
- {label,24}.
- {test,is_nil,{f,26},[{x,1}]}.
- {label,25}.
+ {label,31}.
+ {test,is_nil,{f,32},[{x,1}]}.
{test_heap,3,1}.
{put_tuple2,{x,0},{list,[{x,0},{atom,internal_node}]}}.
return.
- {label,26}.
- {test,is_nonempty_list,{f,22},[{x,0}]}.
+ {label,32}.
+ {test,is_nonempty_list,{f,29},[{x,0}]}.
{get_list,{x,0},{x,2},{x,3}}.
- {test,is_tuple,{f,28},[{x,2}]}.
- {test,test_arity,{f,28},[{x,2},3]}.
- {test,is_nonempty_list,{f,28},[{x,1}]}.
- {get_list,{x,1},{x,4},{x,5}}.
- {test,is_tuple,{f,28},[{x,4}]}.
- {test,test_arity,{f,28},[{x,4},3]}.
- {get_tuple_element,{x,4},1,{x,6}}.
- {test,is_nil,{f,28},[{x,5}]}.
- {get_tuple_element,{x,4},0,{x,5}}.
- {get_tuple_element,{x,2},0,{x,7}}.
- {test,is_eq_exact,{f,27},[{x,5},{x,7}]}.
- {allocate,4,8}.
- {move,{x,6},{y,0}}.
- {move,{x,7},{y,1}}.
- {move,{x,2},{y,2}}.
- {move,{x,3},{y,3}}.
- {get_tuple_element,{x,4},2,{x,1}}.
- {get_tuple_element,{x,2},2,{x,0}}.
+ {test,is_tuple,{f,34},[{x,2}]}.
+ {test,test_arity,{f,34},[{x,2},3]}.
+ {get_tuple_element,{x,2},0,{x,4}}.
+ {get_tuple_element,{x,2},1,{x,5}}.
+ {get_tuple_element,{x,2},2,{x,6}}.
+ {test,is_nonempty_list,{f,34},[{x,1}]}.
+ {get_list,{x,1},{x,7},{x,8}}.
+ {test,is_tuple,{f,34},[{x,7}]}.
+ {test,test_arity,{f,34},[{x,7},3]}.
+ {get_tuple_element,{x,7},0,{x,9}}.
+ {get_tuple_element,{x,7},1,{x,10}}.
+ {get_tuple_element,{x,7},2,{x,11}}.
+ {test,is_nil,{f,34},[{x,8}]}.
+ {test,is_eq_exact,{f,33},[{x,9},{x,4}]}.
+ {allocate,6,12}.
+ {init,{y,0}}.
+ {init,{y,1}}.
+ {move,{x,10},{y,2}}.
+ {move,{x,4},{y,3}}.
+ {move,{x,5},{y,4}}.
+ {move,{x,3},{y,5}}.
+ {move,{x,11},{x,1}}.
+ {move,{x,6},{x,0}}.
{line,[{location,"couch_key_tree.erl",161}]}.
- {call,2,{f,23}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{2 => {t_atom,[internal_node,new_branch,new_leaf]}}}}]}}.
- {get_tuple_element,{y,2},1,{x,1}}.
- {move,{x,0},{y,2}}.
- {move,{y,0},{x,2}}.
- {move,{x,1},{x,0}}.
- {move,{x,2},{x,1}}.
- {trim,1,3}.
+ {call,2,{f,30}}.
+ {test,is_tuple,{f,36},[{x,0}]}.
+ {test,test_arity,{f,36},[{x,0},2]}.
+ {get_tuple_element,{x,0},0,{y,1}}.
+ {get_tuple_element,{x,0},1,{y,0}}.
+ {move,{y,2},{x,1}}.
+ {move,{y,4},{x,0}}.
+ {kill,{y,2}}.
+ {move,{y,0},{y,4}}.
+ {trim,1,5}.
{line,[{location,"couch_key_tree.erl",162}]}.
- {call,2,{f,162}}.
+ {call,2,{f,186}}.
{test_heap,9,1}.
- {get_tuple_element,{y,1},0,{x,1}}.
- {get_tuple_element,{y,1},1,{x,2}}.
- {put_tuple2,{x,0},{list,[{y,0},{x,0},{x,1}]}}.
- {put_list,{x,0},{y,2},{x,0}}.
- {put_tuple2,{x,0},{list,[{x,0},{x,2}]}}.
- {deallocate,3}.
+ {put_tuple2,{x,0},{list,[{y,2},{x,0},{y,0}]}}.
+ {put_list,{x,0},{y,4},{x,0}}.
+ {put_tuple2,{x,0},{list,[{x,0},{y,3}]}}.
+ {deallocate,5}.
return.
- {label,27}.
- {test,is_lt,{f,28},[{x,5},{x,7}]}.
- {test_heap,5,5}.
- {put_list,{x,4},{x,0},{x,0}}.
+ {label,33}.
+ {test,is_lt,{f,34},[{x,9},{x,4}]}.
+ {test_heap,5,8}.
+ {put_list,{x,7},{x,0},{x,0}}.
{put_tuple2,{x,0},{list,[{x,0},{atom,new_branch}]}}.
return.
- {label,28}.
+ {label,34}.
{allocate,2,4}.
{move,{x,2},{y,0}}.
{move,{x,3},{y,1}}.
{move,{x,3},{x,0}}.
{line,[{location,"couch_key_tree.erl",173}]}.
- {call,2,{f,23}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{2 => {t_atom,[internal_node,new_branch,new_leaf]}}}}]}}.
+ {call,2,{f,30}}.
+ {test,is_tuple,{f,37},[{x,0}]}.
+ {test,test_arity,{f,37},[{x,0},2]}.
{get_tuple_element,{x,0},0,{x,1}}.
+ {get_tuple_element,{x,0},1,{x,0}}.
{line,[{location,"couch_key_tree.erl",175}]}.
{gc_bif,length,{f,0},2,[{x,1}],{x,2}}.
{line,[{location,"couch_key_tree.erl",175}]}.
{gc_bif,length,{f,0},3,[{y,1}],{x,3}}.
- {test,is_eq_exact,{f,29},[{x,2},{x,3}]}.
+ {test,is_ne,{f,35},[{x,2},{x,3}]}.
+ {move,{atom,new_branch},{x,0}}.
+ {label,35}.
{test_heap,5,2}.
- {get_tuple_element,{x,0},1,{x,0}}.
{put_list,{y,0},{x,1},{x,1}}.
{put_tuple2,{x,0},{list,[{x,1},{x,0}]}}.
{deallocate,2}.
return.
- {label,29}.
- {test_heap,5,2}.
- {put_list,{y,0},{x,1},{x,0}}.
- {put_tuple2,{x,0},{list,[{x,0},{atom,new_branch}]}}.
- {deallocate,2}.
- return.
+ {label,36}.
+ {line,[{location,"couch_key_tree.erl",161}]}.
+ {badmatch,{x,0}}.
+ {label,37}.
+ {line,[{location,"couch_key_tree.erl",173}]}.
+ {badmatch,{x,0}}.
-{function, find_missing, 2, 31}.
- {label,30}.
+{function, find_missing, 2, 39}.
+ {label,38}.
{line,[{location,"couch_key_tree.erl",181}]}.
{func_info,{atom,couch_key_tree},{atom,find_missing},2}.
- {label,31}.
- {test,is_nil,{f,32},[{x,1}]}.
+ {label,39}.
+ {test,is_nil,{f,40},[{x,1}]}.
{move,nil,{x,0}}.
return.
- {label,32}.
- {test,is_nonempty_list,{f,33},[{x,0}]}.
+ {label,40}.
+ {test,is_nonempty_list,{f,41},[{x,0}]}.
{get_list,{x,0},{x,2},{x,3}}.
- {test,is_tuple,{f,30},[{x,2}]}.
- {test,test_arity,{f,30},[{x,2},2]}.
- {get_tuple_element,{x,2},1,{x,4}}.
- {test,is_tuple,{f,30},[{x,4}]}.
- {test,test_arity,{f,30},[{x,4},3]}.
+ {test,is_tuple,{f,38},[{x,2}]}.
+ {test,test_arity,{f,38},[{x,2},2]}.
+ {get_tuple_element,{x,2},0,{x,4}}.
+ {get_tuple_element,{x,2},1,{x,2}}.
+ {test,is_tuple,{f,38},[{x,2}]}.
+ {test,test_arity,{f,38},[{x,2},3]}.
{allocate,4,5}.
- {move,{x,4},{y,1}}.
+ {move,{x,4},{y,0}}.
+ {move,{x,2},{y,1}}.
{move,{x,3},{y,2}}.
{move,{x,1},{y,3}}.
- {get_tuple_element,{x,2},0,{y,0}}.
{move,{x,1},{x,0}}.
- {move,{y,0},{x,1}}.
+ {move,{x,4},{x,1}}.
{line,[{location,"couch_key_tree.erl",186}]}.
- {call,2,{f,263}}.
- {'%',{var_info,{x,0},[{type,{t_list,{t_tuple,2,true,#{}},nil}}]}}.
+ {call,2,{f,296}}.
{move,{y,0},{x,2}}.
{swap,{y,3},{x,0}}.
{move,{x,2},{x,1}}.
{line,[{location,"couch_key_tree.erl",187}]}.
- {call,2,{f,258}}.
- {'%',{var_info,{x,0},[{type,{t_list,{t_tuple,2,true,#{}},nil}}]}}.
+ {call,2,{f,291}}.
{test_heap,2,1}.
{put_list,{y,1},nil,{x,1}}.
{move,{y,3},{x,3}}.
@@ -506,8 +468,7 @@
{move,{x,3},{x,2}}.
{trim,2,2}.
{line,[{location,"couch_key_tree.erl",188}]}.
- {call,3,{f,35}}.
- {'%',{var_info,{x,0},[{type,{t_list,{t_tuple,2,true,#{}},nil}}]}}.
+ {call,3,{f,43}}.
{move,{x,0},{x,1}}.
{move,{y,1},{x,0}}.
{kill,{y,1}}.
@@ -515,47 +476,43 @@
{call_ext,2,{extfunc,erlang,'++',2}}.
{move,{x,0},{x,1}}.
{move,{y,0},{x,0}}.
- {call_last,2,{f,31},2}.
- {label,33}.
- {test,is_nil,{f,30},[{x,0}]}.
+ {call_last,2,{f,39},2}.
+ {label,41}.
+ {test,is_nil,{f,38},[{x,0}]}.
{move,{x,1},{x,0}}.
return.
-{function, find_missing_simple, 3, 35}.
- {label,34}.
+{function, find_missing_simple, 3, 43}.
+ {label,42}.
{line,[{location,"couch_key_tree.erl",191}]}.
{func_info,{atom,couch_key_tree},{atom,find_missing_simple},3}.
- {label,35}.
- {'%',{var_info,{x,2},[{type,{t_list,{t_tuple,2,true,#{}},nil}}]}}.
- {test,is_nil,{f,36},[{x,2}]}.
+ {label,43}.
+ {test,is_nil,{f,44},[{x,2}]}.
{move,nil,{x,0}}.
return.
- {label,36}.
- {test,is_nonempty_list,{f,37},[{x,1}]}.
+ {label,44}.
+ {test,is_nonempty_list,{f,45},[{x,1}]}.
{get_list,{x,1},{x,3},{x,4}}.
- {test,is_tuple,{f,34},[{x,3}]}.
- {test,test_arity,{f,34},[{x,3},3]}.
+ {test,is_tuple,{f,42},[{x,3}]}.
+ {test,test_arity,{f,42},[{x,3},3]}.
{allocate,5,5}.
- {move,{x,3},{y,1}}.
{move,{x,4},{y,2}}.
{move,{x,2},{y,3}}.
{move,{x,0},{y,4}}.
+ {get_tuple_element,{x,3},0,{y,1}}.
{get_tuple_element,{x,3},2,{y,0}}.
{move,{x,0},{x,1}}.
{move,{x,2},{x,0}}.
{line,[{location,"couch_key_tree.erl",196}]}.
- {call,2,{f,254}}.
- {'%',{var_info,{x,0},[{type,{t_list,{t_tuple,2,true,#{}},nil}}]}}.
+ {call,2,{f,286}}.
{move,{y,4},{x,2}}.
{swap,{y,3},{x,0}}.
{move,{x,2},{x,1}}.
{line,[{location,"couch_key_tree.erl",197}]}.
- {call,2,{f,250}}.
- {'%',{var_info,{x,0},[{type,{t_list,{t_tuple,2,true,#{}},nil}}]}}.
+ {call,2,{f,281}}.
{test_heap,5,1}.
- {get_tuple_element,{y,1},0,{x,1}}.
- {put_tuple2,{x,1},{list,[{y,4},{x,1}]}}.
+ {put_tuple2,{x,1},{list,[{y,4},{y,1}]}}.
{put_list,{x,1},nil,{x,1}}.
{move,{y,3},{x,2}}.
{move,{x,0},{y,3}}.
@@ -570,135 +527,98 @@
{move,{y,0},{x,1}}.
{trim,2,3}.
{line,[{location,"couch_key_tree.erl",200}]}.
- {call,3,{f,35}}.
- {'%',{var_info,{x,0},[{type,{t_list,{t_tuple,2,true,#{}},nil}}]}}.
+ {call,3,{f,43}}.
{move,{y,0},{x,1}}.
{move,{x,0},{x,2}}.
{move,{y,2},{x,0}}.
{move,{y,1},{y,2}}.
{trim,2,1}.
{line,[{location,"couch_key_tree.erl",201}]}.
- {call,3,{f,35}}.
- {'%',{var_info,{x,0},[{type,{t_list,{t_tuple,2,true,#{}},nil}}]}}.
+ {call,3,{f,43}}.
{move,{x,0},{x,1}}.
{move,{y,0},{x,0}}.
{line,[{location,"couch_key_tree.erl",201}]}.
{call_ext_last,2,{extfunc,erlang,'++',2},1}.
- {label,37}.
- {test,is_nil,{f,34},[{x,1}]}.
+ {label,45}.
+ {test,is_nil,{f,42},[{x,1}]}.
{move,{x,2},{x,0}}.
return.
-{function, filter_leafs, 4, 39}.
- {label,38}.
+{function, filter_leafs, 4, 47}.
+ {label,46}.
{line,[{location,"couch_key_tree.erl",203}]}.
{func_info,{atom,couch_key_tree},{atom,filter_leafs},4}.
- {label,39}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_cons,{t_tuple,2,true,#{}},nil}}},
- nil}}]}}.
- {'%',
- {var_info,
- {x,2},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_cons,{t_tuple,2,true,#{}},nil}}},
- nil}}]}}.
- {'%',{var_info,{x,3},[{type,{t_list,{t_tuple,2,true,#{}},nil}}]}}.
- {test,is_nonempty_list,{f,41},[{x,0}]}.
- {allocate_heap,7,3,4}.
+ {label,47}.
+ {test,is_nonempty_list,{f,49},[{x,0}]}.
+ {get_list,{x,0},{x,4},{x,5}}.
+ {test,is_tuple,{f,46},[{x,4}]}.
+ {test,test_arity,{f,46},[{x,4},2]}.
+ {get_tuple_element,{x,4},0,{x,6}}.
+ {get_tuple_element,{x,4},1,{x,7}}.
+ {test,is_nonempty_list,{f,46},[{x,7}]}.
+ {get_list,{x,7},{x,8},{x,7}}.
+ {test,is_tuple,{f,46},[{x,8}]}.
+ {test,test_arity,{f,46},[{x,8},2]}.
+ {allocate_heap,7,3,9}.
+ {move,{x,6},{y,1}}.
+ {move,{x,4},{y,2}}.
+ {move,{x,5},{y,3}}.
{move,{x,3},{y,4}}.
{move,{x,2},{y,5}}.
{move,{x,1},{y,6}}.
- {get_list,{x,0},{y,3},{y,2}}.
- {get_tuple_element,{y,3},1,{x,0}}.
- {get_hd,{x,0},{x,0}}.
- {get_tuple_element,{y,3},0,{y,1}}.
- {get_tuple_element,{x,0},0,{y,0}}.
- {put_tuple2,{x,0},{list,[{y,1},{y,0}]}}.
+ {get_tuple_element,{x,8},0,{y,0}}.
+ {put_tuple2,{x,0},{list,[{x,6},{y,0}]}}.
{line,[{location,"couch_key_tree.erl",206}]}.
{call_ext,2,{extfunc,lists,delete,2}}.
- {test,is_eq,{f,40},[{x,0},{y,6}]}.
+ {test,is_eq,{f,48},[{x,0},{y,6}]}.
{test_heap,2,0}.
- {put_list,{y,3},{y,5},{x,2}}.
+ {put_list,{y,2},{y,5},{x,2}}.
{move,{y,4},{x,3}}.
{move,{y,6},{x,1}}.
- {move,{y,2},{x,0}}.
- {call_last,4,{f,39},7}.
- {label,40}.
+ {move,{y,3},{x,0}}.
+ {call_last,4,{f,47},7}.
+ {label,48}.
{test_heap,5,1}.
{put_tuple2,{x,1},{list,[{y,1},{y,0}]}}.
{put_list,{x,1},{y,4},{x,3}}.
{move,{x,0},{x,1}}.
{move,{y,5},{x,2}}.
- {move,{y,2},{x,0}}.
- {call_last,4,{f,39},7}.
- {label,41}.
+ {move,{y,3},{x,0}}.
+ {call_last,4,{f,47},7}.
+ {label,49}.
+ {test,is_nil,{f,46},[{x,0}]}.
{test_heap,3,4}.
{put_tuple2,{x,0},{list,[{x,2},{x,3}]}}.
return.
-{function, remove_leafs, 2, 43}.
- {label,42}.
+{function, remove_leafs, 2, 51}.
+ {label,50}.
{line,[{location,"couch_key_tree.erl",217}]}.
{func_info,{atom,couch_key_tree},{atom,remove_leafs},2}.
- {label,43}.
+ {label,51}.
{allocate_zero,2,2}.
{move,{x,1},{y,1}}.
{line,[{location,"couch_key_tree.erl",219}]}.
- {call,1,{f,74}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_cons,{t_tuple,2,true,#{}},nil}}},
- nil}}]}}.
+ {call,1,{f,95}}.
{move,nil,{x,2}}.
{move,nil,{x,3}}.
{move,{y,1},{x,1}}.
{kill,{y,1}}.
{line,[{location,"couch_key_tree.erl",222}]}.
- {call,4,{f,39}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 =>
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_cons,{t_tuple,0,false,#{}},nil}}},
- nil},
- 2 => {t_list,{t_tuple,2,true,#{}},nil}}}}]}}.
+ {call,4,{f,47}}.
+ {test,is_tuple,{f,52},[{x,0}]}.
+ {test,test_arity,{f,52},[{x,0},2]}.
{get_tuple_element,{x,0},0,{x,1}}.
{get_tuple_element,{x,0},1,{y,1}}.
{move,{x,1},{x,0}}.
{line,[{location,"couch_key_tree.erl",225}]}.
- {call,1,{f,247}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{1 => number,
- 2 => {t_cons,{t_tuple,0,false,#{}},nil}}},
- nil}}]}}.
+ {call,1,{f,277}}.
{line,[{location,"couch_key_tree.erl",224}]}.
{call_ext,1,{extfunc,lists,sort,1}}.
{move,{x,0},{y,0}}.
- {make_fun2,{f,242},0,0,0}.
- {'%',{var_info,{x,0},[{fun_type,{t_list,any,nil}}]}}.
+ {make_fun2,{f,271},0,0,0}.
{move,{y,0},{x,2}}.
{move,nil,{x,1}}.
{trim,1,1}.
@@ -708,127 +628,108 @@
{put_tuple2,{x,0},{list,[{x,0},{y,0}]}}.
{deallocate,1}.
return.
+ {label,52}.
+ {line,[{location,"couch_key_tree.erl",222}]}.
+ {badmatch,{x,0}}.
-{function, get_key_leafs, 2, 45}.
- {label,44}.
+{function, get_key_leafs, 2, 54}.
+ {label,53}.
{line,[{location,"couch_key_tree.erl",245}]}.
{func_info,{atom,couch_key_tree},{atom,get_key_leafs},2}.
- {label,45}.
+ {label,54}.
{move,nil,{x,2}}.
- {call_only,3,{f,47}}.
+ {call_only,3,{f,56}}.
-{function, get_key_leafs, 3, 47}.
- {label,46}.
+{function, get_key_leafs, 3, 56}.
+ {label,55}.
{line,[{location,"couch_key_tree.erl",248}]}.
{func_info,{atom,couch_key_tree},{atom,get_key_leafs},3}.
- {label,47}.
- {'%',
- {var_info,
- {x,2},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_tuple,2,true,#{2 => {t_cons,any,any}}}}},
- nil}}]}}.
- {test,is_nil,{f,48},[{x,1}]}.
+ {label,56}.
+ {test,is_nil,{f,57},[{x,1}]}.
{test_heap,3,3}.
{put_tuple2,{x,0},{list,[{x,2},nil]}}.
return.
- {label,48}.
- {test,is_nonempty_list,{f,49},[{x,0}]}.
+ {label,57}.
+ {test,is_nonempty_list,{f,58},[{x,0}]}.
{get_list,{x,0},{x,3},{x,4}}.
- {test,is_tuple,{f,46},[{x,3}]}.
- {test,test_arity,{f,46},[{x,3},2]}.
- {allocate_heap,2,2,5}.
- {move,{x,4},{y,0}}.
- {move,{x,2},{y,1}}.
- {get_tuple_element,{x,3},1,{x,0}}.
- {put_list,{x,0},nil,{x,0}}.
- {get_tuple_element,{x,3},0,{x,2}}.
+ {test,is_tuple,{f,55},[{x,3}]}.
+ {test,test_arity,{f,55},[{x,3},2]}.
+ {allocate_heap,3,2,5}.
+ {init,{y,0}}.
+ {move,{x,4},{y,1}}.
+ {move,{x,2},{y,2}}.
+ {get_tuple_element,{x,3},0,{x,0}}.
+ {get_tuple_element,{x,3},1,{x,2}}.
+ {put_list,{x,2},nil,{x,2}}.
{move,nil,{x,3}}.
{swap,{x,1},{x,2}}.
- {swap,{x,0},{x,1}}.
{line,[{location,"couch_key_tree.erl",253}]}.
- {call,4,{f,51}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 =>
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_tuple,2,true,#{2 => {t_cons,any,any}}}}},
- nil}}}}]}}.
+ {call,4,{f,61}}.
+ {test,is_tuple,{f,59},[{x,0}]}.
+ {test,test_arity,{f,59},[{x,0},2]}.
{get_tuple_element,{x,0},0,{x,1}}.
- {move,{y,1},{x,2}}.
- {move,{x,0},{y,1}}.
+ {get_tuple_element,{x,0},1,{y,0}}.
{move,{x,1},{x,0}}.
- {move,{x,2},{x,1}}.
+ {move,{y,2},{x,1}}.
+ {kill,{y,2}}.
{line,[{location,"couch_key_tree.erl",254}]}.
{call_ext,2,{extfunc,erlang,'++',2}}.
- {get_tuple_element,{y,1},1,{x,1}}.
+ {move,{y,0},{x,1}}.
{move,{x,0},{x,2}}.
- {move,{y,0},{x,0}}.
- {call_last,3,{f,47},2}.
- {label,49}.
- {test,is_nil,{f,46},[{x,0}]}.
+ {move,{y,1},{x,0}}.
+ {call_last,3,{f,56},3}.
+ {label,58}.
+ {test,is_nil,{f,55},[{x,0}]}.
{test_heap,3,3}.
{put_tuple2,{x,0},{list,[{x,2},{x,1}]}}.
return.
+ {label,59}.
+ {line,[{location,"couch_key_tree.erl",253}]}.
+ {badmatch,{x,0}}.
-{function, get_key_leafs_simple, 4, 51}.
- {label,50}.
+{function, get_key_leafs_simple, 4, 61}.
+ {label,60}.
{line,[{location,"couch_key_tree.erl",256}]}.
{func_info,{atom,couch_key_tree},{atom,get_key_leafs_simple},4}.
- {label,51}.
- {'%',{var_info,{x,3},[{type,{t_list,any,nil}}]}}.
- {test,is_nil,{f,52},[{x,2}]}.
+ {label,61}.
+ {test,is_nil,{f,62},[{x,2}]}.
{move,{literal,{[],[]}},{x,0}}.
return.
- {label,52}.
- {test,is_nonempty_list,{f,54},[{x,1}]}.
+ {label,62}.
+ {test,is_nonempty_list,{f,64},[{x,1}]}.
{get_list,{x,1},{x,4},{x,5}}.
- {test,is_tuple,{f,50},[{x,4}]}.
- {test,test_arity,{f,50},[{x,4},3]}.
- {allocate_heap,6,3,6}.
- {move,{x,4},{y,1}}.
- {move,{x,5},{y,2}}.
- {move,{x,3},{y,3}}.
- {move,{x,2},{y,4}}.
- {move,{x,0},{y,5}}.
- {get_tuple_element,{x,4},0,{y,0}}.
- {put_tuple2,{x,0},{list,[{x,0},{y,0}]}}.
+ {test,is_tuple,{f,60},[{x,4}]}.
+ {test,test_arity,{f,60},[{x,4},3]}.
+ {allocate_heap,7,3,6}.
+ {move,{x,4},{y,2}}.
+ {move,{x,5},{y,3}}.
+ {move,{x,3},{y,4}}.
+ {move,{x,2},{y,5}}.
+ {move,{x,0},{y,6}}.
+ {get_tuple_element,{x,4},0,{y,1}}.
+ {get_tuple_element,{x,4},2,{y,0}}.
+ {put_tuple2,{x,0},{list,[{x,0},{y,1}]}}.
{move,{x,2},{x,1}}.
{line,[{location,"couch_key_tree.erl",261}]}.
{call_ext,2,{extfunc,lists,delete,2}}.
- {test,is_eq_exact,{f,53},[{x,0},{y,4}]}.
+ {test,is_eq_exact,{f,63},[{x,0},{y,5}]}.
{test_heap,2,0}.
- {put_list,{y,0},{y,3},{x,0}}.
+ {put_list,{y,1},{y,4},{x,0}}.
{line,[{location,"couch_key_tree.erl",265}]}.
- {gc_bif,'+',{f,0},1,[{y,5},{integer,1}],{x,1}}.
- {get_tuple_element,{y,1},2,{x,2}}.
+ {gc_bif,'+',{f,0},1,[{y,6},{integer,1}],{x,1}}.
+ {move,{y,5},{x,2}}.
{move,{x,0},{x,3}}.
{move,{x,1},{x,0}}.
- {move,{x,2},{x,1}}.
- {move,{y,4},{x,2}}.
- {kill,{y,4}}.
- {trim,2,4}.
+ {move,{y,0},{x,1}}.
+ {kill,{y,5}}.
+ {trim,3,4}.
{line,[{location,"couch_key_tree.erl",265}]}.
- {call,4,{f,51}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 =>
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_tuple,2,true,#{2 => {t_cons,any,any}}}}},
- nil}}}}]}}.
+ {call,4,{f,61}}.
+ {test,is_tuple,{f,66},[{x,0}]}.
+ {test,test_arity,{f,66},[{x,0},2]}.
{get_tuple_element,{x,0},0,{y,2}}.
{get_tuple_element,{x,0},1,{x,2}}.
{move,{y,0},{x,1}}.
@@ -837,48 +738,31 @@
{kill,{y,3}}.
{trim,2,2}.
{line,[{location,"couch_key_tree.erl",266}]}.
- {call,4,{f,51}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 =>
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_tuple,2,true,#{2 => {t_cons,any,any}}}}},
- nil}}}}]}}.
+ {call,4,{f,61}}.
+ {test,is_tuple,{f,65},[{x,0}]}.
+ {test,test_arity,{f,65},[{x,0},2]}.
{get_tuple_element,{x,0},0,{x,1}}.
- {move,{x,0},{y,1}}.
+ {get_tuple_element,{x,0},1,{y,1}}.
{move,{y,0},{x,0}}.
{trim,1,1}.
{line,[{location,"couch_key_tree.erl",267}]}.
{call_ext,2,{extfunc,erlang,'++',2}}.
{test_heap,3,1}.
- {get_tuple_element,{y,0},1,{x,1}}.
- {put_tuple2,{x,0},{list,[{x,0},{x,1}]}}.
+ {put_tuple2,{x,0},{list,[{x,0},{y,0}]}}.
{deallocate,1}.
return.
- {label,53}.
+ {label,63}.
{test_heap,2,1}.
- {put_list,{y,1},nil,{x,1}}.
+ {put_list,{y,2},nil,{x,1}}.
{move,{x,0},{x,2}}.
- {move,{y,3},{x,3}}.
- {kill,{y,4}}.
- {trim,2,4}.
+ {move,{y,4},{x,3}}.
+ {kill,{y,5}}.
+ {trim,3,4}.
{move,{y,3},{x,0}}.
{line,[{location,"couch_key_tree.erl",273}]}.
- {call,4,{f,56}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 =>
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_tuple,2,true,#{2 => {t_cons,any,any}}}}},
- nil}}}}]}}.
+ {call,4,{f,70}}.
+ {test,is_tuple,{f,68},[{x,0}]}.
+ {test,test_arity,{f,68},[{x,0},2]}.
{get_tuple_element,{x,0},0,{y,2}}.
{get_tuple_element,{x,0},1,{x,2}}.
{move,{y,0},{x,1}}.
@@ -887,49 +771,51 @@
{kill,{y,3}}.
{trim,2,2}.
{line,[{location,"couch_key_tree.erl",274}]}.
- {call,4,{f,51}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 =>
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_tuple,2,true,#{2 => {t_cons,any,any}}}}},
- nil}}}}]}}.
+ {call,4,{f,61}}.
+ {test,is_tuple,{f,67},[{x,0}]}.
+ {test,test_arity,{f,67},[{x,0},2]}.
{get_tuple_element,{x,0},0,{x,1}}.
- {move,{x,0},{y,1}}.
+ {get_tuple_element,{x,0},1,{y,1}}.
{move,{y,0},{x,0}}.
{trim,1,1}.
{line,[{location,"couch_key_tree.erl",275}]}.
{call_ext,2,{extfunc,erlang,'++',2}}.
{test_heap,3,1}.
- {get_tuple_element,{y,0},1,{x,1}}.
- {put_tuple2,{x,0},{list,[{x,0},{x,1}]}}.
+ {put_tuple2,{x,0},{list,[{x,0},{y,0}]}}.
{deallocate,1}.
return.
- {label,54}.
- {test,is_nil,{f,50},[{x,1}]}.
+ {label,64}.
+ {test,is_nil,{f,60},[{x,1}]}.
{test_heap,3,3}.
{put_tuple2,{x,0},{list,[nil,{x,2}]}}.
return.
+ {label,65}.
+ {line,[{location,"couch_key_tree.erl",266}]}.
+ {badmatch,{x,0}}.
+ {label,66}.
+ {line,[{location,"couch_key_tree.erl",265}]}.
+ {badmatch,{x,0}}.
+ {label,67}.
+ {line,[{location,"couch_key_tree.erl",274}]}.
+ {badmatch,{x,0}}.
+ {label,68}.
+ {line,[{location,"couch_key_tree.erl",273}]}.
+ {badmatch,{x,0}}.
-{function, get_key_leafs_simple2, 4, 56}.
- {label,55}.
+{function, get_key_leafs_simple2, 4, 70}.
+ {label,69}.
{line,[{location,"couch_key_tree.erl",278}]}.
{func_info,{atom,couch_key_tree},{atom,get_key_leafs_simple2},4}.
- {label,56}.
- {'%',{var_info,{x,3},[{type,{t_list,any,nil}}]}}.
- {test,is_nonempty_list,{f,58},[{x,1}]}.
+ {label,70}.
+ {test,is_nonempty_list,{f,72},[{x,1}]}.
{get_list,{x,1},{x,4},{x,5}}.
- {test,is_tuple,{f,55},[{x,4}]}.
- {test,test_arity,{f,55},[{x,4},3]}.
+ {test,is_tuple,{f,69},[{x,4}]}.
+ {test,test_arity,{f,69},[{x,4},3]}.
{get_tuple_element,{x,4},0,{x,1}}.
{get_tuple_element,{x,4},1,{x,6}}.
{get_tuple_element,{x,4},2,{x,4}}.
- {test,is_nil,{f,57},[{x,4}]}.
+ {test,is_nil,{f,71},[{x,4}]}.
{allocate_heap,5,3,7}.
{move,{x,1},{y,0}}.
{move,{x,6},{y,1}}.
@@ -947,17 +833,9 @@
{trim,1,4}.
{move,{y,3},{x,0}}.
{line,[{location,"couch_key_tree.erl",286}]}.
- {call,4,{f,56}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 =>
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_tuple,2,true,#{2 => {t_cons,any,any}}}}},
- nil}}}}]}}.
+ {call,4,{f,70}}.
+ {test,is_tuple,{f,73},[{x,0}]}.
+ {test,test_arity,{f,73},[{x,0},2]}.
{test_heap,13,1}.
{get_tuple_element,{x,0},0,{x,1}}.
{get_tuple_element,{x,0},1,{x,0}}.
@@ -968,7 +846,7 @@
{put_tuple2,{x,0},{list,[{x,1},{x,0}]}}.
{deallocate,4}.
return.
- {label,57}.
+ {label,71}.
{allocate_heap,5,3,6}.
{move,{x,1},{y,0}}.
{move,{x,4},{y,1}}.
@@ -989,17 +867,9 @@
{kill,{y,1}}.
{trim,1,4}.
{line,[{location,"couch_key_tree.erl",293}]}.
- {call,4,{f,56}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 =>
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_tuple,2,true,#{2 => {t_cons,any,any}}}}},
- nil}}}}]}}.
+ {call,4,{f,70}}.
+ {test,is_tuple,{f,75},[{x,0}]}.
+ {test,test_arity,{f,75},[{x,0},2]}.
{get_tuple_element,{x,0},0,{y,0}}.
{get_tuple_element,{x,0},1,{x,2}}.
{move,{y,1},{x,1}}.
@@ -1009,164 +879,138 @@
{kill,{y,2}}.
{kill,{y,3}}.
{line,[{location,"couch_key_tree.erl",294}]}.
- {call,4,{f,56}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 =>
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_tuple,2,true,#{2 => {t_cons,any,any}}}}},
- nil}}}}]}}.
+ {call,4,{f,70}}.
+ {test,is_tuple,{f,74},[{x,0}]}.
+ {test,test_arity,{f,74},[{x,0},2]}.
{get_tuple_element,{x,0},0,{x,1}}.
- {move,{x,0},{y,3}}.
+ {get_tuple_element,{x,0},1,{y,3}}.
{move,{y,0},{x,0}}.
{trim,3,1}.
{line,[{location,"couch_key_tree.erl",295}]}.
{call_ext,2,{extfunc,erlang,'++',2}}.
{test_heap,3,1}.
- {get_tuple_element,{y,0},1,{x,1}}.
- {put_tuple2,{x,0},{list,[{x,0},{x,1}]}}.
+ {put_tuple2,{x,0},{list,[{x,0},{y,0}]}}.
{deallocate,1}.
return.
- {label,58}.
- {test,is_nil,{f,55},[{x,1}]}.
+ {label,72}.
+ {test,is_nil,{f,69},[{x,1}]}.
{test_heap,3,3}.
{put_tuple2,{x,0},{list,[nil,{x,2}]}}.
return.
+ {label,73}.
+ {line,[{location,"couch_key_tree.erl",286}]}.
+ {badmatch,{x,0}}.
+ {label,74}.
+ {line,[{location,"couch_key_tree.erl",294}]}.
+ {badmatch,{x,0}}.
+ {label,75}.
+ {line,[{location,"couch_key_tree.erl",293}]}.
+ {badmatch,{x,0}}.
-{function, get, 2, 60}.
- {label,59}.
+{function, get, 2, 77}.
+ {label,76}.
{line,[{location,"couch_key_tree.erl",297}]}.
{func_info,{atom,couch_key_tree},{atom,get},2}.
- {label,60}.
+ {label,77}.
{allocate_zero,1,2}.
{line,[{location,"couch_key_tree.erl",298}]}.
- {call,2,{f,62}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 =>
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_cons,{t_tuple,0,false,#{}},nil}}},
- nil}}}}]}}.
+ {call,2,{f,80}}.
+ {test,is_tuple,{f,78},[{x,0}]}.
+ {test,test_arity,{f,78},[{x,0},2]}.
{get_tuple_element,{x,0},0,{x,1}}.
{get_tuple_element,{x,0},1,{y,0}}.
{move,{x,1},{x,0}}.
{line,[{location,"couch_key_tree.erl",301}]}.
- {call,1,{f,234}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_tuple,2,true,#{2 => {t_list,any,nil}}}}},
- nil}}]}}.
+ {call,1,{f,263}}.
{test_heap,3,1}.
{put_tuple2,{x,0},{list,[{x,0},{y,0}]}}.
{deallocate,1}.
return.
+ {label,78}.
+ {line,[{location,"couch_key_tree.erl",298}]}.
+ {badmatch,{x,0}}.
-{function, get_full_key_paths, 2, 62}.
- {label,61}.
+{function, get_full_key_paths, 2, 80}.
+ {label,79}.
{line,[{location,"couch_key_tree.erl",305}]}.
{func_info,{atom,couch_key_tree},{atom,get_full_key_paths},2}.
- {label,62}.
+ {label,80}.
{move,nil,{x,2}}.
- {call_only,3,{f,64}}.
+ {call_only,3,{f,82}}.
-{function, get_full_key_paths, 3, 64}.
- {label,63}.
+{function, get_full_key_paths, 3, 82}.
+ {label,81}.
{line,[{location,"couch_key_tree.erl",308}]}.
{func_info,{atom,couch_key_tree},{atom,get_full_key_paths},3}.
- {label,64}.
- {'%',
- {var_info,
- {x,2},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_cons,{t_tuple,0,false,#{}},nil}}},
- nil}}]}}.
- {test,is_nil,{f,65},[{x,1}]}.
+ {label,82}.
+ {test,is_nil,{f,83},[{x,1}]}.
{test_heap,3,3}.
{put_tuple2,{x,0},{list,[{x,2},nil]}}.
return.
- {label,65}.
- {test,is_nonempty_list,{f,66},[{x,0}]}.
+ {label,83}.
+ {test,is_nonempty_list,{f,84},[{x,0}]}.
{get_list,{x,0},{x,3},{x,4}}.
- {test,is_tuple,{f,63},[{x,3}]}.
- {test,test_arity,{f,63},[{x,3},2]}.
- {allocate_heap,2,2,5}.
- {move,{x,4},{y,0}}.
- {move,{x,2},{y,1}}.
- {get_tuple_element,{x,3},1,{x,0}}.
- {put_list,{x,0},nil,{x,0}}.
- {get_tuple_element,{x,3},0,{x,2}}.
+ {test,is_tuple,{f,81},[{x,3}]}.
+ {test,test_arity,{f,81},[{x,3},2]}.
+ {allocate_heap,3,2,5}.
+ {init,{y,0}}.
+ {move,{x,4},{y,1}}.
+ {move,{x,2},{y,2}}.
+ {get_tuple_element,{x,3},0,{x,0}}.
+ {get_tuple_element,{x,3},1,{x,2}}.
+ {put_list,{x,2},nil,{x,2}}.
{move,nil,{x,3}}.
{swap,{x,1},{x,2}}.
- {swap,{x,0},{x,1}}.
{line,[{location,"couch_key_tree.erl",313}]}.
- {call,4,{f,68}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 =>
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_cons,{t_tuple,0,false,#{}},nil}}},
- nil}}}}]}}.
+ {call,4,{f,87}}.
+ {test,is_tuple,{f,85},[{x,0}]}.
+ {test,test_arity,{f,85},[{x,0},2]}.
{get_tuple_element,{x,0},0,{x,1}}.
- {move,{y,1},{x,2}}.
- {move,{x,0},{y,1}}.
+ {get_tuple_element,{x,0},1,{y,0}}.
{move,{x,1},{x,0}}.
- {move,{x,2},{x,1}}.
+ {move,{y,2},{x,1}}.
+ {kill,{y,2}}.
{line,[{location,"couch_key_tree.erl",314}]}.
{call_ext,2,{extfunc,erlang,'++',2}}.
- {get_tuple_element,{y,1},1,{x,1}}.
+ {move,{y,0},{x,1}}.
{move,{x,0},{x,2}}.
- {move,{y,0},{x,0}}.
- {call_last,3,{f,64},2}.
- {label,66}.
- {test,is_nil,{f,63},[{x,0}]}.
+ {move,{y,1},{x,0}}.
+ {call_last,3,{f,82},3}.
+ {label,84}.
+ {test,is_nil,{f,81},[{x,0}]}.
{test_heap,3,3}.
{put_tuple2,{x,0},{list,[{x,2},{x,1}]}}.
return.
+ {label,85}.
+ {line,[{location,"couch_key_tree.erl",313}]}.
+ {badmatch,{x,0}}.
-{function, get_full_key_paths, 4, 68}.
- {label,67}.
+{function, get_full_key_paths, 4, 87}.
+ {label,86}.
{line,[{location,"couch_key_tree.erl",316}]}.
{func_info,{atom,couch_key_tree},{atom,get_full_key_paths},4}.
- {label,68}.
- {'%',{var_info,{x,3},[{type,{t_list,{t_tuple,2,true,#{}},nil}}]}}.
- {test,is_nil,{f,69},[{x,2}]}.
+ {label,87}.
+ {test,is_nil,{f,88},[{x,2}]}.
{move,{literal,{[],[]}},{x,0}}.
return.
- {label,69}.
- {test,is_nonempty_list,{f,72},[{x,1}]}.
+ {label,88}.
+ {test,is_nonempty_list,{f,91},[{x,1}]}.
{get_list,{x,1},{x,4},{x,5}}.
- {test,is_tuple,{f,67},[{x,4}]}.
- {test,test_arity,{f,67},[{x,4},3]}.
- {allocate_heap,6,5,6}.
- {move,{x,4},{y,1}}.
- {move,{x,5},{y,2}}.
- {move,{x,3},{y,3}}.
- {move,{x,2},{y,4}}.
- {move,{x,0},{y,5}}.
- {get_tuple_element,{x,4},0,{y,0}}.
- {put_tuple2,{x,0},{list,[{x,0},{y,0}]}}.
+ {test,is_tuple,{f,86},[{x,4}]}.
+ {test,test_arity,{f,86},[{x,4},3]}.
+ {allocate_heap,7,5,6}.
+ {move,{x,5},{y,3}}.
+ {move,{x,3},{y,4}}.
+ {move,{x,2},{y,5}}.
+ {move,{x,0},{y,6}}.
+ {get_tuple_element,{x,4},0,{y,2}}.
+ {get_tuple_element,{x,4},1,{y,1}}.
+ {get_tuple_element,{x,4},2,{y,0}}.
+ {put_tuple2,{x,0},{list,[{x,0},{y,2}]}}.
{put_list,{x,0},nil,{x,1}}.
{move,{x,2},{x,0}}.
{line,[{location,"couch_key_tree.erl",321}]}.
@@ -1174,41 +1018,32 @@
{line,[{location,"couch_key_tree.erl",323}]}.
{gc_bif,length,{f,0},1,[{x,0}],{x,1}}.
{line,[{location,"couch_key_tree.erl",323}]}.
- {gc_bif,length,{f,0},2,[{y,4}],{x,2}}.
- {get_tuple_element,{y,1},1,{x,3}}.
- {test,is_eq_exact,{f,70},[{x,1},{x,2}]}.
- {move,nil,{y,4}}.
- {jump,{f,71}}.
- {label,70}.
- {test_heap,10,4}.
- {put_tuple2,{x,1},{list,[{y,0},{x,3}]}}.
- {put_list,{x,1},{y,3},{x,1}}.
- {put_tuple2,{x,1},{list,[{y,5},{x,1}]}}.
+ {gc_bif,length,{f,0},2,[{y,5}],{x,2}}.
+ {test,is_eq_exact,{f,89},[{x,1},{x,2}]}.
+ {move,nil,{y,5}}.
+ {jump,{f,90}}.
+ {label,89}.
+ {test_heap,10,1}.
+ {put_tuple2,{x,1},{list,[{y,2},{y,1}]}}.
+ {put_list,{x,1},{y,4},{x,1}}.
+ {put_tuple2,{x,1},{list,[{y,6},{x,1}]}}.
{put_list,{x,1},nil,{x,1}}.
- {move,{x,1},{y,4}}.
- {label,71}.
+ {move,{x,1},{y,5}}.
+ {label,90}.
{line,[{location,"couch_key_tree.erl",331}]}.
- {gc_bif,'+',{f,0},4,[{y,5},{integer,1}],{x,1}}.
- {test_heap,5,4}.
- {put_tuple2,{x,2},{list,[{y,0},{x,3}]}}.
- {put_list,{x,2},{y,3},{x,3}}.
- {get_tuple_element,{y,1},2,{x,2}}.
- {swap,{x,2},{x,1}}.
- {swap,{x,0},{x,2}}.
- {kill,{y,1}}.
- {trim,1,5}.
+ {gc_bif,'+',{f,0},1,[{y,6},{integer,1}],{x,1}}.
+ {test_heap,5,2}.
+ {put_tuple2,{x,2},{list,[{y,2},{y,1}]}}.
+ {put_list,{x,2},{y,4},{x,3}}.
+ {move,{x,0},{x,2}}.
+ {move,{x,1},{x,0}}.
+ {move,{y,0},{x,1}}.
+ {kill,{y,2}}.
+ {trim,2,5}.
{line,[{location,"couch_key_tree.erl",331}]}.
- {call,4,{f,68}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 =>
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_cons,{t_tuple,0,false,#{}},nil}}},
- nil}}}}]}}.
+ {call,4,{f,87}}.
+ {test,is_tuple,{f,93},[{x,0}]}.
+ {test,test_arity,{f,93},[{x,0},2]}.
{get_tuple_element,{x,0},0,{y,0}}.
{get_tuple_element,{x,0},1,{x,2}}.
{move,{y,1},{x,1}}.
@@ -1218,19 +1053,11 @@
{kill,{y,2}}.
{kill,{y,4}}.
{line,[{location,"couch_key_tree.erl",334}]}.
- {call,4,{f,68}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 =>
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_cons,{t_tuple,0,false,#{}},nil}}},
- nil}}}}]}}.
+ {call,4,{f,87}}.
+ {test,is_tuple,{f,92},[{x,0}]}.
+ {test,test_arity,{f,92},[{x,0},2]}.
{get_tuple_element,{x,0},0,{x,1}}.
- {move,{x,0},{y,4}}.
+ {get_tuple_element,{x,0},1,{y,4}}.
{move,{y,0},{x,0}}.
{trim,3,2}.
{line,[{location,"couch_key_tree.erl",335}]}.
@@ -1241,87 +1068,75 @@
{line,[{location,"couch_key_tree.erl",335}]}.
{call_ext,2,{extfunc,erlang,'++',2}}.
{test_heap,3,1}.
- {get_tuple_element,{y,0},1,{x,1}}.
- {put_tuple2,{x,0},{list,[{x,0},{x,1}]}}.
+ {put_tuple2,{x,0},{list,[{x,0},{y,0}]}}.
{deallocate,1}.
return.
- {label,72}.
- {test,is_nil,{f,67},[{x,1}]}.
+ {label,91}.
+ {test,is_nil,{f,86},[{x,1}]}.
{test_heap,3,3}.
{put_tuple2,{x,0},{list,[nil,{x,2}]}}.
return.
+ {label,92}.
+ {line,[{location,"couch_key_tree.erl",334}]}.
+ {badmatch,{x,0}}.
+ {label,93}.
+ {line,[{location,"couch_key_tree.erl",331}]}.
+ {badmatch,{x,0}}.
-{function, get_all_leafs_full, 1, 74}.
- {label,73}.
+{function, get_all_leafs_full, 1, 95}.
+ {label,94}.
{line,[{location,"couch_key_tree.erl",337}]}.
{func_info,{atom,couch_key_tree},{atom,get_all_leafs_full},1}.
- {label,74}.
+ {label,95}.
{move,nil,{x,1}}.
- {call_only,2,{f,76}}.
+ {call_only,2,{f,97}}.
-{function, get_all_leafs_full, 2, 76}.
- {label,75}.
+{function, get_all_leafs_full, 2, 97}.
+ {label,96}.
{line,[{location,"couch_key_tree.erl",340}]}.
{func_info,{atom,couch_key_tree},{atom,get_all_leafs_full},2}.
- {label,76}.
- {'%',
- {var_info,
- {x,1},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_cons,{t_tuple,2,true,#{}},nil}}},
- nil}}]}}.
- {test,is_nonempty_list,{f,77},[{x,0}]}.
+ {label,97}.
+ {test,is_nonempty_list,{f,98},[{x,0}]}.
{get_list,{x,0},{x,2},{x,3}}.
- {test,is_tuple,{f,75},[{x,2}]}.
- {test,test_arity,{f,75},[{x,2},2]}.
+ {test,is_tuple,{f,96},[{x,2}]}.
+ {test,test_arity,{f,96},[{x,2},2]}.
{allocate_heap,2,2,4}.
{move,{x,3},{y,0}}.
{move,{x,1},{y,1}}.
- {get_tuple_element,{x,2},1,{x,0}}.
- {put_list,{x,0},nil,{x,1}}.
{get_tuple_element,{x,2},0,{x,0}}.
+ {get_tuple_element,{x,2},1,{x,1}}.
+ {put_list,{x,1},nil,{x,1}}.
{move,nil,{x,2}}.
{line,[{location,"couch_key_tree.erl",343}]}.
- {call,3,{f,79}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_cons,{t_tuple,2,true,#{}},nil}}},
- nil}}]}}.
+ {call,3,{f,100}}.
{move,{y,1},{x,1}}.
{kill,{y,1}}.
{line,[{location,"couch_key_tree.erl",343}]}.
{call_ext,2,{extfunc,erlang,'++',2}}.
{move,{x,0},{x,1}}.
{move,{y,0},{x,0}}.
- {call_last,2,{f,76},2}.
- {label,77}.
- {test,is_nil,{f,75},[{x,0}]}.
+ {call_last,2,{f,97},2}.
+ {label,98}.
+ {test,is_nil,{f,96},[{x,0}]}.
{move,{x,1},{x,0}}.
return.
-{function, get_all_leafs_full_simple, 3, 79}.
- {label,78}.
+{function, get_all_leafs_full_simple, 3, 100}.
+ {label,99}.
{line,[{location,"couch_key_tree.erl",345}]}.
{func_info,{atom,couch_key_tree},{atom,get_all_leafs_full_simple},3}.
- {label,79}.
- {'%',{var_info,{x,2},[{type,{t_list,{t_tuple,2,true,#{}},nil}}]}}.
- {test,is_nonempty_list,{f,81},[{x,1}]}.
+ {label,100}.
+ {test,is_nonempty_list,{f,102},[{x,1}]}.
{get_list,{x,1},{x,3},{x,4}}.
- {test,is_tuple,{f,78},[{x,3}]}.
- {test,test_arity,{f,78},[{x,3},3]}.
+ {test,is_tuple,{f,99},[{x,3}]}.
+ {test,test_arity,{f,99},[{x,3},3]}.
{get_tuple_element,{x,3},0,{x,1}}.
{get_tuple_element,{x,3},1,{x,5}}.
{get_tuple_element,{x,3},2,{x,3}}.
- {test,is_nil,{f,80},[{x,3}]}.
+ {test,is_nil,{f,101},[{x,3}]}.
{allocate,4,6}.
{move,{x,1},{y,0}}.
{move,{x,5},{y,1}}.
@@ -1329,15 +1144,7 @@
{move,{x,0},{y,3}}.
{move,{x,4},{x,1}}.
{line,[{location,"couch_key_tree.erl",348}]}.
- {call,3,{f,79}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_cons,{t_tuple,2,true,#{}},nil}}},
- nil}}]}}.
+ {call,3,{f,100}}.
{test_heap,10,1}.
{put_tuple2,{x,1},{list,[{y,0},{y,1}]}}.
{put_list,{x,1},{y,2},{x,1}}.
@@ -1345,7 +1152,7 @@
{put_list,{x,1},{x,0},{x,0}}.
{deallocate,4}.
return.
- {label,80}.
+ {label,101}.
{line,[{location,"couch_key_tree.erl",350}]}.
{gc_bif,'+',{f,0},6,[{x,0},{integer,1}],{x,6}}.
{allocate_heap,3,5,7}.
@@ -1357,15 +1164,7 @@
{move,{x,3},{x,1}}.
{move,{x,6},{x,0}}.
{line,[{location,"couch_key_tree.erl",350}]}.
- {call,3,{f,79}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_cons,{t_tuple,2,true,#{}},nil}}},
- nil}}]}}.
+ {call,3,{f,100}}.
{move,{y,0},{x,2}}.
{move,{y,1},{x,3}}.
{swap,{y,2},{x,0}}.
@@ -1373,95 +1172,70 @@
{move,{x,3},{x,2}}.
{trim,2,1}.
{line,[{location,"couch_key_tree.erl",351}]}.
- {call,3,{f,79}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_cons,{t_tuple,2,true,#{}},nil}}},
- nil}}]}}.
+ {call,3,{f,100}}.
{move,{x,0},{x,1}}.
{move,{y,0},{x,0}}.
{line,[{location,"couch_key_tree.erl",350}]}.
{call_ext_last,2,{extfunc,erlang,'++',2},1}.
- {label,81}.
- {test,is_nil,{f,78},[{x,1}]}.
+ {label,102}.
+ {test,is_nil,{f,99},[{x,1}]}.
{move,nil,{x,0}}.
return.
-{function, get_all_leafs, 1, 83}.
- {label,82}.
+{function, get_all_leafs, 1, 104}.
+ {label,103}.
{line,[{location,"couch_key_tree.erl",353}]}.
{func_info,{atom,couch_key_tree},{atom,get_all_leafs},1}.
- {label,83}.
+ {label,104}.
{move,nil,{x,1}}.
- {call_only,2,{f,85}}.
+ {call_only,2,{f,106}}.
-{function, get_all_leafs, 2, 85}.
- {label,84}.
+{function, get_all_leafs, 2, 106}.
+ {label,105}.
{line,[{location,"couch_key_tree.erl",356}]}.
{func_info,{atom,couch_key_tree},{atom,get_all_leafs},2}.
- {label,85}.
- {'%',
- {var_info,
- {x,1},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_tuple,2,true,#{2 => {t_cons,any,nil}}}}},
- nil}}]}}.
- {test,is_nonempty_list,{f,86},[{x,0}]}.
+ {label,106}.
+ {test,is_nonempty_list,{f,107},[{x,0}]}.
{get_list,{x,0},{x,2},{x,3}}.
- {test,is_tuple,{f,84},[{x,2}]}.
- {test,test_arity,{f,84},[{x,2},2]}.
+ {test,is_tuple,{f,105},[{x,2}]}.
+ {test,test_arity,{f,105},[{x,2},2]}.
{allocate_heap,2,2,4}.
{move,{x,3},{y,0}}.
{move,{x,1},{y,1}}.
- {get_tuple_element,{x,2},1,{x,0}}.
- {put_list,{x,0},nil,{x,1}}.
{get_tuple_element,{x,2},0,{x,0}}.
+ {get_tuple_element,{x,2},1,{x,1}}.
+ {put_list,{x,1},nil,{x,1}}.
{move,nil,{x,2}}.
{line,[{location,"couch_key_tree.erl",359}]}.
- {call,3,{f,88}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_tuple,2,true,#{2 => {t_cons,any,nil}}}}},
- nil}}]}}.
+ {call,3,{f,109}}.
{move,{y,1},{x,1}}.
{kill,{y,1}}.
{line,[{location,"couch_key_tree.erl",359}]}.
{call_ext,2,{extfunc,erlang,'++',2}}.
{move,{x,0},{x,1}}.
{move,{y,0},{x,0}}.
- {call_last,2,{f,85},2}.
- {label,86}.
- {test,is_nil,{f,84},[{x,0}]}.
+ {call_last,2,{f,106},2}.
+ {label,107}.
+ {test,is_nil,{f,105},[{x,0}]}.
{move,{x,1},{x,0}}.
return.
-{function, get_all_leafs_simple, 3, 88}.
- {label,87}.
+{function, get_all_leafs_simple, 3, 109}.
+ {label,108}.
{line,[{location,"couch_key_tree.erl",361}]}.
{func_info,{atom,couch_key_tree},{atom,get_all_leafs_simple},3}.
- {label,88}.
- {'%',{var_info,{x,2},[{type,{t_list,any,nil}}]}}.
- {test,is_nonempty_list,{f,90},[{x,1}]}.
+ {label,109}.
+ {test,is_nonempty_list,{f,111},[{x,1}]}.
{get_list,{x,1},{x,3},{x,4}}.
- {test,is_tuple,{f,87},[{x,3}]}.
- {test,test_arity,{f,87},[{x,3},3]}.
+ {test,is_tuple,{f,108},[{x,3}]}.
+ {test,test_arity,{f,108},[{x,3},3]}.
{get_tuple_element,{x,3},0,{x,1}}.
{get_tuple_element,{x,3},1,{x,5}}.
{get_tuple_element,{x,3},2,{x,3}}.
- {test,is_nil,{f,89},[{x,3}]}.
+ {test,is_nil,{f,110},[{x,3}]}.
{allocate,4,6}.
{move,{x,1},{y,0}}.
{move,{x,5},{y,1}}.
@@ -1469,15 +1243,7 @@
{move,{x,0},{y,3}}.
{move,{x,4},{x,1}}.
{line,[{location,"couch_key_tree.erl",364}]}.
- {call,3,{f,88}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_tuple,2,true,#{2 => {t_cons,any,nil}}}}},
- nil}}]}}.
+ {call,3,{f,109}}.
{test_heap,10,1}.
{put_list,{y,0},{y,2},{x,1}}.
{put_tuple2,{x,1},{list,[{y,3},{x,1}]}}.
@@ -1485,7 +1251,7 @@
{put_list,{x,1},{x,0},{x,0}}.
{deallocate,4}.
return.
- {label,89}.
+ {label,110}.
{line,[{location,"couch_key_tree.erl",366}]}.
{gc_bif,'+',{f,0},5,[{x,0},{integer,1}],{x,5}}.
{allocate_heap,3,2,6}.
@@ -1496,15 +1262,7 @@
{move,{x,3},{x,1}}.
{move,{x,5},{x,0}}.
{line,[{location,"couch_key_tree.erl",366}]}.
- {call,3,{f,88}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_tuple,2,true,#{2 => {t_cons,any,nil}}}}},
- nil}}]}}.
+ {call,3,{f,109}}.
{move,{y,0},{x,2}}.
{move,{y,1},{x,3}}.
{swap,{y,2},{x,0}}.
@@ -1512,149 +1270,136 @@
{move,{x,3},{x,2}}.
{trim,2,1}.
{line,[{location,"couch_key_tree.erl",367}]}.
- {call,3,{f,88}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_tuple,2,true,#{2 => {t_cons,any,nil}}}}},
- nil}}]}}.
+ {call,3,{f,109}}.
{move,{x,0},{x,1}}.
{move,{y,0},{x,0}}.
{line,[{location,"couch_key_tree.erl",366}]}.
{call_ext_last,2,{extfunc,erlang,'++',2},1}.
- {label,90}.
- {test,is_nil,{f,87},[{x,1}]}.
+ {label,111}.
+ {test,is_nil,{f,108},[{x,1}]}.
{move,nil,{x,0}}.
return.
-{function, count_leafs, 1, 92}.
- {label,91}.
+{function, count_leafs, 1, 113}.
+ {label,112}.
{line,[{location,"couch_key_tree.erl",369}]}.
{func_info,{atom,couch_key_tree},{atom,count_leafs},1}.
- {label,92}.
- {test,is_nonempty_list,{f,93},[{x,0}]}.
+ {label,113}.
+ {test,is_nonempty_list,{f,114},[{x,0}]}.
{get_list,{x,0},{x,1},{x,2}}.
- {test,is_tuple,{f,91},[{x,1}]}.
- {test,test_arity,{f,91},[{x,1},2]}.
+ {test,is_tuple,{f,112},[{x,1}]}.
+ {test,test_arity,{f,112},[{x,1},2]}.
{allocate_heap,1,2,3}.
{move,{x,2},{y,0}}.
{get_tuple_element,{x,1},1,{x,0}}.
{put_list,{x,0},nil,{x,0}}.
{line,[{location,"couch_key_tree.erl",372}]}.
- {call,1,{f,95}}.
- {'%',{var_info,{x,0},[{type,{t_integer,any}}]}}.
+ {call,1,{f,116}}.
{swap,{y,0},{x,0}}.
{line,[{location,"couch_key_tree.erl",372}]}.
- {call,1,{f,92}}.
- {'%',{var_info,{x,0},[{type,{t_integer,any}}]}}.
+ {call,1,{f,113}}.
{line,[{location,"couch_key_tree.erl",372}]}.
{gc_bif,'+',{f,0},1,[{y,0},{x,0}],{x,0}}.
{deallocate,1}.
return.
- {label,93}.
- {test,is_nil,{f,91},[{x,0}]}.
+ {label,114}.
+ {test,is_nil,{f,112},[{x,0}]}.
{move,{integer,0},{x,0}}.
return.
-{function, count_leafs_simple, 1, 95}.
- {label,94}.
+{function, count_leafs_simple, 1, 116}.
+ {label,115}.
{line,[{location,"couch_key_tree.erl",374}]}.
{func_info,{atom,couch_key_tree},{atom,count_leafs_simple},1}.
- {label,95}.
- {test,is_nonempty_list,{f,97},[{x,0}]}.
+ {label,116}.
+ {test,is_nonempty_list,{f,118},[{x,0}]}.
{get_list,{x,0},{x,1},{x,2}}.
- {test,is_tuple,{f,94},[{x,1}]}.
- {test,test_arity,{f,94},[{x,1},3]}.
+ {test,is_tuple,{f,115},[{x,1}]}.
+ {test,test_arity,{f,115},[{x,1},3]}.
{get_tuple_element,{x,1},2,{x,0}}.
- {test,is_nil,{f,96},[{x,0}]}.
+ {test,is_nil,{f,117},[{x,0}]}.
{allocate,0,3}.
{move,{x,2},{x,0}}.
{line,[{location,"couch_key_tree.erl",377}]}.
- {call,1,{f,95}}.
- {'%',{var_info,{x,0},[{type,{t_integer,any}}]}}.
+ {call,1,{f,116}}.
{line,[{location,"couch_key_tree.erl",377}]}.
- {gc_bif,'+',{f,0},1,[{x,0},{integer,1}],{x,0}}.
+ {gc_bif,'+',{f,0},1,[{integer,1},{x,0}],{x,0}}.
{deallocate,0}.
return.
- {label,96}.
+ {label,117}.
{allocate,1,3}.
{move,{x,2},{y,0}}.
{line,[{location,"couch_key_tree.erl",379}]}.
- {call,1,{f,95}}.
- {'%',{var_info,{x,0},[{type,{t_integer,any}}]}}.
+ {call,1,{f,116}}.
{swap,{y,0},{x,0}}.
{line,[{location,"couch_key_tree.erl",379}]}.
- {call,1,{f,95}}.
- {'%',{var_info,{x,0},[{type,{t_integer,any}}]}}.
+ {call,1,{f,116}}.
{line,[{location,"couch_key_tree.erl",379}]}.
{gc_bif,'+',{f,0},1,[{y,0},{x,0}],{x,0}}.
{deallocate,1}.
return.
- {label,97}.
- {test,is_nil,{f,94},[{x,0}]}.
+ {label,118}.
+ {test,is_nil,{f,115},[{x,0}]}.
{move,{integer,0},{x,0}}.
return.
-{function, fold, 3, 99}.
- {label,98}.
+{function, fold, 3, 120}.
+ {label,119}.
{line,[{location,"couch_key_tree.erl",381}]}.
{func_info,{atom,couch_key_tree},{atom,fold},3}.
- {label,99}.
- {test,is_nonempty_list,{f,100},[{x,2}]}.
+ {label,120}.
+ {test,is_nonempty_list,{f,121},[{x,2}]}.
{get_list,{x,2},{x,3},{x,4}}.
- {test,is_tuple,{f,98},[{x,3}]}.
- {test,test_arity,{f,98},[{x,3},2]}.
+ {test,is_tuple,{f,119},[{x,3}]}.
+ {test,test_arity,{f,119},[{x,3},2]}.
{allocate_heap,2,2,5}.
{move,{x,4},{y,0}}.
{move,{x,0},{y,1}}.
- {get_tuple_element,{x,3},1,{x,0}}.
- {put_list,{x,0},nil,{x,0}}.
{get_tuple_element,{x,3},0,{x,2}}.
- {move,{x,0},{x,3}}.
+ {get_tuple_element,{x,3},1,{x,0}}.
+ {put_list,{x,0},nil,{x,3}}.
{move,{y,1},{x,0}}.
{line,[{location,"couch_key_tree.erl",384}]}.
- {call,4,{f,102}}.
+ {call,4,{f,123}}.
{move,{x,0},{x,1}}.
{move,{y,0},{x,2}}.
{move,{y,1},{x,0}}.
- {call_last,3,{f,99},2}.
- {label,100}.
- {test,is_nil,{f,98},[{x,2}]}.
+ {call_last,3,{f,120},2}.
+ {label,121}.
+ {test,is_nil,{f,119},[{x,2}]}.
{move,{x,1},{x,0}}.
return.
-{function, fold_simple, 4, 102}.
- {label,101}.
+{function, fold_simple, 4, 123}.
+ {label,122}.
{line,[{location,"couch_key_tree.erl",387}]}.
{func_info,{atom,couch_key_tree},{atom,fold_simple},4}.
- {label,102}.
- {test,is_nonempty_list,{f,105},[{x,3}]}.
+ {label,123}.
+ {test,is_nonempty_list,{f,126},[{x,3}]}.
{get_list,{x,3},{x,4},{x,5}}.
- {test,is_tuple,{f,101},[{x,4}]}.
- {test,test_arity,{f,101},[{x,4},3]}.
+ {test,is_tuple,{f,122},[{x,4}]}.
+ {test,test_arity,{f,122},[{x,4},3]}.
{allocate,4,6}.
{move,{x,5},{y,1}}.
{move,{x,2},{y,2}}.
{move,{x,0},{y,3}}.
- {get_tuple_element,{x,4},2,{y,0}}.
- {test,is_nil,{f,103},[{y,0}]}.
- {move,{atom,leaf},{x,2}}.
- {jump,{f,104}}.
- {label,103}.
- {move,{atom,branch},{x,2}}.
- {label,104}.
- {test_heap,3,5}.
{get_tuple_element,{x,4},0,{x,0}}.
+ {get_tuple_element,{x,4},1,{x,2}}.
+ {get_tuple_element,{x,4},2,{y,0}}.
+ {test,is_eq,{f,124},[{y,0},nil]}.
+ {move,{atom,leaf},{x,3}}.
+ {jump,{f,125}}.
+ {label,124}.
+ {move,{atom,branch},{x,3}}.
+ {label,125}.
+ {test_heap,3,4}.
{put_tuple2,{x,0},{list,[{y,2},{x,0}]}}.
- {get_tuple_element,{x,4},1,{x,3}}.
{move,{y,3},{x,4}}.
+ {swap,{x,3},{x,2}}.
{swap,{x,1},{x,3}}.
{line,[{location,"couch_key_tree.erl",395}]}.
{call_fun,4}.
@@ -1665,189 +1410,142 @@
{trim,1,3}.
{move,{y,2},{x,0}}.
{line,[{location,"couch_key_tree.erl",396}]}.
- {call,4,{f,102}}.
+ {call,4,{f,123}}.
{move,{y,1},{x,2}}.
{move,{x,0},{x,1}}.
{move,{y,0},{x,3}}.
{move,{y,2},{x,0}}.
- {call_last,4,{f,102},3}.
- {label,105}.
- {test,is_nil,{f,101},[{x,3}]}.
+ {call_last,4,{f,123},3}.
+ {label,126}.
+ {test,is_nil,{f,122},[{x,3}]}.
{move,{x,1},{x,0}}.
return.
-{function, map, 2, 107}.
- {label,106}.
+{function, map, 2, 128}.
+ {label,127}.
{line,[{location,"couch_key_tree.erl",399}]}.
{func_info,{atom,couch_key_tree},{atom,map},2}.
- {label,107}.
- {test,is_nonempty_list,{f,110},[{x,1}]}.
+ {label,128}.
+ {test,is_nonempty_list,{f,131},[{x,1}]}.
{get_list,{x,1},{x,2},{x,3}}.
- {test,is_tuple,{f,106},[{x,2}]}.
- {test,test_arity,{f,106},[{x,2},2]}.
+ {test,is_tuple,{f,127},[{x,2}]}.
+ {test,test_arity,{f,127},[{x,2},2]}.
{allocate,4,4}.
- {init,{y,0}}.
- {move,{x,2},{y,1}}.
{move,{x,3},{y,2}}.
{move,{x,0},{y,3}}.
+ {get_tuple_element,{x,2},0,{y,1}}.
+ {get_tuple_element,{x,2},1,{y,0}}.
{move,{atom,arity},{x,1}}.
{line,[{location,"couch_key_tree.erl",402}]}.
{call_ext,2,{extfunc,erlang,fun_info,2}}.
- {test,is_tagged_tuple,{f,113},[{x,0},2,{atom,arity}]}.
- {get_tuple_element,{x,0},1,{x,1}}.
- {get_tuple_element,{y,1},0,{y,0}}.
- {get_tuple_element,{y,1},1,{y,1}}.
- {select_val,{x,1},
- {f,113},
- {list,[{integer,2},{f,109},{integer,3},{f,108}]}}.
- {label,108}.
+ {test,is_tuple,{f,134},[{x,0}]}.
+ {test,test_arity,{f,134},[{x,0},2]}.
+ {get_tuple_element,{x,0},0,{x,1}}.
+ {get_tuple_element,{x,0},1,{x,2}}.
+ {test,is_eq_exact,{f,134},[{x,1},{atom,arity}]}.
+ {select_val,{x,2},
+ {f,134},
+ {list,[{integer,2},{f,130},{integer,3},{f,129}]}}.
+ {label,129}.
{test_heap,2,0}.
- {put_list,{y,1},nil,{x,2}}.
- {move,{y,0},{x,1}}.
- {kill,{y,1}}.
+ {put_list,{y,0},nil,{x,2}}.
+ {move,{y,1},{x,1}}.
+ {kill,{y,0}}.
{move,{y,3},{x,0}}.
{line,[{location,"couch_key_tree.erl",407}]}.
- {call,3,{f,115}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_cons,
- {t_tuple,3,true,
- #{3 =>
- {t_list,
- {t_tuple,3,true,#{3 => {t_list,any,any}}},
- nil}}},
- nil}}]}}.
- {get_list,{x,0},{y,1},{x,1}}.
- {test,is_nil,{f,111},[{x,1}]}.
+ {call,3,{f,136}}.
+ {test,is_nonempty_list,{f,132},[{x,0}]}.
+ {get_list,{x,0},{y,0},{x,1}}.
+ {test,is_nil,{f,132},[{x,1}]}.
{move,{y,2},{x,1}}.
{move,{y,3},{x,0}}.
{move,{y,0},{y,3}}.
{move,{y,1},{y,2}}.
{trim,2,2}.
{line,[{location,"couch_key_tree.erl",408}]}.
- {call,2,{f,107}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_tuple,3,true,#{3 => {t_list,{t_tuple,0,false,#{}},nil}}}}},
- nil}}]}}.
+ {call,2,{f,128}}.
{test_heap,5,1}.
- {put_tuple2,{x,1},{list,[{y,1},{y,0}]}}.
+ {put_tuple2,{x,1},{list,[{y,0},{y,1}]}}.
{put_list,{x,1},{x,0},{x,0}}.
{deallocate,2}.
return.
- {label,109}.
+ {label,130}.
{move,{y,3},{x,0}}.
- {make_fun2,{f,232},0,0,1}.
+ {make_fun2,{f,261},0,0,1}.
{test_heap,2,1}.
- {put_list,{y,1},nil,{x,2}}.
- {move,{y,0},{x,1}}.
- {kill,{y,1}}.
+ {put_list,{y,0},nil,{x,2}}.
+ {move,{y,1},{x,1}}.
+ {kill,{y,0}}.
{line,[{location,"couch_key_tree.erl",404}]}.
- {call,3,{f,115}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_cons,
- {t_tuple,3,true,
- #{3 =>
- {t_list,
- {t_tuple,3,true,#{3 => {t_list,any,any}}},
- nil}}},
- nil}}]}}.
- {get_list,{x,0},{y,1},{x,1}}.
- {test,is_nil,{f,112},[{x,1}]}.
+ {call,3,{f,136}}.
+ {test,is_nonempty_list,{f,133},[{x,0}]}.
+ {get_list,{x,0},{y,0},{x,1}}.
+ {test,is_nil,{f,133},[{x,1}]}.
{move,{y,2},{x,1}}.
{move,{y,3},{x,0}}.
{move,{y,0},{y,3}}.
{move,{y,1},{y,2}}.
{trim,2,2}.
{line,[{location,"couch_key_tree.erl",405}]}.
- {call,2,{f,107}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_tuple,3,true,#{3 => {t_list,{t_tuple,0,false,#{}},nil}}}}},
- nil}}]}}.
+ {call,2,{f,128}}.
{test_heap,5,1}.
- {put_tuple2,{x,1},{list,[{y,1},{y,0}]}}.
+ {put_tuple2,{x,1},{list,[{y,0},{y,1}]}}.
{put_list,{x,1},{x,0},{x,0}}.
{deallocate,2}.
return.
- {label,110}.
- {test,is_nil,{f,106},[{x,1}]}.
+ {label,131}.
+ {test,is_nil,{f,127},[{x,1}]}.
{move,nil,{x,0}}.
return.
- {label,111}.
+ {label,132}.
{line,[{location,"couch_key_tree.erl",407}]}.
{badmatch,{x,0}}.
- {label,112}.
+ {label,133}.
{line,[{location,"couch_key_tree.erl",404}]}.
{badmatch,{x,0}}.
- {label,113}.
+ {label,134}.
{line,[{location,"couch_key_tree.erl",402}]}.
{case_end,{x,0}}.
-{function, map_simple, 3, 115}.
- {label,114}.
+{function, map_simple, 3, 136}.
+ {label,135}.
{line,[{location,"couch_key_tree.erl",411}]}.
{func_info,{atom,couch_key_tree},{atom,map_simple},3}.
- {label,115}.
- {test,is_nonempty_list,{f,118},[{x,2}]}.
+ {label,136}.
+ {test,is_nonempty_list,{f,139},[{x,2}]}.
{get_list,{x,2},{x,3},{x,4}}.
- {test,is_tuple,{f,114},[{x,3}]}.
- {test,test_arity,{f,114},[{x,3},3]}.
+ {test,is_tuple,{f,135},[{x,3}]}.
+ {test,test_arity,{f,135},[{x,3},3]}.
{allocate,5,5}.
- {init,{y,0}}.
{move,{x,4},{y,2}}.
{move,{x,1},{y,3}}.
{move,{x,0},{y,4}}.
- {get_tuple_element,{x,3},2,{y,1}}.
- {test,is_nil,{f,116},[{y,1}]}.
- {move,{atom,leaf},{x,0}}.
- {jump,{f,117}}.
- {label,116}.
- {move,{atom,branch},{x,0}}.
- {label,117}.
- {test_heap,3,4}.
- {get_tuple_element,{x,3},0,{y,0}}.
- {put_tuple2,{x,1},{list,[{y,3},{y,0}]}}.
- {get_tuple_element,{x,3},1,{x,2}}.
+ {get_tuple_element,{x,3},0,{y,1}}.
+ {get_tuple_element,{x,3},1,{x,0}}.
+ {get_tuple_element,{x,3},2,{y,0}}.
+ {test,is_eq,{f,137},[{y,0},nil]}.
+ {move,{atom,leaf},{x,1}}.
+ {jump,{f,138}}.
+ {label,137}.
+ {move,{atom,branch},{x,1}}.
+ {label,138}.
+ {test_heap,3,2}.
+ {put_tuple2,{x,2},{list,[{y,3},{y,1}]}}.
{move,{y,4},{x,3}}.
- {swap,{x,2},{x,1}}.
- {swap,{x,0},{x,2}}.
+ {swap,{x,1},{x,2}}.
+ {swap,{x,0},{x,1}}.
{line,[{location,"couch_key_tree.erl",414}]}.
{call_fun,3}.
{line,[{location,"couch_key_tree.erl",422}]}.
{gc_bif,'+',{f,0},1,[{y,3},{integer,1}],{x,1}}.
- {move,{y,1},{x,3}}.
- {move,{x,0},{y,1}}.
+ {move,{y,0},{x,3}}.
+ {move,{x,0},{y,0}}.
{move,{y,4},{x,0}}.
{move,{x,3},{x,2}}.
{line,[{location,"couch_key_tree.erl",422}]}.
- {call,3,{f,115}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,3,true,
- #{3 =>
- {t_list,
- {t_tuple,3,true,#{3 => {t_list,any,any}}},
- nil}}},
- nil}}]}}.
+ {call,3,{f,136}}.
{move,{y,2},{x,3}}.
{move,{y,3},{x,2}}.
{swap,{y,4},{x,0}}.
@@ -1857,81 +1555,55 @@
{move,{y,1},{y,2}}.
{trim,2,3}.
{line,[{location,"couch_key_tree.erl",422}]}.
- {call,3,{f,115}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,3,true,
- #{3 =>
- {t_list,
- {t_tuple,3,true,#{3 => {t_list,any,any}}},
- nil}}},
- nil}}]}}.
+ {call,3,{f,136}}.
{test_heap,6,1}.
- {put_tuple2,{x,1},{list,[{y,1},{y,0},{y,2}]}}.
+ {put_tuple2,{x,1},{list,[{y,0},{y,1},{y,2}]}}.
{put_list,{x,1},{x,0},{x,0}}.
{deallocate,3}.
return.
- {label,118}.
- {test,is_nil,{f,114},[{x,2}]}.
+ {label,139}.
+ {test,is_nil,{f,135},[{x,2}]}.
{move,nil,{x,0}}.
return.
-{function, mapfold, 3, 120}.
- {label,119}.
+{function, mapfold, 3, 141}.
+ {label,140}.
{line,[{location,"couch_key_tree.erl",424}]}.
{func_info,{atom,couch_key_tree},{atom,mapfold},3}.
- {label,120}.
- {test,is_nonempty_list,{f,121},[{x,2}]}.
+ {label,141}.
+ {test,is_nonempty_list,{f,142},[{x,2}]}.
{get_list,{x,2},{x,3},{x,4}}.
- {test,is_tuple,{f,119},[{x,3}]}.
- {test,test_arity,{f,119},[{x,3},2]}.
+ {test,is_tuple,{f,140},[{x,3}]}.
+ {test,test_arity,{f,140},[{x,3},2]}.
{allocate_heap,4,2,5}.
{init,{y,0}}.
{move,{x,4},{y,2}}.
{move,{x,0},{y,3}}.
- {get_tuple_element,{x,3},1,{x,0}}.
- {put_list,{x,0},nil,{x,0}}.
{get_tuple_element,{x,3},0,{y,1}}.
+ {get_tuple_element,{x,3},1,{x,0}}.
+ {put_list,{x,0},nil,{x,3}}.
{move,{y,1},{x,2}}.
- {move,{x,0},{x,3}}.
{move,{y,3},{x,0}}.
{line,[{location,"couch_key_tree.erl",427}]}.
- {call,4,{f,124}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 =>
- {t_cons,
- {t_tuple,3,true,
- #{3 => {t_list,{t_tuple,0,false,#{}},nil}}},
- nil}}}}]}}.
+ {call,4,{f,146}}.
+ {test,is_tuple,{f,144},[{x,0}]}.
+ {test,test_arity,{f,144},[{x,0},2]}.
{get_tuple_element,{x,0},0,{x,1}}.
+ {get_tuple_element,{x,0},1,{x,2}}.
+ {test,is_nonempty_list,{f,144},[{x,1}]}.
{get_list,{x,1},{y,0},{x,1}}.
- {test,is_nil,{f,122},[{x,1}]}.
- {get_tuple_element,{x,0},1,{x,1}}.
+ {test,is_nil,{f,144},[{x,1}]}.
+ {move,{x,2},{x,1}}.
{move,{y,2},{x,2}}.
{move,{y,3},{x,0}}.
{move,{y,0},{y,3}}.
{move,{y,1},{y,2}}.
{trim,2,2}.
{line,[{location,"couch_key_tree.erl",428}]}.
- {call,3,{f,120}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 =>
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_tuple,3,true,#{3 => {t_list,any,any}}}}},
- nil}}}}]}}.
+ {call,3,{f,141}}.
+ {test,is_tuple,{f,143},[{x,0}]}.
+ {test,test_arity,{f,143},[{x,0},2]}.
{test_heap,8,1}.
{get_tuple_element,{x,0},0,{x,1}}.
{get_tuple_element,{x,0},1,{x,0}}.
@@ -1940,68 +1612,64 @@
{put_tuple2,{x,0},{list,[{x,1},{x,0}]}}.
{deallocate,2}.
return.
- {label,121}.
- {test,is_nil,{f,119},[{x,2}]}.
+ {label,142}.
+ {test,is_nil,{f,140},[{x,2}]}.
{test_heap,3,2}.
{put_tuple2,{x,0},{list,[nil,{x,1}]}}.
return.
- {label,122}.
+ {label,143}.
+ {line,[{location,"couch_key_tree.erl",428}]}.
+ {badmatch,{x,0}}.
+ {label,144}.
{line,[{location,"couch_key_tree.erl",427}]}.
{badmatch,{x,0}}.
-{function, mapfold_simple, 4, 124}.
- {label,123}.
+{function, mapfold_simple, 4, 146}.
+ {label,145}.
{line,[{location,"couch_key_tree.erl",431}]}.
{func_info,{atom,couch_key_tree},{atom,mapfold_simple},4}.
- {label,124}.
- {test,is_nonempty_list,{f,127},[{x,3}]}.
+ {label,146}.
+ {test,is_nonempty_list,{f,149},[{x,3}]}.
{get_list,{x,3},{x,4},{x,5}}.
- {test,is_tuple,{f,123},[{x,4}]}.
- {test,test_arity,{f,123},[{x,4},3]}.
+ {test,is_tuple,{f,145},[{x,4}]}.
+ {test,test_arity,{f,145},[{x,4},3]}.
{allocate,6,6}.
{init,{y,0}}.
- {init,{y,1}}.
{move,{x,5},{y,3}}.
{move,{x,2},{y,4}}.
{move,{x,0},{y,5}}.
- {get_tuple_element,{x,4},2,{y,2}}.
- {test,is_nil,{f,125},[{y,2}]}.
+ {get_tuple_element,{x,4},0,{y,2}}.
+ {get_tuple_element,{x,4},1,{x,0}}.
+ {get_tuple_element,{x,4},2,{y,1}}.
+ {test,is_eq,{f,147},[{y,1},nil]}.
{move,{atom,leaf},{x,2}}.
- {jump,{f,126}}.
- {label,125}.
+ {jump,{f,148}}.
+ {label,147}.
{move,{atom,branch},{x,2}}.
- {label,126}.
- {test_heap,3,5}.
- {get_tuple_element,{x,4},0,{y,1}}.
- {put_tuple2,{x,0},{list,[{y,4},{y,1}]}}.
- {get_tuple_element,{x,4},1,{x,3}}.
+ {label,148}.
+ {test_heap,3,3}.
+ {put_tuple2,{x,3},{list,[{y,4},{y,2}]}}.
{move,{y,5},{x,4}}.
{swap,{x,1},{x,3}}.
+ {swap,{x,0},{x,1}}.
{line,[{location,"couch_key_tree.erl",434}]}.
{call_fun,4}.
- {test,is_tuple,{f,128},[{x,0}]}.
- {test,test_arity,{f,128},[{x,0},2]}.
+ {test,is_tuple,{f,152},[{x,0}]}.
+ {test,test_arity,{f,152},[{x,0},2]}.
{get_tuple_element,{x,0},0,{y,0}}.
+ {get_tuple_element,{x,0},1,{x,0}}.
{line,[{location,"couch_key_tree.erl",443}]}.
{gc_bif,'+',{f,0},1,[{y,4},{integer,1}],{x,2}}.
- {get_tuple_element,{x,0},1,{x,1}}.
- {move,{y,2},{x,3}}.
- {kill,{y,2}}.
+ {move,{x,0},{x,1}}.
+ {move,{y,1},{x,3}}.
+ {kill,{y,1}}.
{move,{y,5},{x,0}}.
{line,[{location,"couch_key_tree.erl",443}]}.
- {call,4,{f,124}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 =>
- {t_list,
- {t_tuple,3,true,
- #{3 => {t_list,{t_tuple,0,false,#{}},nil}}},
- nil}}}}]}}.
- {get_tuple_element,{x,0},0,{y,2}}.
+ {call,4,{f,146}}.
+ {test,is_tuple,{f,151},[{x,0}]}.
+ {test,test_arity,{f,151},[{x,0},2]}.
+ {get_tuple_element,{x,0},0,{y,1}}.
{get_tuple_element,{x,0},1,{x,1}}.
{move,{y,3},{x,3}}.
{move,{y,4},{x,2}}.
@@ -2011,111 +1679,90 @@
{move,{y,2},{y,3}}.
{trim,3,3}.
{line,[{location,"couch_key_tree.erl",444}]}.
- {call,4,{f,124}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 =>
- {t_list,
- {t_tuple,3,true,
- #{3 => {t_list,{t_tuple,0,false,#{}},nil}}},
- nil}}}}]}}.
+ {call,4,{f,146}}.
+ {test,is_tuple,{f,150},[{x,0}]}.
+ {test,test_arity,{f,150},[{x,0},2]}.
{test_heap,9,1}.
{get_tuple_element,{x,0},0,{x,1}}.
{get_tuple_element,{x,0},1,{x,0}}.
- {put_tuple2,{x,2},{list,[{y,1},{y,2},{y,0}]}}.
+ {put_tuple2,{x,2},{list,[{y,0},{y,2},{y,1}]}}.
{put_list,{x,2},{x,1},{x,1}}.
{put_tuple2,{x,0},{list,[{x,1},{x,0}]}}.
{deallocate,3}.
return.
- {label,127}.
- {test,is_nil,{f,123},[{x,3}]}.
+ {label,149}.
+ {test,is_nil,{f,145},[{x,3}]}.
{test_heap,3,2}.
{put_tuple2,{x,0},{list,[nil,{x,1}]}}.
return.
- {label,128}.
+ {label,150}.
+ {line,[{location,"couch_key_tree.erl",444}]}.
+ {badmatch,{x,0}}.
+ {label,151}.
+ {line,[{location,"couch_key_tree.erl",443}]}.
+ {badmatch,{x,0}}.
+ {label,152}.
{line,[{location,"couch_key_tree.erl",434}]}.
{badmatch,{x,0}}.
-{function, map_leafs, 2, 130}.
- {label,129}.
+{function, map_leafs, 2, 154}.
+ {label,153}.
{line,[{location,"couch_key_tree.erl",447}]}.
{func_info,{atom,couch_key_tree},{atom,map_leafs},2}.
- {label,130}.
- {test,is_nonempty_list,{f,131},[{x,1}]}.
+ {label,154}.
+ {test,is_nonempty_list,{f,155},[{x,1}]}.
{get_list,{x,1},{x,2},{x,3}}.
- {test,is_tuple,{f,129},[{x,2}]}.
- {test,test_arity,{f,129},[{x,2},2]}.
+ {test,is_tuple,{f,153},[{x,2}]}.
+ {test,test_arity,{f,153},[{x,2},2]}.
{allocate_heap,4,2,4}.
{init,{y,0}}.
{move,{x,3},{y,2}}.
{move,{x,0},{y,3}}.
- {get_tuple_element,{x,2},1,{x,0}}.
- {put_list,{x,0},nil,{x,0}}.
{get_tuple_element,{x,2},0,{y,1}}.
+ {get_tuple_element,{x,2},1,{x,0}}.
+ {put_list,{x,0},nil,{x,2}}.
{move,{y,1},{x,1}}.
- {move,{x,0},{x,2}}.
{move,{y,3},{x,0}}.
{line,[{location,"couch_key_tree.erl",450}]}.
- {call,3,{f,134}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_cons,
- {t_tuple,3,true,
- #{3 =>
- {t_list,
- {t_tuple,3,true,#{3 => {t_list,any,any}}},
- nil}}},
- nil}}]}}.
+ {call,3,{f,158}}.
+ {test,is_nonempty_list,{f,156},[{x,0}]}.
{get_list,{x,0},{y,0},{x,1}}.
- {test,is_nil,{f,132},[{x,1}]}.
+ {test,is_nil,{f,156},[{x,1}]}.
{move,{y,2},{x,1}}.
{move,{y,3},{x,0}}.
{move,{y,0},{y,3}}.
{move,{y,1},{y,2}}.
{trim,2,2}.
{line,[{location,"couch_key_tree.erl",451}]}.
- {call,2,{f,130}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_tuple,3,true,#{3 => {t_list,{t_tuple,0,false,#{}},nil}}}}},
- nil}}]}}.
+ {call,2,{f,154}}.
{test_heap,5,1}.
{put_tuple2,{x,1},{list,[{y,0},{y,1}]}}.
{put_list,{x,1},{x,0},{x,0}}.
{deallocate,2}.
return.
- {label,131}.
- {test,is_nil,{f,129},[{x,1}]}.
+ {label,155}.
+ {test,is_nil,{f,153},[{x,1}]}.
{move,nil,{x,0}}.
return.
- {label,132}.
+ {label,156}.
{line,[{location,"couch_key_tree.erl",450}]}.
{badmatch,{x,0}}.
-{function, map_leafs_simple, 3, 134}.
- {label,133}.
+{function, map_leafs_simple, 3, 158}.
+ {label,157}.
{line,[{location,"couch_key_tree.erl",453}]}.
{func_info,{atom,couch_key_tree},{atom,map_leafs_simple},3}.
- {label,134}.
- {test,is_nonempty_list,{f,136},[{x,2}]}.
+ {label,158}.
+ {test,is_nonempty_list,{f,160},[{x,2}]}.
{get_list,{x,2},{x,3},{x,4}}.
- {test,is_tuple,{f,133},[{x,3}]}.
- {test,test_arity,{f,133},[{x,3},3]}.
+ {test,is_tuple,{f,157},[{x,3}]}.
+ {test,test_arity,{f,157},[{x,3},3]}.
{get_tuple_element,{x,3},0,{x,2}}.
{get_tuple_element,{x,3},1,{x,5}}.
{get_tuple_element,{x,3},2,{x,3}}.
- {test,is_nil,{f,135},[{x,3}]}.
+ {test,is_nil,{f,159},[{x,3}]}.
{allocate_heap,4,3,6}.
{move,{x,2},{y,0}}.
{move,{x,4},{y,1}}.
@@ -2134,24 +1781,13 @@
{move,{y,0},{y,2}}.
{trim,2,2}.
{line,[{location,"couch_key_tree.erl",457}]}.
- {call,3,{f,134}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,3,true,
- #{3 =>
- {t_list,
- {t_tuple,3,true,#{3 => {t_list,any,any}}},
- nil}}},
- nil}}]}}.
+ {call,3,{f,158}}.
{test_heap,6,1}.
{put_tuple2,{x,1},{list,[{y,0},{y,1},nil]}}.
{put_list,{x,1},{x,0},{x,0}}.
{deallocate,2}.
return.
- {label,135}.
+ {label,159}.
{line,[{location,"couch_key_tree.erl",459}]}.
{gc_bif,'+',{f,0},6,[{x,1},{integer,1}],{x,6}}.
{allocate,5,7}.
@@ -2163,18 +1799,7 @@
{move,{x,3},{x,2}}.
{move,{x,6},{x,1}}.
{line,[{location,"couch_key_tree.erl",459}]}.
- {call,3,{f,134}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,3,true,
- #{3 =>
- {t_list,
- {t_tuple,3,true,#{3 => {t_list,any,any}}},
- nil}}},
- nil}}]}}.
+ {call,3,{f,158}}.
{move,{y,2},{x,3}}.
{move,{y,3},{x,2}}.
{swap,{y,4},{x,0}}.
@@ -2184,42 +1809,30 @@
{move,{y,1},{y,2}}.
{trim,2,3}.
{line,[{location,"couch_key_tree.erl",459}]}.
- {call,3,{f,134}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,3,true,
- #{3 =>
- {t_list,
- {t_tuple,3,true,#{3 => {t_list,any,any}}},
- nil}}},
- nil}}]}}.
+ {call,3,{f,158}}.
{test_heap,6,1}.
{put_tuple2,{x,1},{list,[{y,1},{y,0},{y,2}]}}.
{put_list,{x,1},{x,0},{x,0}}.
{deallocate,3}.
return.
- {label,136}.
- {test,is_nil,{f,133},[{x,2}]}.
+ {label,160}.
+ {test,is_nil,{f,157},[{x,2}]}.
{move,nil,{x,0}}.
return.
-{function, stem, 2, 138}.
- {label,137}.
+{function, stem, 2, 162}.
+ {label,161}.
{line,[{location,"couch_key_tree.erl",461}]}.
{func_info,{atom,couch_key_tree},{atom,stem},2}.
- {label,138}.
+ {label,162}.
{allocate,4,2}.
{init,{y,0}}.
{move,{x,1},{y,1}}.
{move,{x,0},{y,2}}.
- {'try',{y,3},{f,139}}.
+ {'try',{y,3},{f,163}}.
{move,{x,1},{x,0}}.
- {make_fun2,{f,229},0,0,1}.
- {'%',{var_info,{x,0},[{fun_type,{t_tuple,2,true,#{}}}]}}.
+ {make_fun2,{f,257},0,0,1}.
{move,{x,0},{y,0}}.
{line,[{location,"couch_key_tree.erl",468}]}.
{call_ext,0,{extfunc,sets,new,0}}.
@@ -2230,8 +1843,8 @@
{kill,{y,0}}.
{line,[{location,"couch_key_tree.erl",463}]}.
{call_ext,3,{extfunc,lists,foldl,3}}.
- {test,is_tuple,{f,141},[{x,0}]}.
- {test,test_arity,{f,141},[{x,0},2]}.
+ {test,is_tuple,{f,165},[{x,0}]}.
+ {test,test_arity,{f,165},[{x,0},2]}.
{get_tuple_element,{x,0},0,{x,1}}.
{get_tuple_element,{x,0},1,{y,0}}.
{move,{x,1},{x,0}}.
@@ -2250,27 +1863,27 @@
{try_end,{y,3}}.
{deallocate,4}.
return.
- {label,139}.
+ {label,163}.
{try_case,{y,3}}.
- {test,is_eq_exact,{f,140},[{x,0},{atom,throw}]}.
- {test,is_eq_exact,{f,140},[{x,1},{atom,dupe_keys}]}.
+ {test,is_eq_exact,{f,164},[{x,0},{atom,throw}]}.
+ {test,is_eq_exact,{f,164},[{x,1},{atom,dupe_keys}]}.
{move,{y,1},{x,1}}.
{move,{y,2},{x,0}}.
- {call_last,2,{f,160},4}.
- {label,140}.
+ {call_last,2,{f,184},4}.
+ {label,164}.
{bif,raise,{f,0},[{x,2},{x,1}],{x,0}}.
- {label,141}.
+ {label,165}.
{line,[{scope,[2]},{location,"couch_key_tree.erl",463}]}.
{badmatch,{x,0}}.
-{function, stem_tree, 3, 143}.
- {label,142}.
+{function, stem_tree, 3, 167}.
+ {label,166}.
{line,[{location,"couch_key_tree.erl",478}]}.
{func_info,{atom,couch_key_tree},{atom,stem_tree},3}.
- {label,143}.
- {test,is_tuple,{f,142},[{x,0}]}.
- {test,test_arity,{f,142},[{x,0},2]}.
+ {label,167}.
+ {test,is_tuple,{f,166},[{x,0}]}.
+ {test,test_arity,{f,166},[{x,0},2]}.
{allocate,1,3}.
{get_tuple_element,{x,0},0,{y,0}}.
{get_tuple_element,{x,0},1,{x,0}}.
@@ -2279,10 +1892,10 @@
{move,{x,0},{x,1}}.
{move,{y,0},{x,0}}.
{line,[{location,"couch_key_tree.erl",479}]}.
- {call,4,{f,148}}.
- {'%',{var_info,{x,0},[{type,{t_tuple,3,false,#{2 => number}}}]}}.
- {select_tuple_arity,{x,0},{f,146},{list,[3,{f,145},4,{f,144}]}}.
- {label,144}.
+ {call,4,{f,172}}.
+ {test,is_tuple,{f,170},[{x,0}]}.
+ {select_tuple_arity,{x,0},{f,170},{list,[3,{f,169},4,{f,168}]}}.
+ {label,168}.
{test_heap,8,1}.
{get_tuple_element,{x,0},0,{x,1}}.
{get_tuple_element,{x,0},2,{x,2}}.
@@ -2292,100 +1905,98 @@
{put_tuple2,{x,0},{list,[{x,1},{x,0}]}}.
{deallocate,1}.
return.
- {label,145}.
+ {label,169}.
{test_heap,3,1}.
{get_tuple_element,{x,0},0,{x,1}}.
{get_tuple_element,{x,0},2,{x,0}}.
{put_tuple2,{x,0},{list,[{x,1},{x,0}]}}.
{deallocate,1}.
return.
- {label,146}.
+ {label,170}.
{line,[{location,"couch_key_tree.erl",479}]}.
{case_end,{x,0}}.
-{function, stem_tree, 4, 148}.
- {label,147}.
+{function, stem_tree, 4, 172}.
+ {label,171}.
{line,[{location,"couch_key_tree.erl",486}]}.
{func_info,{atom,couch_key_tree},{atom,stem_tree},4}.
- {label,148}.
- {test,is_tuple,{f,147},[{x,1}]}.
- {test,test_arity,{f,147},[{x,1},3]}.
+ {label,172}.
+ {test,is_tuple,{f,171},[{x,1}]}.
+ {test,test_arity,{f,171},[{x,1},3]}.
{get_tuple_element,{x,1},0,{x,4}}.
- {get_tuple_element,{x,1},2,{x,5}}.
- {test,is_nil,{f,149},[{x,5}]}.
+ {get_tuple_element,{x,1},1,{x,5}}.
+ {get_tuple_element,{x,1},2,{x,6}}.
+ {test,is_nil,{f,173},[{x,6}]}.
{allocate,2,5}.
{move,{x,2},{y,0}}.
{move,{x,1},{y,1}}.
{move,{x,3},{x,1}}.
{move,{x,4},{x,0}}.
{line,[{location,"couch_key_tree.erl",487}]}.
- {call,2,{f,155}}.
+ {call,2,{f,179}}.
{line,[{location,"couch_key_tree.erl",487}]}.
{gc_bif,'-',{f,0},1,[{y,0},{integer,1}],{x,1}}.
{test_heap,5,2}.
{put_tuple2,{x,0},{list,[{x,0},{x,1},{y,1},nil]}}.
{deallocate,2}.
return.
- {label,149}.
- {allocate,7,6}.
+ {label,173}.
+ {allocate,7,7}.
{init,{y,0}}.
{init,{y,1}}.
{move,{x,4},{y,2}}.
{move,{x,5},{y,3}}.
- {move,{x,2},{y,4}}.
- {move,{x,1},{y,5}}.
+ {move,{x,6},{y,4}}.
+ {move,{x,2},{y,5}}.
{move,{x,0},{y,6}}.
{move,{x,3},{x,1}}.
{move,{x,4},{x,0}}.
{line,[{location,"couch_key_tree.erl",489}]}.
- {call,2,{f,155}}.
- {move,{y,4},{x,2}}.
- {move,{x,0},{y,4}}.
+ {call,2,{f,179}}.
+ {move,{y,5},{x,2}}.
+ {move,{x,0},{y,5}}.
{move,{y,6},{x,0}}.
{move,{x,2},{x,1}}.
- {make_fun2,{f,223},0,0,2}.
- {'%',{var_info,{x,0},[{fun_type,{t_tuple,4,true,#{}}}]}}.
+ {make_fun2,{f,251},0,0,2}.
{test_heap,5,1}.
- {put_tuple2,{x,1},{list,[{y,4},{integer,-1},nil,nil]}}.
- {move,{y,3},{x,2}}.
- {kill,{y,3}}.
+ {put_tuple2,{x,1},{list,[{y,5},{integer,-1},nil,nil]}}.
+ {move,{y,4},{x,2}}.
{kill,{y,4}}.
+ {kill,{y,5}}.
{line,[{location,"couch_key_tree.erl",490}]}.
{call_ext,3,{extfunc,lists,foldl,3}}.
- {test,is_tuple,{f,153},[{x,0}]}.
- {test,test_arity,{f,153},[{x,0},4]}.
- {get_tuple_element,{x,0},0,{y,4}}.
- {get_tuple_element,{x,0},1,{y,3}}.
+ {test,is_tuple,{f,177},[{x,0}]}.
+ {test,test_arity,{f,177},[{x,0},4]}.
+ {get_tuple_element,{x,0},0,{y,5}}.
+ {get_tuple_element,{x,0},1,{y,4}}.
{get_tuple_element,{x,0},2,{y,1}}.
{get_tuple_element,{x,0},3,{y,0}}.
- {test,is_lt,{f,150},[{integer,0},{y,3}]}.
- {gc_bif,length,{f,150},0,[{y,1}],{x,0}}.
- {test,is_lt,{f,150},[{integer,0},{x,0}]}.
+ {test,is_lt,{f,174},[{integer,0},{y,4}]}.
+ {gc_bif,length,{f,174},0,[{y,1}],{x,0}}.
+ {test,is_lt,{f,174},[{integer,0},{x,0}]}.
{move,{y,1},{x,0}}.
{move,{y,0},{y,6}}.
{trim,2,5}.
{line,[{location,"couch_key_tree.erl",511}]}.
{call_ext,1,{extfunc,lists,reverse,1}}.
{test_heap,4,1}.
- {get_tuple_element,{y,3},1,{x,1}}.
- {put_tuple2,{x,0},{list,[{y,0},{x,1},{x,0}]}}.
+ {put_tuple2,{x,0},{list,[{y,0},{y,1},{x,0}]}}.
{line,[{location,"couch_key_tree.erl",512}]}.
- {gc_bif,'-',{f,0},1,[{y,1},{integer,1}],{x,1}}.
+ {gc_bif,'-',{f,0},1,[{y,2},{integer,1}],{x,1}}.
{test_heap,5,2}.
- {put_tuple2,{x,0},{list,[{y,2},{x,1},{x,0},{y,4}]}}.
+ {put_tuple2,{x,0},{list,[{y,3},{x,1},{x,0},{y,4}]}}.
{deallocate,5}.
return.
- {label,150}.
- {test,is_eq_exact,{f,151},[{y,3},{integer,0}]}.
- {gc_bif,length,{f,151},0,[{y,1}],{x,0}}.
- {test,is_lt,{f,151},[{integer,0},{x,0}]}.
+ {label,174}.
+ {test,is_eq_exact,{f,175},[{y,4},{integer,0}]}.
+ {gc_bif,length,{f,175},0,[{y,1}],{x,0}}.
+ {test,is_lt,{f,175},[{integer,0},{x,0}]}.
{move,{y,6},{x,0}}.
- {make_fun2,{f,221},0,0,1}.
- {'%',{var_info,{x,0},[{fun_type,{t_tuple,2,true,#{1 => number}}}]}}.
+ {make_fun2,{f,249},0,0,1}.
{move,{x,0},{y,6}}.
{move,{y,1},{x,0}}.
- {move,{y,0},{y,5}}.
+ {move,{y,0},{y,4}}.
{trim,4,3}.
{line,[{location,"couch_key_tree.erl",518}]}.
{call_ext,1,{extfunc,lists,reverse,1}}.
@@ -2395,84 +2006,71 @@
{trim,1,2}.
{line,[{location,"couch_key_tree.erl",514}]}.
{call_ext,2,{extfunc,lists,map,2}}.
- {move,{y,0},{x,1}}.
- {trim,1,1}.
+ {move,{y,1},{x,1}}.
+ {kill,{y,1}}.
{line,[{location,"couch_key_tree.erl",520}]}.
{call_ext,2,{extfunc,erlang,'++',2}}.
{test_heap,4,1}.
{put_tuple2,{x,0},{list,[{y,0},{integer,-1},{x,0}]}}.
- {deallocate,1}.
+ {deallocate,2}.
return.
- {label,151}.
- {test,is_lt,{f,152},[{y,3},{integer,0}]}.
- {gc_bif,length,{f,152},0,[{y,1}],{x,0}}.
- {test,is_eq_exact,{f,152},[{x,0},{integer,0}]}.
+ {label,175}.
+ {test,is_lt,{f,176},[{y,4},{integer,0}]}.
+ {gc_bif,length,{f,176},0,[{y,1}],{x,0}}.
+ {test,is_eq,{f,176},[{x,0},{integer,0}]}.
{line,[{location,"couch_key_tree.erl",522}]}.
- {gc_bif,'-',{f,0},0,[{y,3},{integer,1}],{x,0}}.
+ {gc_bif,'-',{f,0},0,[{y,4},{integer,1}],{x,0}}.
{test_heap,4,1}.
- {put_tuple2,{x,0},{list,[{y,4},{x,0},{y,0}]}}.
+ {put_tuple2,{x,0},{list,[{y,5},{x,0},{y,0}]}}.
{deallocate,7}.
return.
- {label,152}.
+ {label,176}.
{line,[{location,"couch_key_tree.erl",509}]}.
- {case_end,{y,3}}.
- {label,153}.
+ {case_end,{y,4}}.
+ {label,177}.
{line,[{location,"couch_key_tree.erl",508}]}.
{badmatch,{x,0}}.
-{function, check_key, 2, 155}.
- {label,154}.
+{function, check_key, 2, 179}.
+ {label,178}.
{line,[{location,"couch_key_tree.erl",525}]}.
{func_info,{atom,couch_key_tree},{atom,check_key},2}.
- {label,155}.
+ {label,179}.
{allocate,2,2}.
{move,{x,1},{y,0}}.
{move,{x,0},{y,1}}.
{line,[{location,"couch_key_tree.erl",526}]}.
{call_ext,2,{extfunc,sets,is_element,2}}.
{select_val,{x,0},
- {f,158},
- {list,[{atom,false},{f,157},{atom,true},{f,156}]}}.
- {label,156}.
+ {f,182},
+ {list,[{atom,false},{f,181},{atom,true},{f,180}]}}.
+ {label,180}.
{move,{atom,dupe_keys},{x,0}}.
{line,[{location,"couch_key_tree.erl",528}]}.
{call_ext_last,1,{extfunc,erlang,throw,1},2}.
- {label,157}.
+ {label,181}.
{move,{y,0},{x,1}}.
{move,{y,1},{x,0}}.
{line,[{location,"couch_key_tree.erl",530}]}.
{call_ext_last,2,{extfunc,sets,add_element,2},2}.
- {label,158}.
+ {label,182}.
{line,[{location,"couch_key_tree.erl",526}]}.
{case_end,{x,0}}.
-{function, repair_tree, 2, 160}.
- {label,159}.
+{function, repair_tree, 2, 184}.
+ {label,183}.
{line,[{location,"couch_key_tree.erl",533}]}.
{func_info,{atom,couch_key_tree},{atom,repair_tree},2}.
- {label,160}.
+ {label,184}.
{allocate,1,2}.
{move,{x,0},{y,0}}.
{move,{x,1},{x,0}}.
- {make_fun2,{f,218},0,0,1}.
- {'%',
- {var_info,
- {x,0},
- [{fun_type,
- {t_tuple,2,true,#{1 => number,2 => {t_list,any,nil}}}}]}}.
+ {make_fun2,{f,246},0,0,1}.
{swap,{y,0},{x,0}}.
{line,[{location,"couch_key_tree.erl",541}]}.
- {call,1,{f,74}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_cons,{t_tuple,2,true,#{}},nil}}},
- nil}}]}}.
+ {call,1,{f,95}}.
{move,{x,0},{x,1}}.
{move,{y,0},{x,0}}.
{kill,{y,0}}.
@@ -2481,95 +2079,91 @@
{line,[{location,"couch_key_tree.erl",535}]}.
{call_ext,1,{extfunc,lists,sort,1}}.
{move,{x,0},{y,0}}.
- {make_fun2,{f,213},0,0,0}.
- {'%',{var_info,{x,0},[{fun_type,{t_list,any,nil}}]}}.
+ {make_fun2,{f,240},0,0,0}.
{move,{y,0},{x,2}}.
{move,nil,{x,1}}.
{line,[{location,"couch_key_tree.erl",546}]}.
{call_ext_last,3,{extfunc,lists,foldl,3},1}.
-{function, value_pref, 2, 162}.
- {label,161}.
+{function, value_pref, 2, 186}.
+ {label,185}.
{line,[{location,"couch_key_tree.erl",558}]}.
{func_info,{atom,couch_key_tree},{atom,value_pref},2}.
- {label,162}.
- {test,is_tuple,{f,164},[{x,0}]}.
- {test,test_arity,{f,163},[{x,0},3]}.
- return.
- {label,163}.
- {test,test_arity,{f,164},[{x,0},4]}.
+ {label,186}.
+ {test,is_tuple,{f,189},[{x,0}]}.
+ {bif,tuple_size,{f,189},[{x,0}],{x,2}}.
+ {test,is_eq,{f,187},[{x,2},{integer,3}]}.
+ {move,{atom,true},{x,2}}.
+ {jump,{f,188}}.
+ {label,187}.
+ {bif,tuple_size,{f,189},[{x,0}],{x,2}}.
+ {bif,'==',{f,0},[{x,2},{integer,4}],{x,2}}.
+ {label,188}.
+ {test,is_eq_exact,{f,189},[{x,2},{atom,true}]}.
return.
- {label,164}.
- {test,is_tuple,{f,166},[{x,1}]}.
- {test,test_arity,{f,165},[{x,1},3]}.
- {jump,{f,167}}.
- {label,165}.
- {test,test_arity,{f,166},[{x,1},4]}.
- {jump,{f,167}}.
- {label,166}.
- {test,is_nil,{f,168},[{x,0}]}.
- {label,167}.
+ {label,189}.
+ {test,is_tuple,{f,192},[{x,1}]}.
+ {bif,tuple_size,{f,192},[{x,1}],{x,2}}.
+ {test,is_eq,{f,190},[{x,2},{integer,3}]}.
+ {move,{atom,true},{x,2}}.
+ {jump,{f,191}}.
+ {label,190}.
+ {bif,tuple_size,{f,192},[{x,1}],{x,2}}.
+ {bif,'==',{f,0},[{x,2},{integer,4}],{x,2}}.
+ {label,191}.
+ {test,is_ne_exact,{f,193},[{x,2},{atom,true}]}.
+ {label,192}.
+ {test,is_nil,{f,194},[{x,0}]}.
+ {label,193}.
{move,{x,1},{x,0}}.
return.
- {label,168}.
+ {label,194}.
+ {bif,'=:=',{f,0},[{x,1},nil],{x,1}}.
return.
-{function, gen_and_stem, 0, 170}.
- {label,169}.
+{function, gen_and_stem, 0, 196}.
+ {label,195}.
{line,[{location,"couch_key_tree.erl",579}]}.
{func_info,{atom,couch_key_tree},{atom,gen_and_stem},0}.
- {label,170}.
+ {label,196}.
{move,{float,0.0008},{x,1}}.
{move,{literal,{1647,841737,351137}},{x,2}}.
{move,{integer,7000},{x,0}}.
- {call_only,3,{f,172}}.
+ {call_only,3,{f,198}}.
-{function, gen_and_stem, 3, 172}.
- {label,171}.
+{function, gen_and_stem, 3, 198}.
+ {label,197}.
{line,[{location,"couch_key_tree.erl",582}]}.
{func_info,{atom,couch_key_tree},{atom,gen_and_stem},3}.
- {label,172}.
+ {label,198}.
{allocate_zero,4,3}.
{line,[{location,"couch_key_tree.erl",583}]}.
- {call,3,{f,176}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{2 =>
- {t_cons,
- {t_tuple,2,true,
- #{1 => {t_integer,{1,1}},
- 2 =>
- {t_tuple,3,true,#{2 => {t_atom,[x]},3 => {t_list,any,any}}}}},
- nil}}}}]}}.
- {move,{x,0},{y,3}}.
+ {call,3,{f,203}}.
+ {test,is_tuple,{f,199},[{x,0}]}.
+ {test,test_arity,{f,199},[{x,0},2]}.
+ {get_tuple_element,{x,0},1,{y,3}}.
{line,[{location,"couch_key_tree.erl",584}]}.
{call_ext,0,{extfunc,erlang,garbage_collect,0}}.
{bif,self,{f,0},[],{x,0}}.
{move,{integer,500},{x,1}}.
{line,[{location,"couch_key_tree.erl",586}]}.
- {call,2,{f,199}}.
+ {call,2,{f,226}}.
{move,{x,0},{y,2}}.
{line,[{location,"couch_key_tree.erl",587}]}.
{call_ext,0,{extfunc,erlang,monotonic_time,0}}.
- {get_tuple_element,{y,3},1,{x,1}}.
- {move,{x,0},{y,3}}.
- {move,{x,1},{x,0}}.
+ {swap,{y,3},{x,0}}.
{move,{integer,1000},{x,1}}.
{line,[{location,"couch_key_tree.erl",589}]}.
- {call,2,{f,138}}.
- {'%',{var_info,{x,0},[{type,{t_list,any,nil}}]}}.
+ {call,2,{f,162}}.
{line,[{location,"couch_key_tree.erl",591}]}.
{call_ext,0,{extfunc,erlang,monotonic_time,0}}.
{move,{x,0},{y,1}}.
{move,{y,2},{x,0}}.
{line,[{location,"couch_key_tree.erl",592}]}.
- {call,1,{f,194}}.
+ {call,1,{f,221}}.
{move,{x,0},{y,0}}.
{line,[{location,"couch_key_tree.erl",594}]}.
{call_ext,0,{extfunc,erlang,garbage_collect,0}}.
@@ -2587,29 +2181,32 @@
{move,{y,1},{y,2}}.
{trim,2,1}.
{line,[{location,"couch_key_tree.erl",598}]}.
- {call,2,{f,189}}.
+ {call,2,{f,216}}.
{test_heap,3,1}.
{put_tuple2,{x,0},{list,[{x,0},{y,0}]}}.
{deallocate,1}.
return.
+ {label,199}.
+ {line,[{location,"couch_key_tree.erl",583}]}.
+ {badmatch,{x,0}}.
-{function, gen, 0, 174}.
- {label,173}.
+{function, gen, 0, 201}.
+ {label,200}.
{line,[{location,"couch_key_tree.erl",601}]}.
{func_info,{atom,couch_key_tree},{atom,gen},0}.
- {label,174}.
+ {label,201}.
{move,{float,0.0008},{x,1}}.
{move,{literal,{1647,841737,351137}},{x,2}}.
{move,{integer,7000},{x,0}}.
- {call_only,3,{f,176}}.
+ {call_only,3,{f,203}}.
-{function, gen, 3, 176}.
- {label,175}.
+{function, gen, 3, 203}.
+ {label,202}.
{line,[{location,"couch_key_tree.erl",604}]}.
{func_info,{atom,couch_key_tree},{atom,gen},3}.
- {label,176}.
+ {label,203}.
{allocate,3,3}.
{move,{x,2},{y,0}}.
{move,{x,1},{y,1}}.
@@ -2623,19 +2220,7 @@
{move,{y,0},{y,2}}.
{trim,2,1}.
{line,[{location,"couch_key_tree.erl",606}]}.
- {call,2,{f,183}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,3,true,
- #{2 => {t_atom,[x]},
- 3 =>
- {t_list,
- {t_tuple,3,true,
- #{2 => {t_atom,[x]},
- 3 => {t_list,{t_tuple,0,false,#{}},nil}}},
- nil}}}}]}}.
+ {call,2,{f,210}}.
{test_heap,8,1}.
{put_tuple2,{x,0},{list,[{integer,1},{x,0}]}}.
{put_list,{x,0},nil,{x,0}}.
@@ -2644,11 +2229,11 @@
return.
-{function, save, 2, 178}.
- {label,177}.
+{function, save, 2, 205}.
+ {label,204}.
{line,[{location,"couch_key_tree.erl",608}]}.
{func_info,{atom,couch_key_tree},{atom,save},2}.
- {label,178}.
+ {label,205}.
{allocate,1,2}.
{move,{x,0},{y,0}}.
{move,{x,1},{x,0}}.
@@ -2659,46 +2244,50 @@
{call_ext_last,2,{extfunc,file,write_file,2},1}.
-{function, load, 1, 180}.
- {label,179}.
+{function, load, 1, 207}.
+ {label,206}.
{line,[{location,"couch_key_tree.erl",611}]}.
{func_info,{atom,couch_key_tree},{atom,load},1}.
- {label,180}.
+ {label,207}.
{allocate,0,1}.
{line,[{location,"couch_key_tree.erl",612}]}.
{call_ext,1,{extfunc,file,read_file,1}}.
- {test,is_tagged_tuple,{f,181},[{x,0},2,{atom,ok}]}.
- {get_tuple_element,{x,0},1,{x,0}}.
+ {test,is_tuple,{f,208},[{x,0}]}.
+ {test,test_arity,{f,208},[{x,0},2]}.
+ {get_tuple_element,{x,0},0,{x,1}}.
+ {get_tuple_element,{x,0},1,{x,2}}.
+ {test,is_eq_exact,{f,208},[{x,1},{atom,ok}]}.
+ {move,{x,2},{x,0}}.
{line,[{location,"couch_key_tree.erl",613}]}.
{call_ext_last,1,{extfunc,erlang,binary_to_term,1},0}.
- {label,181}.
+ {label,208}.
{line,[{location,"couch_key_tree.erl",612}]}.
{badmatch,{x,0}}.
-{function, revnode, 2, 183}.
- {label,182}.
+{function, revnode, 2, 210}.
+ {label,209}.
{line,[{location,"couch_key_tree.erl",615}]}.
{func_info,{atom,couch_key_tree},{atom,revnode},2}.
- {label,183}.
- {test,is_eq_exact,{f,184},[{x,0},{integer,0}]}.
+ {label,210}.
+ {test,is_eq_exact,{f,211},[{x,0},{integer,0}]}.
{allocate,0,0}.
{line,[{location,"couch_key_tree.erl",616}]}.
- {call,0,{f,187}}.
+ {call,0,{f,214}}.
{test_heap,4,1}.
{put_tuple2,{x,0},{list,[{x,0},{atom,x},nil]}}.
{deallocate,0}.
return.
- {label,184}.
+ {label,211}.
{allocate,3,2}.
{init,{y,0}}.
{move,{x,1},{y,1}}.
{move,{x,0},{y,2}}.
{line,[{location,"couch_key_tree.erl",618}]}.
{call_ext,0,{extfunc,rand,uniform,0}}.
- {test,is_lt,{f,185},[{x,0},{y,1}]}.
+ {test,is_lt,{f,212},[{x,0},{y,1}]}.
{line,[{location,"couch_key_tree.erl",620}]}.
- {call,0,{f,187}}.
+ {call,0,{f,214}}.
{line,[{location,"couch_key_tree.erl",621}]}.
{gc_bif,'-',{f,0},1,[{y,2},{integer,1}],{x,1}}.
{move,{x,0},{y,0}}.
@@ -2706,19 +2295,7 @@
{move,{x,1},{x,0}}.
{move,{x,2},{x,1}}.
{line,[{location,"couch_key_tree.erl",621}]}.
- {call,2,{f,183}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,3,true,
- #{2 => {t_atom,[x]},
- 3 =>
- {t_list,
- {t_tuple,3,true,
- #{2 => {t_atom,[x]},
- 3 => {t_list,{t_tuple,0,false,#{}},nil}}},
- nil}}}}]}}.
+ {call,2,{f,210}}.
{line,[{location,"couch_key_tree.erl",622}]}.
{gc_bif,'-',{f,0},1,[{y,2},{integer,1}],{x,1}}.
{move,{x,0},{y,2}}.
@@ -2728,28 +2305,16 @@
{move,{y,0},{y,1}}.
{trim,1,2}.
{line,[{location,"couch_key_tree.erl",622}]}.
- {call,2,{f,183}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,3,true,
- #{2 => {t_atom,[x]},
- 3 =>
- {t_list,
- {t_tuple,3,true,
- #{2 => {t_atom,[x]},
- 3 => {t_list,{t_tuple,0,false,#{}},nil}}},
- nil}}}}]}}.
+ {call,2,{f,210}}.
{test_heap,8,1}.
{put_list,{x,0},nil,{x,0}}.
{put_list,{y,1},{x,0},{x,0}}.
{put_tuple2,{x,0},{list,[{y,0},{atom,x},{x,0}]}}.
{deallocate,2}.
return.
- {label,185}.
+ {label,212}.
{line,[{location,"couch_key_tree.erl",625}]}.
- {call,0,{f,187}}.
+ {call,0,{f,214}}.
{line,[{location,"couch_key_tree.erl",625}]}.
{gc_bif,'-',{f,0},1,[{y,2},{integer,1}],{x,1}}.
{move,{x,0},{y,2}}.
@@ -2758,19 +2323,7 @@
{move,{x,2},{x,1}}.
{trim,2,1}.
{line,[{location,"couch_key_tree.erl",625}]}.
- {call,2,{f,183}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,3,true,
- #{2 => {t_atom,[x]},
- 3 =>
- {t_list,
- {t_tuple,3,true,
- #{2 => {t_atom,[x]},
- 3 => {t_list,{t_tuple,0,false,#{}},nil}}},
- nil}}}}]}}.
+ {call,2,{f,210}}.
{test_heap,6,1}.
{put_list,{x,0},nil,{x,0}}.
{put_tuple2,{x,0},{list,[{y,0},{atom,x},{x,0}]}}.
@@ -2778,21 +2331,21 @@
return.
-{function, rev, 0, 187}.
- {label,186}.
+{function, rev, 0, 214}.
+ {label,213}.
{line,[{location,"couch_key_tree.erl",628}]}.
{func_info,{atom,couch_key_tree},{atom,rev},0}.
- {label,187}.
+ {label,214}.
{move,{integer,16},{x,0}}.
{line,[{location,"couch_key_tree.erl",629}]}.
{call_ext_only,1,{extfunc,crypto,strong_rand_bytes,1}}.
-{function, dt, 2, 189}.
- {label,188}.
+{function, dt, 2, 216}.
+ {label,215}.
{line,[{location,"couch_key_tree.erl",631}]}.
{func_info,{atom,couch_key_tree},{atom,dt},2}.
- {label,189}.
+ {label,216}.
{line,[{location,"couch_key_tree.erl",632}]}.
{gc_bif,'-',{f,0},2,[{x,0},{x,1}],{x,0}}.
{move,{atom,second},{x,2}}.
@@ -2801,199 +2354,193 @@
{call_ext_only,3,{extfunc,erlang,convert_time_unit,3}}.
-{function, mem_mb, 1, 191}.
- {label,190}.
+{function, mem_mb, 1, 218}.
+ {label,217}.
{line,[{location,"couch_key_tree.erl",634}]}.
{func_info,{atom,couch_key_tree},{atom,mem_mb},1}.
- {label,191}.
+ {label,218}.
{allocate,0,1}.
{move,{atom,memory},{x,1}}.
{line,[{location,"couch_key_tree.erl",635}]}.
{call_ext,2,{extfunc,erlang,process_info,2}}.
- {test,is_tagged_tuple,{f,192},[{x,0},2,{atom,memory}]}.
- {get_tuple_element,{x,0},1,{x,0}}.
+ {test,is_tuple,{f,219},[{x,0}]}.
+ {test,test_arity,{f,219},[{x,0},2]}.
+ {get_tuple_element,{x,0},0,{x,1}}.
+ {get_tuple_element,{x,0},1,{x,2}}.
+ {test,is_eq_exact,{f,219},[{x,1},{atom,memory}]}.
{line,[{location,"couch_key_tree.erl",636}]}.
- {gc_bif,'*',{f,0},1,[{x,0},{integer,8}],{x,0}}.
- fclearerror.
+ {gc_bif,'*',{f,0},3,[{x,2},{integer,8}],{x,0}}.
{line,[{location,"couch_key_tree.erl",637}]}.
- {fconv,{x,0},{fr,0}}.
- {fmove,{float,1048576.0},{fr,1}}.
- {line,[{location,"couch_key_tree.erl",637}]}.
- {bif,fdiv,{f,0},[{fr,0},{fr,1}],{fr,0}}.
- {fcheckerror,{f,0}}.
- {test_heap,{alloc,[{words,0},{floats,1}]},0}.
- {fmove,{fr,0},{x,0}}.
+ {gc_bif,'/',{f,0},1,[{x,0},{integer,1048576}],{x,0}}.
{deallocate,0}.
return.
- {label,192}.
+ {label,219}.
{line,[{location,"couch_key_tree.erl",635}]}.
{badmatch,{x,0}}.
-{function, get_max_mem, 1, 194}.
- {label,193}.
+{function, get_max_mem, 1, 221}.
+ {label,220}.
{line,[{location,"couch_key_tree.erl",639}]}.
{func_info,{atom,couch_key_tree},{atom,get_max_mem},1}.
- {label,194}.
+ {label,221}.
{allocate_heap,0,3,1}.
{bif,self,{f,0},[],{x,1}}.
{put_tuple2,{x,1},{list,[{atom,get_mem},{x,1}]}}.
{line,[{location,"couch_key_tree.erl",640}]}.
send.
- {label,195}.
- {loop_rec,{f,197},{x,0}}.
- {test,is_tagged_tuple,{f,196},[{x,0},2,{atom,mem_max}]}.
+ {label,222}.
+ {loop_rec,{f,224},{x,0}}.
+ {test,is_tuple,{f,223},[{x,0}]}.
+ {test,test_arity,{f,223},[{x,0},2]}.
+ {get_tuple_element,{x,0},0,{x,1}}.
{get_tuple_element,{x,0},1,{x,0}}.
+ {test,is_eq_exact,{f,223},[{x,1},{atom,mem_max}]}.
remove_message.
{deallocate,0}.
return.
- {label,196}.
- {loop_rec_end,{f,195}}.
- {label,197}.
- {wait,{f,195}}.
+ {label,223}.
+ {loop_rec_end,{f,222}}.
+ {label,224}.
+ {wait,{f,222}}.
-{function, spawn_mem_sampler, 2, 199}.
- {label,198}.
+{function, spawn_mem_sampler, 2, 226}.
+ {label,225}.
{line,[{location,"couch_key_tree.erl",643}]}.
{func_info,{atom,couch_key_tree},{atom,spawn_mem_sampler},2}.
- {label,199}.
- {'%',{var_info,{x,1},[{type,{t_integer,{500,500}}}]}}.
- {make_fun2,{f,211},0,0,2}.
- {'%',{var_info,{x,0},[{fun_type,none}]}}.
+ {label,226}.
+ {make_fun2,{f,238},0,0,2}.
{line,[{location,"couch_key_tree.erl",644}]}.
{call_ext_only,1,{extfunc,erlang,spawn_link,1}}.
-{function, mem_sampler, 3, 201}.
- {label,200}.
+{function, mem_sampler, 3, 228}.
+ {label,227}.
{line,[{location,"couch_key_tree.erl",646}]}.
{func_info,{atom,couch_key_tree},{atom,mem_sampler},3}.
- {label,201}.
- {'%',{var_info,{x,1},[{type,{t_integer,{500,500}}}]}}.
- {allocate,2,3}.
+ {label,228}.
+ {allocate,3,3}.
{move,{x,2},{y,0}}.
- {move,{x,0},{y,1}}.
- {move,{integer,500},{x,0}}.
+ {move,{x,1},{y,1}}.
+ {move,{x,0},{y,2}}.
+ {move,{x,1},{x,0}}.
{line,[{location,"couch_key_tree.erl",647}]}.
{call_ext,1,{extfunc,timer,sleep,1}}.
- {move,{y,1},{x,0}}.
+ {move,{y,2},{x,0}}.
{line,[{location,"couch_key_tree.erl",648}]}.
- {call,1,{f,191}}.
- {'%',{var_info,{x,0},[{type,{t_float,any}}]}}.
+ {call,1,{f,218}}.
{move,{y,0},{x,1}}.
{kill,{y,0}}.
{call_ext,2,{extfunc,erlang,max,2}}.
{move,{x,0},{y,0}}.
- {label,202}.
- {loop_rec,{f,204},{x,0}}.
- {test,is_tagged_tuple,{f,203},[{x,0},2,{atom,get_mem}]}.
+ {label,229}.
+ {loop_rec,{f,231},{x,0}}.
+ {test,is_tuple,{f,230},[{x,0}]}.
+ {test,test_arity,{f,230},[{x,0},2]}.
+ {get_tuple_element,{x,0},0,{x,1}}.
+ {get_tuple_element,{x,0},1,{x,0}}.
+ {test,is_eq_exact,{f,230},[{x,1},{atom,get_mem}]}.
{test_heap,3,1}.
remove_message.
{put_tuple2,{x,1},{list,[{atom,mem_max},{y,0}]}}.
- {get_tuple_element,{x,0},1,{x,0}}.
{line,[{location,"couch_key_tree.erl",651}]}.
send.
- {jump,{f,205}}.
- {label,203}.
- {loop_rec_end,{f,202}}.
- {label,204}.
+ {jump,{f,232}}.
+ {label,230}.
+ {loop_rec_end,{f,229}}.
+ {label,231}.
timeout.
- {label,205}.
- {move,{integer,500},{x,1}}.
+ {label,232}.
{move,{y,0},{x,2}}.
- {move,{y,1},{x,0}}.
- {call_last,3,{f,201},2}.
+ {move,{y,1},{x,1}}.
+ {move,{y,2},{x,0}}.
+ {call_last,3,{f,228},3}.
-{function, module_info, 0, 207}.
- {label,206}.
+{function, module_info, 0, 234}.
+ {label,233}.
{line,[]}.
{func_info,{atom,couch_key_tree},{atom,module_info},0}.
- {label,207}.
+ {label,234}.
{move,{atom,couch_key_tree},{x,0}}.
{line,[]}.
{call_ext_only,1,{extfunc,erlang,get_module_info,1}}.
-{function, module_info, 1, 209}.
- {label,208}.
+{function, module_info, 1, 236}.
+ {label,235}.
{line,[]}.
{func_info,{atom,couch_key_tree},{atom,module_info},1}.
- {label,209}.
+ {label,236}.
{move,{x,0},{x,1}}.
{move,{atom,couch_key_tree},{x,0}}.
{line,[]}.
{call_ext_only,2,{extfunc,erlang,get_module_info,2}}.
-{function, '-spawn_mem_sampler/2-fun-0-', 2, 211}.
- {label,210}.
+{function, '-spawn_mem_sampler/2-fun-0-', 2, 238}.
+ {label,237}.
{line,[{location,"couch_key_tree.erl",644}]}.
{func_info,{atom,couch_key_tree},{atom,'-spawn_mem_sampler/2-fun-0-'},2}.
- {label,211}.
- {'%',{var_info,{x,1},[{type,{t_integer,{500,500}}}]}}.
- {allocate,1,1}.
- {move,{x,0},{y,0}}.
+ {label,238}.
+ {allocate,2,2}.
+ {move,{x,1},{y,0}}.
+ {move,{x,0},{y,1}}.
{line,[{location,"couch_key_tree.erl",644}]}.
- {call,1,{f,191}}.
- {'%',{var_info,{x,0},[{type,{t_float,any}}]}}.
- {move,{integer,500},{x,1}}.
+ {call,1,{f,218}}.
+ {move,{y,0},{x,1}}.
{move,{x,0},{x,2}}.
- {move,{y,0},{x,0}}.
- {call_last,3,{f,201},1}.
+ {move,{y,1},{x,0}}.
+ {call_last,3,{f,228},2}.
-{function, '-repair_tree/2-fun-2-', 2, 213}.
- {label,212}.
+{function, '-repair_tree/2-fun-2-', 2, 240}.
+ {label,239}.
{line,[{location,"couch_key_tree.erl",547}]}.
{func_info,{atom,couch_key_tree},{atom,'-repair_tree/2-fun-2-'},2}.
- {label,213}.
- {test,is_tuple,{f,212},[{x,0}]}.
- {test,test_arity,{f,212},[{x,0},2]}.
+ {label,240}.
+ {test,is_tuple,{f,239},[{x,0}]}.
+ {test,test_arity,{f,239},[{x,0},2]}.
{allocate,3,2}.
- {move,{x,0},{y,1}}.
{move,{x,1},{y,2}}.
- {get_tuple_element,{x,0},0,{y,0}}.
- {make_fun2,{f,216},0,0,0}.
- {'%',{var_info,{x,0},[{fun_type,{t_cons,{t_tuple,3,true,#{}},nil}}]}}.
- {get_tuple_element,{y,1},1,{x,2}}.
+ {get_tuple_element,{x,0},0,{y,1}}.
+ {get_tuple_element,{x,0},1,{y,0}}.
+ {make_fun2,{f,244},0,0,0}.
+ {move,{y,0},{x,2}}.
{move,nil,{x,1}}.
- {move,{y,0},{y,1}}.
{trim,1,2}.
{line,[{location,"couch_key_tree.erl",548}]}.
{call_ext,3,{extfunc,lists,foldl,3}}.
- {test,is_nonempty_list,{f,214},[{x,0}]}.
+ {test,is_nonempty_list,{f,242},[{x,0}]}.
{get_list,{x,0},{x,1},{x,2}}.
- {test,is_nil,{f,214},[{x,2}]}.
+ {test,is_nil,{f,242},[{x,2}]}.
{test_heap,3,2}.
{put_tuple2,{x,1},{list,[{y,0},{x,1}]}}.
{move,{y,1},{x,0}}.
{trim,2,0}.
{line,[{location,"couch_key_tree.erl",551}]}.
{call,2,{f,4}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 => {t_list,any,nil},
- 2 => {t_atom,[internal_node,new_branch,new_leaf]}}}}]}}.
+ {test,is_tuple,{f,241},[{x,0}]}.
+ {test,test_arity,{f,241},[{x,0},2]}.
{get_tuple_element,{x,0},0,{x,0}}.
{deallocate,0}.
return.
- {label,214}.
+ {label,241}.
+ {line,[{location,"couch_key_tree.erl",551}]}.
+ {badmatch,{x,0}}.
+ {label,242}.
{line,[{location,"couch_key_tree.erl",548}]}.
{badmatch,{x,0}}.
-{function, '-repair_tree/2-fun-1-', 2, 216}.
- {label,215}.
+{function, '-repair_tree/2-fun-1-', 2, 244}.
+ {label,243}.
{line,[{location,"couch_key_tree.erl",549}]}.
{func_info,{atom,couch_key_tree},{atom,'-repair_tree/2-fun-1-'},2}.
- {label,216}.
- {test,is_tuple,{f,215},[{x,0}]}.
- {test,test_arity,{f,215},[{x,0},2]}.
+ {label,244}.
+ {test,is_tuple,{f,243},[{x,0}]}.
+ {test,test_arity,{f,243},[{x,0},2]}.
{test_heap,6,2}.
{get_tuple_element,{x,0},0,{x,2}}.
{get_tuple_element,{x,0},1,{x,0}}.
@@ -3002,13 +2549,13 @@
return.
-{function, '-repair_tree/2-fun-0-', 2, 218}.
- {label,217}.
+{function, '-repair_tree/2-fun-0-', 2, 246}.
+ {label,245}.
{line,[{location,"couch_key_tree.erl",537}]}.
{func_info,{atom,couch_key_tree},{atom,'-repair_tree/2-fun-0-'},2}.
- {label,218}.
- {test,is_tuple,{f,219},[{x,0}]}.
- {test,test_arity,{f,219},[{x,0},2]}.
+ {label,246}.
+ {test,is_tuple,{f,247},[{x,0}]}.
+ {test,test_arity,{f,247},[{x,0},2]}.
{allocate,1,2}.
{get_tuple_element,{x,0},0,{y,0}}.
{get_tuple_element,{x,0},1,{x,0}}.
@@ -3024,7 +2571,7 @@
{put_tuple2,{x,0},{list,[{x,1},{x,0}]}}.
{deallocate,1}.
return.
- {label,219}.
+ {label,247}.
{test_heap,2,1}.
{put_list,{x,0},nil,{x,1}}.
{move,{atom,function_clause},{x,0}}.
@@ -3032,11 +2579,11 @@
{call_ext_only,2,{extfunc,erlang,error,2}}.
-{function, '-stem_tree/4-fun-1-', 2, 221}.
- {label,220}.
+{function, '-stem_tree/4-fun-1-', 2, 249}.
+ {label,248}.
{line,[{location,"couch_key_tree.erl",515}]}.
{func_info,{atom,couch_key_tree},{atom,'-stem_tree/4-fun-1-'},2}.
- {label,221}.
+ {label,249}.
{line,[{location,"couch_key_tree.erl",516}]}.
{gc_bif,'+',{f,0},2,[{x,1},{integer,1}],{x,1}}.
{test_heap,3,2}.
@@ -3044,111 +2591,123 @@
return.
-{function, '-stem_tree/4-fun-0-', 4, 223}.
- {label,222}.
+{function, '-stem_tree/4-fun-0-', 4, 251}.
+ {label,250}.
{line,[{location,"couch_key_tree.erl",491}]}.
{func_info,{atom,couch_key_tree},{atom,'-stem_tree/4-fun-0-'},4}.
- {label,223}.
- {test,is_tuple,{f,227},[{x,1}]}.
- {test,test_arity,{f,227},[{x,1},4]}.
+ {label,251}.
+ {test,is_tuple,{f,255},[{x,1}]}.
+ {test,test_arity,{f,255},[{x,1},4]}.
+ {get_tuple_element,{x,1},0,{x,4}}.
+ {get_tuple_element,{x,1},1,{x,5}}.
+ {get_tuple_element,{x,1},2,{x,6}}.
+ {get_tuple_element,{x,1},3,{x,1}}.
{line,[{location,"couch_key_tree.erl",493}]}.
- {gc_bif,'+',{f,0},4,[{x,2},{integer,1}],{x,2}}.
- {allocate_zero,3,4}.
- {move,{x,1},{y,2}}.
- {get_tuple_element,{x,1},0,{x,1}}.
- {swap,{x,3},{x,2}}.
- {swap,{x,1},{x,3}}.
- {swap,{x,0},{x,1}}.
+ {gc_bif,'+',{f,0},7,[{x,2},{integer,1}],{x,2}}.
+ {allocate_zero,6,7}.
+ {move,{x,5},{y,3}}.
+ {move,{x,6},{y,4}}.
+ {move,{x,1},{y,5}}.
+ {move,{x,0},{x,1}}.
+ {move,{x,2},{x,0}}.
+ {move,{x,3},{x,2}}.
+ {move,{x,4},{x,3}}.
{line,[{location,"couch_key_tree.erl",493}]}.
- {call,4,{f,148}}.
- {'%',{var_info,{x,0},[{type,{t_tuple,3,false,#{2 => number}}}]}}.
- {get_tuple_element,{y,2},1,{x,1}}.
- {get_tuple_element,{y,2},2,{y,1}}.
- {get_tuple_element,{y,2},3,{y,2}}.
- {move,{x,0},{y,0}}.
- {select_tuple_arity,{x,0},{f,226},{list,[3,{f,225},4,{f,224}]}}.
- {label,224}.
- {get_tuple_element,{x,0},1,{x,0}}.
+ {call,4,{f,172}}.
+ {test,is_tuple,{f,254},[{x,0}]}.
+ {select_tuple_arity,{x,0},{f,254},{list,[3,{f,253},4,{f,252}]}}.
+ {label,252}.
+ {get_tuple_element,{x,0},0,{y,2}}.
+ {get_tuple_element,{x,0},1,{x,1}}.
+ {get_tuple_element,{x,0},2,{y,1}}.
+ {get_tuple_element,{x,0},3,{y,0}}.
+ {move,{x,1},{x,0}}.
+ {move,{y,3},{x,1}}.
+ {kill,{y,3}}.
{call_ext,2,{extfunc,erlang,max,2}}.
{test_heap,2,1}.
- {get_tuple_element,{y,0},2,{x,1}}.
- {put_list,{x,1},{y,1},{y,1}}.
- {get_tuple_element,{y,0},3,{x,1}}.
- {move,{y,2},{x,2}}.
- {move,{x,0},{y,2}}.
- {move,{x,1},{x,0}}.
+ {put_list,{y,1},{y,4},{y,4}}.
+ {move,{y,5},{x,2}}.
+ {move,{x,0},{y,5}}.
+ {move,{y,0},{x,0}}.
{move,{x,2},{x,1}}.
+ {trim,2,4}.
{line,[{location,"couch_key_tree.erl",497}]}.
{call_ext,2,{extfunc,erlang,'++',2}}.
{test_heap,5,1}.
- {get_tuple_element,{y,0},0,{x,1}}.
- {put_tuple2,{x,0},{list,[{x,1},{y,2},{y,1},{x,0}]}}.
- {deallocate,3}.
+ {put_tuple2,{x,0},{list,[{y,0},{y,3},{y,2},{x,0}]}}.
+ {deallocate,4}.
return.
- {label,225}.
- {get_tuple_element,{x,0},1,{x,0}}.
- {call_ext,2,{extfunc,erlang,max,2}}.
- {get_tuple_element,{y,0},2,{x,1}}.
- {move,{y,2},{x,2}}.
- {move,{x,0},{y,2}}.
+ {label,253}.
+ {get_tuple_element,{x,0},0,{y,2}}.
+ {get_tuple_element,{x,0},1,{x,1}}.
+ {get_tuple_element,{x,0},2,{y,1}}.
{move,{x,1},{x,0}}.
+ {move,{y,3},{x,1}}.
+ {kill,{y,3}}.
+ {call_ext,2,{extfunc,erlang,max,2}}.
+ {move,{y,5},{x,2}}.
+ {move,{x,0},{y,5}}.
+ {move,{y,1},{x,0}}.
{move,{x,2},{x,1}}.
+ {trim,2,4}.
{line,[{location,"couch_key_tree.erl",501}]}.
{call_ext,2,{extfunc,erlang,'++',2}}.
{test_heap,5,1}.
- {get_tuple_element,{y,0},0,{x,1}}.
- {put_tuple2,{x,0},{list,[{x,1},{y,2},{y,1},{x,0}]}}.
- {deallocate,3}.
+ {put_tuple2,{x,0},{list,[{y,0},{y,3},{y,2},{x,0}]}}.
+ {deallocate,4}.
return.
- {label,226}.
+ {label,254}.
{line,[{location,"couch_key_tree.erl",493}]}.
{case_end,{x,0}}.
- {label,227}.
+ {label,255}.
{line,[{location,"couch_key_tree.erl",492}]}.
{badmatch,{x,1}}.
-{function, '-stem/2-fun-0-', 3, 229}.
- {label,228}.
+{function, '-stem/2-fun-0-', 3, 257}.
+ {label,256}.
{line,[{location,"couch_key_tree.erl",464}]}.
{func_info,{atom,couch_key_tree},{atom,'-stem/2-fun-0-'},3}.
- {label,229}.
- {test,is_tuple,{f,230},[{x,1}]}.
- {test,test_arity,{f,230},[{x,1},2]}.
- {allocate,1,3}.
+ {label,257}.
+ {test,is_tuple,{f,258},[{x,1}]}.
+ {test,test_arity,{f,258},[{x,1},2]}.
+ {allocate_zero,2,3}.
{get_tuple_element,{x,1},0,{x,3}}.
- {get_tuple_element,{x,1},1,{y,0}}.
+ {get_tuple_element,{x,1},1,{y,1}}.
{move,{x,2},{x,1}}.
{move,{x,3},{x,2}}.
{line,[{location,"couch_key_tree.erl",465}]}.
- {call,3,{f,143}}.
- {'%',{var_info,{x,0},[{type,{t_tuple,2,true,#{}}}]}}.
- {get_tuple_element,{x,0},1,{x,1}}.
- {move,{y,0},{x,2}}.
- {move,{x,0},{y,0}}.
- {move,{x,1},{x,0}}.
- {move,{x,2},{x,1}}.
+ {call,3,{f,167}}.
+ {test,is_tuple,{f,259},[{x,0}]}.
+ {test,test_arity,{f,259},[{x,0},2]}.
+ {get_tuple_element,{x,0},0,{y,0}}.
+ {get_tuple_element,{x,0},1,{x,0}}.
+ {move,{y,1},{x,1}}.
+ {kill,{y,1}}.
{line,[{location,"couch_key_tree.erl",466}]}.
{call_ext,2,{extfunc,erlang,'++',2}}.
{test_heap,3,1}.
- {get_tuple_element,{y,0},0,{x,1}}.
- {put_tuple2,{x,0},{list,[{x,1},{x,0}]}}.
- {deallocate,1}.
+ {put_tuple2,{x,0},{list,[{y,0},{x,0}]}}.
+ {deallocate,2}.
return.
- {label,230}.
+ {label,258}.
{test_heap,4,2}.
{put_list,{x,1},nil,{x,1}}.
{put_list,{x,0},{x,1},{x,1}}.
{move,{atom,function_clause},{x,0}}.
{line,[{location,"couch_key_tree.erl",464}]}.
{call_ext_only,2,{extfunc,erlang,error,2}}.
+ {label,259}.
+ {line,[{location,"couch_key_tree.erl",465}]}.
+ {badmatch,{x,0}}.
-{function, '-map/2-fun-0-', 4, 232}.
- {label,231}.
+{function, '-map/2-fun-0-', 4, 261}.
+ {label,260}.
{line,[{location,"couch_key_tree.erl",404}]}.
{func_info,{atom,couch_key_tree},{atom,'-map/2-fun-0-'},4}.
- {label,232}.
+ {label,261}.
{allocate,0,4}.
{move,{x,3},{x,2}}.
{line,[{location,"couch_key_tree.erl",404}]}.
@@ -3157,132 +2716,114 @@
return.
-{function, '-get/2-lc$^0/1-0-', 1, 234}.
- {label,233}.
+{function, '-get/2-lc$^0/1-0-', 1, 263}.
+ {label,262}.
{line,[{location,"couch_key_tree.erl",301}]}.
{func_info,{atom,couch_key_tree},{atom,'-get/2-lc$^0/1-0-'},1}.
- {label,234}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_cons,{t_tuple,0,false,#{}},nil}}},
- nil}}]}}.
- {test,is_nonempty_list,{f,236},[{x,0}]}.
+ {label,263}.
+ {test,is_nonempty_list,{f,265},[{x,0}]}.
{get_list,{x,0},{x,1},{x,0}}.
+ {test,is_tuple,{f,264},[{x,1}]}.
+ {test,test_arity,{f,264},[{x,1},2]}.
{get_tuple_element,{x,1},0,{x,2}}.
{get_tuple_element,{x,1},1,{x,1}}.
- {get_hd,{x,1},{x,3}}.
- {test,test_arity,{f,235},[{x,3},2]}.
+ {test,is_nonempty_list,{f,264},[{x,1}]}.
+ {get_list,{x,1},{x,3},{x,4}}.
+ {test,is_tuple,{f,264},[{x,3}]}.
+ {test,test_arity,{f,264},[{x,3},2]}.
{allocate,3,4}.
- {move,{x,3},{y,0}}.
{move,{x,2},{y,1}}.
{move,{x,0},{y,2}}.
+ {get_tuple_element,{x,3},1,{y,0}}.
{move,{x,1},{x,0}}.
{line,[{location,"couch_key_tree.erl",300}]}.
- {call,1,{f,238}}.
- {'%',{var_info,{x,0},[{type,{t_list,any,nil}}]}}.
+ {call,1,{f,267}}.
{swap,{y,2},{x,0}}.
{line,[{location,"couch_key_tree.erl",301}]}.
- {call,1,{f,234}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_tuple,2,true,#{2 => {t_list,any,nil}}}}},
- nil}}]}}.
+ {call,1,{f,263}}.
{test_heap,8,1}.
- {get_tuple_element,{y,0},1,{x,1}}.
- {put_tuple2,{x,2},{list,[{y,1},{y,2}]}}.
- {put_tuple2,{x,1},{list,[{x,1},{x,2}]}}.
+ {put_tuple2,{x,1},{list,[{y,1},{y,2}]}}.
+ {put_tuple2,{x,1},{list,[{y,0},{x,1}]}}.
{put_list,{x,1},{x,0},{x,0}}.
{deallocate,3}.
return.
- {label,235}.
- {call_only,1,{f,234}}.
- {label,236}.
+ {label,264}.
+ {call_only,1,{f,263}}.
+ {label,265}.
+ {test,is_nil,{f,262},[{x,0}]}.
return.
-{function, '-get/2-lc$^1/1-1-', 1, 238}.
- {label,237}.
+{function, '-get/2-lc$^1/1-1-', 1, 267}.
+ {label,266}.
{line,[{location,"couch_key_tree.erl",300}]}.
{func_info,{atom,couch_key_tree},{atom,'-get/2-lc$^1/1-1-'},1}.
- {label,238}.
- {'%',{var_info,{x,0},[{type,{t_list,{t_tuple,0,false,#{}},nil}}]}}.
- {test,is_nonempty_list,{f,240},[{x,0}]}.
+ {label,267}.
+ {test,is_nonempty_list,{f,269},[{x,0}]}.
{get_list,{x,0},{x,1},{x,0}}.
- {test,test_arity,{f,239},[{x,1},2]}.
+ {test,is_tuple,{f,268},[{x,1}]}.
+ {test,test_arity,{f,268},[{x,1},2]}.
{allocate,1,2}.
- {move,{x,1},{y,0}}.
+ {get_tuple_element,{x,1},0,{y,0}}.
{line,[{location,"couch_key_tree.erl",300}]}.
- {call,1,{f,238}}.
- {'%',{var_info,{x,0},[{type,{t_list,any,nil}}]}}.
+ {call,1,{f,267}}.
{test_heap,2,1}.
- {get_tuple_element,{y,0},0,{x,1}}.
- {put_list,{x,1},{x,0},{x,0}}.
+ {put_list,{y,0},{x,0},{x,0}}.
{deallocate,1}.
return.
- {label,239}.
- {call_only,1,{f,238}}.
- {label,240}.
+ {label,268}.
+ {call_only,1,{f,267}}.
+ {label,269}.
+ {test,is_nil,{f,266},[{x,0}]}.
return.
-{function, '-remove_leafs/2-fun-2-', 2, 242}.
- {label,241}.
+{function, '-remove_leafs/2-fun-2-', 2, 271}.
+ {label,270}.
{line,[{location,"couch_key_tree.erl",230}]}.
{func_info,{atom,couch_key_tree},{atom,'-remove_leafs/2-fun-2-'},2}.
- {label,242}.
- {test,is_tuple,{f,241},[{x,0}]}.
- {test,test_arity,{f,241},[{x,0},2]}.
+ {label,271}.
+ {test,is_tuple,{f,270},[{x,0}]}.
+ {test,test_arity,{f,270},[{x,0},2]}.
{allocate,3,2}.
- {move,{x,0},{y,1}}.
{move,{x,1},{y,2}}.
- {get_tuple_element,{x,0},0,{y,0}}.
- {make_fun2,{f,245},0,0,0}.
- {'%',{var_info,{x,0},[{fun_type,{t_cons,{t_tuple,3,true,#{}},nil}}]}}.
- {get_tuple_element,{y,1},1,{x,2}}.
+ {get_tuple_element,{x,0},0,{y,1}}.
+ {get_tuple_element,{x,0},1,{y,0}}.
+ {make_fun2,{f,275},0,0,0}.
+ {move,{y,0},{x,2}}.
{move,nil,{x,1}}.
- {move,{y,0},{y,1}}.
{trim,1,2}.
{line,[{location,"couch_key_tree.erl",231}]}.
{call_ext,3,{extfunc,lists,foldl,3}}.
- {test,is_nonempty_list,{f,243},[{x,0}]}.
+ {test,is_nonempty_list,{f,273},[{x,0}]}.
{get_list,{x,0},{x,1},{x,2}}.
- {test,is_nil,{f,243},[{x,2}]}.
+ {test,is_nil,{f,273},[{x,2}]}.
{test_heap,3,2}.
{put_tuple2,{x,1},{list,[{y,0},{x,1}]}}.
{move,{y,1},{x,0}}.
{trim,2,0}.
{line,[{location,"couch_key_tree.erl",234}]}.
{call,2,{f,4}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 => {t_list,any,nil},
- 2 => {t_atom,[internal_node,new_branch,new_leaf]}}}}]}}.
+ {test,is_tuple,{f,272},[{x,0}]}.
+ {test,test_arity,{f,272},[{x,0},2]}.
{get_tuple_element,{x,0},0,{x,0}}.
{deallocate,0}.
return.
- {label,243}.
+ {label,272}.
+ {line,[{location,"couch_key_tree.erl",234}]}.
+ {badmatch,{x,0}}.
+ {label,273}.
{line,[{location,"couch_key_tree.erl",231}]}.
{badmatch,{x,0}}.
-{function, '-remove_leafs/2-fun-1-', 2, 245}.
- {label,244}.
+{function, '-remove_leafs/2-fun-1-', 2, 275}.
+ {label,274}.
{line,[{location,"couch_key_tree.erl",232}]}.
{func_info,{atom,couch_key_tree},{atom,'-remove_leafs/2-fun-1-'},2}.
- {label,245}.
- {test,is_tuple,{f,244},[{x,0}]}.
- {test,test_arity,{f,244},[{x,0},2]}.
+ {label,275}.
+ {test,is_tuple,{f,274},[{x,0}]}.
+ {test,test_arity,{f,274},[{x,0},2]}.
{test_heap,6,2}.
{get_tuple_element,{x,0},0,{x,2}}.
{get_tuple_element,{x,0},1,{x,0}}.
@@ -3291,25 +2832,19 @@
return.
-{function, '-remove_leafs/2-lc$^0/1-0-', 1, 247}.
- {label,246}.
+{function, '-remove_leafs/2-lc$^0/1-0-', 1, 277}.
+ {label,276}.
{line,[{location,"couch_key_tree.erl",225}]}.
{func_info,{atom,couch_key_tree},{atom,'-remove_leafs/2-lc$^0/1-0-'},1}.
- {label,247}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{2 => {t_cons,{t_tuple,0,false,#{}},nil}}},
- nil}}]}}.
- {test,is_nonempty_list,{f,248},[{x,0}]}.
+ {label,277}.
+ {test,is_nonempty_list,{f,279},[{x,0}]}.
{get_list,{x,0},{x,1},{x,0}}.
+ {test,is_tuple,{f,278},[{x,1}]}.
+ {test,test_arity,{f,278},[{x,1},2]}.
{get_tuple_element,{x,1},0,{x,2}}.
+ {get_tuple_element,{x,1},1,{x,1}}.
{line,[{location,"couch_key_tree.erl",225}]}.
{gc_bif,'+',{f,0},3,[{x,2},{integer,1}],{x,2}}.
- {get_tuple_element,{x,1},1,{x,1}}.
{line,[{location,"couch_key_tree.erl",225}]}.
{gc_bif,length,{f,0},3,[{x,1}],{x,3}}.
{line,[{location,"couch_key_tree.erl",225}]}.
@@ -3318,105 +2853,112 @@
{move,{x,1},{y,0}}.
{move,{x,2},{y,1}}.
{line,[{location,"couch_key_tree.erl",225}]}.
- {call,1,{f,247}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_list,
- {t_tuple,2,true,
- #{1 => number,
- 2 => {t_cons,{t_tuple,0,false,#{}},nil}}},
- nil}}]}}.
+ {call,1,{f,277}}.
{test_heap,5,1}.
{put_tuple2,{x,1},{list,[{y,1},{y,0}]}}.
{put_list,{x,1},{x,0},{x,0}}.
{deallocate,2}.
return.
- {label,248}.
+ {label,278}.
+ {call_only,1,{f,277}}.
+ {label,279}.
+ {test,is_nil,{f,276},[{x,0}]}.
return.
-{function, '-find_missing_simple/3-lc$^1/1-1-', 2, 250}.
- {label,249}.
+{function, '-find_missing_simple/3-lc$^1/1-1-', 2, 281}.
+ {label,280}.
{line,[{location,"couch_key_tree.erl",197}]}.
{func_info,{atom,couch_key_tree},
{atom,'-find_missing_simple/3-lc$^1/1-1-'},
2}.
- {label,250}.
- {'%',{var_info,{x,0},[{type,{t_list,{t_tuple,2,true,#{}},nil}}]}}.
- {test,is_nonempty_list,{f,252},[{x,0}]}.
+ {label,281}.
+ {test,is_nonempty_list,{f,283},[{x,0}]}.
{get_list,{x,0},{x,2},{x,0}}.
+ {test,is_tuple,{f,282},[{x,2}]}.
+ {test,test_arity,{f,282},[{x,2},2]}.
{get_tuple_element,{x,2},0,{x,3}}.
- {test,is_lt,{f,251},[{x,3},{x,1}]}.
+ {test,is_lt,{f,282},[{x,3},{x,1}]}.
{allocate,1,3}.
{move,{x,2},{y,0}}.
{line,[{location,"couch_key_tree.erl",197}]}.
- {call,2,{f,250}}.
- {'%',{var_info,{x,0},[{type,{t_list,{t_tuple,2,true,#{}},nil}}]}}.
+ {call,2,{f,281}}.
{test_heap,2,1}.
{put_list,{y,0},{x,0},{x,0}}.
{deallocate,1}.
return.
- {label,251}.
- {call_only,2,{f,250}}.
- {label,252}.
+ {label,282}.
+ {call_only,2,{f,281}}.
+ {label,283}.
+ {test,is_nil,{f,284},[{x,0}]}.
return.
+ {label,284}.
+ {test_heap,2,1}.
+ {put_list,{x,0},nil,{x,1}}.
+ {move,{atom,function_clause},{x,0}}.
+ {line,[{location,"couch_key_tree.erl",197}]}.
+ {call_ext_only,2,{extfunc,erlang,error,2}}.
-{function, '-find_missing_simple/3-lc$^0/1-0-', 2, 254}.
- {label,253}.
+{function, '-find_missing_simple/3-lc$^0/1-0-', 2, 286}.
+ {label,285}.
{line,[{location,"couch_key_tree.erl",196}]}.
{func_info,{atom,couch_key_tree},
{atom,'-find_missing_simple/3-lc$^0/1-0-'},
2}.
- {label,254}.
- {'%',{var_info,{x,0},[{type,{t_list,{t_tuple,2,true,#{}},nil}}]}}.
- {test,is_nonempty_list,{f,256},[{x,0}]}.
+ {label,286}.
+ {test,is_nonempty_list,{f,288},[{x,0}]}.
{get_list,{x,0},{x,2},{x,0}}.
+ {test,is_tuple,{f,287},[{x,2}]}.
+ {test,test_arity,{f,287},[{x,2},2]}.
{get_tuple_element,{x,2},0,{x,3}}.
- {test,is_ge,{f,255},[{x,3},{x,1}]}.
+ {test,is_ge,{f,287},[{x,3},{x,1}]}.
{allocate,1,3}.
{move,{x,2},{y,0}}.
{line,[{location,"couch_key_tree.erl",196}]}.
- {call,2,{f,254}}.
- {'%',{var_info,{x,0},[{type,{t_list,{t_tuple,2,true,#{}},nil}}]}}.
+ {call,2,{f,286}}.
{test_heap,2,1}.
{put_list,{y,0},{x,0},{x,0}}.
{deallocate,1}.
return.
- {label,255}.
- {call_only,2,{f,254}}.
- {label,256}.
+ {label,287}.
+ {call_only,2,{f,286}}.
+ {label,288}.
+ {test,is_nil,{f,289},[{x,0}]}.
return.
+ {label,289}.
+ {test_heap,2,1}.
+ {put_list,{x,0},nil,{x,1}}.
+ {move,{atom,function_clause},{x,0}}.
+ {line,[{location,"couch_key_tree.erl",196}]}.
+ {call_ext_only,2,{extfunc,erlang,error,2}}.
-{function, '-find_missing/2-lc$^1/1-1-', 2, 258}.
- {label,257}.
+{function, '-find_missing/2-lc$^1/1-1-', 2, 291}.
+ {label,290}.
{line,[{location,"couch_key_tree.erl",187}]}.
{func_info,{atom,couch_key_tree},{atom,'-find_missing/2-lc$^1/1-1-'},2}.
- {label,258}.
- {test,is_nonempty_list,{f,260},[{x,0}]}.
+ {label,291}.
+ {test,is_nonempty_list,{f,293},[{x,0}]}.
{get_list,{x,0},{x,2},{x,0}}.
- {test,is_tuple,{f,259},[{x,2}]}.
- {test,test_arity,{f,259},[{x,2},2]}.
+ {test,is_tuple,{f,292},[{x,2}]}.
+ {test,test_arity,{f,292},[{x,2},2]}.
{get_tuple_element,{x,2},0,{x,3}}.
- {test,is_lt,{f,259},[{x,3},{x,1}]}.
+ {test,is_lt,{f,292},[{x,3},{x,1}]}.
{allocate,1,3}.
{move,{x,2},{y,0}}.
{line,[{location,"couch_key_tree.erl",187}]}.
- {call,2,{f,258}}.
- {'%',{var_info,{x,0},[{type,{t_list,{t_tuple,2,true,#{}},nil}}]}}.
+ {call,2,{f,291}}.
{test_heap,2,1}.
{put_list,{y,0},{x,0},{x,0}}.
{deallocate,1}.
return.
- {label,259}.
- {call_only,2,{f,258}}.
- {label,260}.
- {test,is_nil,{f,261},[{x,0}]}.
+ {label,292}.
+ {call_only,2,{f,291}}.
+ {label,293}.
+ {test,is_nil,{f,294},[{x,0}]}.
return.
- {label,261}.
+ {label,294}.
{test_heap,2,1}.
{put_list,{x,0},nil,{x,1}}.
{move,{atom,function_clause},{x,0}}.
@@ -3424,32 +2966,31 @@
{call_ext_only,2,{extfunc,erlang,error,2}}.
-{function, '-find_missing/2-lc$^0/1-0-', 2, 263}.
- {label,262}.
+{function, '-find_missing/2-lc$^0/1-0-', 2, 296}.
+ {label,295}.
{line,[{location,"couch_key_tree.erl",186}]}.
{func_info,{atom,couch_key_tree},{atom,'-find_missing/2-lc$^0/1-0-'},2}.
- {label,263}.
- {test,is_nonempty_list,{f,265},[{x,0}]}.
+ {label,296}.
+ {test,is_nonempty_list,{f,298},[{x,0}]}.
{get_list,{x,0},{x,2},{x,0}}.
- {test,is_tuple,{f,264},[{x,2}]}.
- {test,test_arity,{f,264},[{x,2},2]}.
+ {test,is_tuple,{f,297},[{x,2}]}.
+ {test,test_arity,{f,297},[{x,2},2]}.
{get_tuple_element,{x,2},0,{x,3}}.
- {test,is_ge,{f,264},[{x,3},{x,1}]}.
+ {test,is_ge,{f,297},[{x,3},{x,1}]}.
{allocate,1,3}.
{move,{x,2},{y,0}}.
{line,[{location,"couch_key_tree.erl",186}]}.
- {call,2,{f,263}}.
- {'%',{var_info,{x,0},[{type,{t_list,{t_tuple,2,true,#{}},nil}}]}}.
+ {call,2,{f,296}}.
{test_heap,2,1}.
{put_list,{y,0},{x,0},{x,0}}.
{deallocate,1}.
return.
- {label,264}.
- {call_only,2,{f,263}}.
- {label,265}.
- {test,is_nil,{f,266},[{x,0}]}.
+ {label,297}.
+ {call_only,2,{f,296}}.
+ {label,298}.
+ {test,is_nil,{f,299},[{x,0}]}.
return.
- {label,266}.
+ {label,299}.
{test_heap,2,1}.
{put_list,{x,0},nil,{x,1}}.
{move,{atom,function_clause},{x,0}}.
@@ -3457,22 +2998,20 @@
{call_ext_only,2,{extfunc,erlang,error,2}}.
-{function, '-multi_merge/2-fun-0-', 2, 268}.
- {label,267}.
+{function, '-multi_merge/2-fun-0-', 2, 301}.
+ {label,300}.
{line,[{location,"couch_key_tree.erl",46}]}.
{func_info,{atom,couch_key_tree},{atom,'-multi_merge/2-fun-0-'},2}.
- {label,268}.
+ {label,301}.
{allocate,0,2}.
{swap,{x,0},{x,1}}.
{line,[{location,"couch_key_tree.erl",47}]}.
{call,2,{f,4}}.
- {'%',
- {var_info,
- {x,0},
- [{type,
- {t_tuple,2,true,
- #{1 => {t_list,any,nil},
- 2 => {t_atom,[internal_node,new_branch,new_leaf]}}}}]}}.
+ {test,is_tuple,{f,302},[{x,0}]}.
+ {test,test_arity,{f,302},[{x,0},2]}.
{get_tuple_element,{x,0},0,{x,0}}.
{deallocate,0}.
return.
+ {label,302}.
+ {line,[{location,"couch_key_tree.erl",47}]}.
+ {badmatch,{x,0}}.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment