LUCENE-6889: Add some basic rewrite rules to BooleanQuery that can make it run significantly faster in some cases.