[Xapian-discuss] timing behaviour for creating large queries

Markus Wörle mrks at mrks.de
Thu Feb 8 17:36:08 GMT 2007


Am 07.02.2007 um 18:27 schrieb Richard Boulton:

> Markus Wörle wrote:
>> My queryparser builds a query object by connecting two objects by  
>> an operator using the Search::Xapian::Query constructor, e.g.
>> Search::Xapian::Query->new(OP_OR, $left, $right)
>
> The C++ interface supports a constructor which takes a sequence of  
> terms to build an OR query out of - this should get around the  
> quadratic complexity you're seeing (though I haven't tested to  
> check). I'm not belive that construction method is available from  
> Perl, having taken a quick peek at the XS code.

It actually is available from Perl, so i modified my algorithm to  
join consecutive terms which are connected by the same operator - and  
it worked very well as you can see on this new results: http:// 
5nord.org/~mrks/query-performance-new.gif

Thank you!


More information about the Xapian-discuss mailing list