anchor.diff:  backward([{label,Lbl}=L|Is], D, Acc) ->
       backward(Is, beam_utils:index_label(Lbl, Acc, D), [L|Acc]);
   backward([{select,select_val,Reg,{f,Fail0},List0}|Is], D, Acc) ->
  -    List = shortcut_select_list(List0, Reg, D, []),
  +    List1 = shortcut_select_list(List0, Reg, D, []),
       Fail1 = shortcut_label(Fail0, D),
       Fail = shortcut_bs_test(Fail1, Is, D),
  +    List = prune_redundant(List1, Fail),
       case List of
  +	[] ->
  +	    Jump = {jump,{f,Fail}},
  +	    backward([Jump|Is], D, Acc);
  +	[V,F] ->
  +	    Test = {test,is_eq_exact,{f,Fail},[Reg,V]},
  +	    Jump = {jump,F},
  +	    backward([Jump,Test|Is], D, Acc);
   	[{atom,B1},F,{atom,B2},F] when B1 =:= not B2 ->
   	    Test = {test,is_boolean,{f,Fail},[Reg]},
   	    Jump = {jump,F},
  
positive.code: 
  shortcut_select_label(To, Reg, Lit, D) ->
      shortcut_rel_op(To, is_ne_exact, [Reg,Lit], D).
  
  %% Replace a comparison operator with a test instruction and a jump.
  %% For example, if we have this code:
  
negative.code: 	    %% An is_atom test before an is_boolean test (with the
  	    %% same failure label) is redundant.
  	    backward(Is, D, Acc);
  	{{test,is_atom,Fail,[R]},
  	 [{test,is_eq_exact,Fail,[R,{atom,_}]}|_]} ->
  	    %% An is_atom test before a comparison with an atom (with
  	    %% the same failure label) is redundant.
  	    backward(Is, D, Acc);
  	{{test,is_integer,Fail,[R]},
  	 [{test,is_eq_exact,Fail,[R,{integer,_}]}|_]} ->
  	    %% An is_integer test before a comparison with an integer
  	    %% (with the same failure label) is redundant.
  	    backward(Is, D, Acc);
  	{{test,_,_,_},_} ->
  	    %% Still a test instruction. Done.
  	    backward(Is, D, [I|Acc]);
  