basic reach algorithm done with field marking