Return-Path: Delivered-To: apmail-lucene-dev-archive@www.apache.org Received: (qmail 86896 invoked from network); 19 Apr 2010 20:12:11 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 19 Apr 2010 20:12:11 -0000 Received: (qmail 82170 invoked by uid 500); 19 Apr 2010 20:12:10 -0000 Delivered-To: apmail-lucene-dev-archive@lucene.apache.org Received: (qmail 82129 invoked by uid 500); 19 Apr 2010 20:12:09 -0000 Mailing-List: contact dev-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@lucene.apache.org Delivered-To: mailing list dev@lucene.apache.org Received: (qmail 82118 invoked by uid 99); 19 Apr 2010 20:12:09 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 19 Apr 2010 20:12:09 +0000 X-ASF-Spam-Status: No, hits=0.4 required=10.0 tests=AWL,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of dawid.weiss@gmail.com designates 209.85.219.221 as permitted sender) Received: from [209.85.219.221] (HELO mail-ew0-f221.google.com) (209.85.219.221) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 19 Apr 2010 20:12:03 +0000 Received: by ewy21 with SMTP id 21so1077426ewy.5 for ; Mon, 19 Apr 2010 13:11:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :from:date:received:message-id:subject:to:content-type; bh=JCs2Ncekz+wmwk1WNm0euJT9P/NmIVMVG6kDny+xitI=; b=MVNDlfWV7Jq7acS/NIExvI6bD+uKvu9faTNo9cgq0njNeYt6zUf9AqevTJMGIcd+j1 Io1e2gzOhgoIE7piBEPQKLYZVaKKNPzGvUbzcyt0/XWJTrOl7vDAkbpYZ/5fQqp8/ggX VzbZBF/O4rzG5XKdYGQlmMqgy+6uwfLZ2hZ6M= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type; b=mU8OLdzRELHOfbxjAy8XlVChIsOpqGt/X3o4fhyUlkl0YMyhUxi/qclAUblLfYyVkQ uQqC47C8IVVOqU0+l5Zomf+OMnTqbzoiKm68ijKWVopsq9d1wxd881khi8xL5f2MhrjK KjQO7pY6pIQDJYkvs4DRFUFFrJM5AAeZz7bgI= MIME-Version: 1.0 Received: by 10.239.132.204 with HTTP; Mon, 19 Apr 2010 13:11:21 -0700 (PDT) In-Reply-To: References: From: Dawid Weiss Date: Mon, 19 Apr 2010 22:11:21 +0200 Received: by 10.239.183.211 with SMTP id v19mr521285hbg.182.1271707901196; Mon, 19 Apr 2010 13:11:41 -0700 (PDT) Message-ID: Subject: Re: HPPC: High Performance Primitive Collections for Java To: dev@lucene.apache.org Content-Type: text/plain; charset=UTF-8 > Hmmm.. can anybody compare these to fastutil? I believe I can answer some of your questions. 1) HPPC is not directly Java Collections-compatible. It does have interface hierarchy, but it's not a descendant of the familiar Set, Map or List. Fastutil is collections-compatible. 2) HPPC has open internals, so you can do anything you like once your collections are created, including manipulation of internal storage arrays, for instance. This was a design decision and goal. As with any sharp objects, improper use may cause harm. 3) HPPC uses assert instead of fixed condition checks. There are no attempts to detect misuse (fail-fast iterators, etc.). 4) fastutil is more mature, has support for more data structures (sorted trees, etc.) and was written by an excellent programmer (Sebastiano Vigna). HPPC was created internally for use at Carrot Search and was primarily motivated by speed; we believed that in certain applications direct access to collections' internals should be allowed and should be beneficial. Our micro-benchmarks show that this is largerly true if you manipulate LOTS of data. For smaller data sets even built-in Java collections with boxed types do surprisingly well (due to HotSpot optimizations too). 5) There are subtle differences in how HPPC is written -- I use pretty much normal generic classes with some pseudo-intrinsics and regexp-substituted comments. Sebastiano uses C++ preprocessor to generate Java classes from templates (yes, wicked). I look at Lucene and SOLR source code and learn a LOT from folks contributing to this project, so HPPC will be hardly any faster or better compared to what Lucene already has, but if anybody find anything from HPPC useful, please take handfuls. I would love for this project to be finally merged with Mahout, but I intentially left it in Carrot Search labs for a little while so that the API can stabilize (through our in-house experiments mostly). Thanks for showing your interest! Dawid --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org For additional commands, e-mail: dev-help@lucene.apache.org