code: def common_subexp_elimination(block=None, abs_thresh=1, percent_thresh=0):
      
      block = working_block(block)
      net_count = _NetCount(block)
  
      while net_count.shrinking(block, percent_thresh, abs_thresh):
          net_table = _find_common_subexps(block)
          _replace_subexps(block, net_table)
docs: Common Subexpression Elimination for PyRTL blocks
  
      :param block: the block to run the subexpression elimination on
      :param abs_thresh: absolute threshold for stopping optimization
      :param percent_thresh: percent threshold for stopping optimization