mergeLabels :: [LabelTable] -> InstrM ()
mergeLabels tables = do
  debug $ do
    InstrState { isLabelTable = table } <- get
    liftIO $ print ("mergeLabels", map (`differenceLT` table) tables)
  modify' $ \s@InstrState { isLabelTable = table
                          , isRunAgain   = ra } ->
    let diffTables = map (`differenceLT` table) tables
        updates = any (\m -> sizeLT m > 0) diffTables
    in s { isLabelTable = unionsLT (table : diffTables)
         , isRunAgain   = updateRunAgain ra updates }
mergeLabels :: [LabelTable] -> InstrM ()
mergeLabels tables = do
  debug $ do
    InstrState { isLabelTable = table } <- get
    liftIO $ print ("mergeLabels", map (`differenceLT` table) tables)
  modify' $ \s@InstrState { isLabelTable = table
                          , isRunAgain   = ra } ->
    let diffTables = map (`differenceLT` table) tables
        updates = any (\m -> sizeLT m > 0) diffTables
    in s { isLabelTable = unionsLT (table : diffTables)
         , isRunAgain   = updateRunAgain ra updates }
mergeLabels tables = do
  debug $ do
    InstrState { isLabelTable = table } <- get
    liftIO $ print ("mergeLabels", map (`differenceLT` table) tables)
  modify' $ \s@InstrState { isLabelTable = table
                          , isRunAgain   = ra } ->
    let diffTables = map (`differenceLT` table) tables
        updates = any (\m -> sizeLT m > 0) diffTables
    in s { isLabelTable = unionsLT (table : diffTables)
         , isRunAgain   = updateRunAgain ra updates }