Make test/perf.js use types.visit instead of types.traverse.
Create child cache lazily to avoid Object.create(null) in Path constructor.