 SYMBOL: live-phis
 
 : live-phi? ( ##phi -- ? )
-    dst>> live-phis get key? ;
+    dst>> live-phis get in? ;
 
 : compute-live-phis ( -- )
-    H{ } clone live-phis set
+    HS{ } clone live-phis set
     used-vregs get [
         phis get at [
             [
                 dst>>
-                [ live-phis get conjoin ]
+                [ live-phis get adjoin ]
                 [ phis get delete-at ]
                 bi
             ]


: gen-name ( vreg -- vreg' )
    [ next-vreg dup ] dip
    dup pushed get 2dup key?
    [ 2drop stacks get at set-last ]
    [ conjoin stacks get push-at ]
    if ;

: (top-name) ( vreg -- vreg' )

M: vreg-insn compute-insn-defs
    defs-vregs [
        defs get [ conjoin-at ] [ drop ] [ at assoc-size 1 > ] 2tri
        [ defs-multi get adjoin ] [ drop ] if
    ] with each ;

: compute-defs ( cfg -- )
    H{ } clone defs set
    HS{ } clone defs-multi set
    [
        [ basic-block get ] dip
        [ compute-insn-defs ] with each
