-Reduce visit function use reversed deep first order

Signed-off-by: xiehuc <xiehuc@gmail.com>