At the moment UserAgent parser is based on multiple regular expression pattern matching which is very time consuming.