Warm up caches in the XPath big XML benchmark

This commit is contained in:
Yorick Peterse 2015-04-12 20:25:21 +02:00
parent b42f9aaf32
commit e6d2ba4e0e
1 changed files with 3 additions and 0 deletions

View File

@ -2,6 +2,9 @@ require_relative '../../benchmark_helper'
doc = Oga.parse_xml(big_xml_file)
# Warm up any caches
doc.xpath('descendant-or-self::location')
measure_average do
doc.xpath('descendant-or-self::location')
end