From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@sympa.inria.fr Delivered-To: caml-list@sympa.inria.fr Received: from mail3-relais-sop.national.inria.fr (mail3-relais-sop.national.inria.fr [192.134.164.104]) by sympa.inria.fr (Postfix) with ESMTPS id 89FA17F787 for ; Tue, 8 Nov 2016 13:42:20 +0100 (CET) Authentication-Results: mail3-smtp-sop.national.inria.fr; spf=None smtp.pra=oleg@okmij.org; spf=Pass smtp.mailfrom=oleg@okmij.org; spf=None smtp.helo=postmaster@mail1.g3.pair.com Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of oleg@okmij.org) identity=pra; client-ip=66.39.3.114; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="oleg@okmij.org"; x-sender="oleg@okmij.org"; x-conformance=sidf_compatible Received-SPF: Pass (mail3-smtp-sop.national.inria.fr: domain of oleg@okmij.org designates 66.39.3.114 as permitted sender) identity=mailfrom; client-ip=66.39.3.114; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="oleg@okmij.org"; x-sender="oleg@okmij.org"; x-conformance=sidf_compatible; x-record-type="v=spf1" Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of postmaster@mail1.g3.pair.com) identity=helo; client-ip=66.39.3.114; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="oleg@okmij.org"; x-sender="postmaster@mail1.g3.pair.com"; x-conformance=sidf_compatible IronPort-PHdr: =?us-ascii?q?9a23=3AHc3AnBTRrS9hFN1+0OIXLN0Yjtpsv+yvbD5Q0YIu?= =?us-ascii?q?jvd0So/mwa64ZhCN2/xhgRfzUJnB7Loc0qyN4vqmCDJLuMfJmUtBWaQEbwUCh8?= =?us-ascii?q?QSkl5oK+++Imq/EsTXaTcnFt9JTl5v8iLzG0FUHMHjew+a+SXqvnYsExnyfTB4?= =?us-ascii?q?Ov7yUtaLyZ/mjabjpdaKMk1hv3mUWftKNhK4rAHc5IE9oLBJDeIP8CbPuWZCYO?= =?us-ascii?q?9MxGlldhq5lhf44dqsrtY4q3wD86Fpy8kVXqzwZaU1SfpDBzQrKW0vzMLuvBjH?= =?us-ascii?q?CwCI4ygySGITxz1MDgeNuBb+U5jZtSj/t+g73zOVa56lBYsoUCivuv84ACTjjz?= =?us-ascii?q?0KYmY0?= X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: =?us-ascii?q?A0A1AADyxyFYh3IDJ0JdGwEBAQMBAQEJA?= =?us-ascii?q?QEBFwEBBAEBCgEBgwQBAQEBAaYzlFOCCIYkAoIVQRIBAQEBAQEBAQEBARIBAQE?= =?us-ascii?q?KCwkJHTCCMxiCFwEBAwE6PwUWITQFcIhACLREi0oBAQgCJYY9hFiEFIEAgmWCL?= =?us-ascii?q?wWPUYpegjaOBwuBboFOgySJNJE2JQKBKBuDJ4F3iB0BAQE?= X-IPAS-Result: =?us-ascii?q?A0A1AADyxyFYh3IDJ0JdGwEBAQMBAQEJAQEBFwEBBAEBCgE?= =?us-ascii?q?BgwQBAQEBAaYzlFOCCIYkAoIVQRIBAQEBAQEBAQEBARIBAQEKCwkJHTCCMxiCF?= =?us-ascii?q?wEBAwE6PwUWITQFcIhACLREi0oBAQgCJYY9hFiEFIEAgmWCLwWPUYpegjaOBwu?= =?us-ascii?q?BboFOgySJNJE2JQKBKBuDJ4F3iB0BAQE?= X-IronPort-AV: E=Sophos;i="5.31,462,1473112800"; d="scan'208";a="199615251" Received: from mail1.g3.pair.com ([66.39.3.114]) by mail3-smtp-sop.national.inria.fr with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 08 Nov 2016 13:42:08 +0100 Received: from Magus.localnet (fortigate.sf.ecei.tohoku.ac.jp [130.34.188.206]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail1.g3.pair.com (Postfix) with ESMTPSA id CF8AB3FBB41; Tue, 8 Nov 2016 07:42:03 -0500 (EST) Date: Tue, 8 Nov 2016 21:47:31 +0900 From: Oleg To: gabriel.scherer@gmail.com Cc: yminsky@janestreet.com, caml-list@inria.fr, gmalecha@gmail.com Message-ID: <20161108124731.GA6455@Magus.localnet> Mail-Followup-To: Oleg , gabriel.scherer@gmail.com, yminsky@janestreet.com, caml-list@inria.fr, gmalecha@gmail.com MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.6.1 (2016-04-27) Subject: Re: [Caml-list] The fastest stream library [Was: Question about Gabriel wrote: > I regret not being pointed to this work earlier, because I think that > measuring the performance of Enum as a representative OCaml stream library > performance is not the best choice : Enum is designed to be flexible in a > bit too many ways to be efficient on pure-streaming scenarios (it supports > a generic "clone", and effectful generators, that makes the codebase too > complex for its own good; I think that Batteries community is aware that > Enum is not as good as it should be right now). There are other, more > efficient streaming libraries out there, including BatSeq in Batteries that > should already be sensibly faster; Core and Containers also have more > efficient streaming libraries. Please do note that we make the double claim: wide expressivity *and* guaranteed highest performance. We support not just the standard map and filter, but zipping of streams with flat_maps in them, with both finite and infinite streams. So we do want generality. From this point, Enum was quite an appropriate. Speaking of benchmarks, the real point of comparison is the hand-written code for each benchmark, written with imperative loops, references, etc. (We admit that some of that on several occasions the hand-written baseline code was fine-tuned when it turned out that the generated code outperformed it.) Please do feel free to suggest faster versions.