From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: 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 C82CD7FA5F for ; Mon, 16 Jan 2017 18:13:00 +0100 (CET) Authentication-Results: mail3-smtp-sop.national.inria.fr; spf=None smtp.pra=examachine@gmail.com; spf=Pass smtp.mailfrom=examachine@gmail.com; spf=None smtp.helo=postmaster@mail-vk0-f52.google.com Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of examachine@gmail.com) identity=pra; client-ip=209.85.213.52; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="examachine@gmail.com"; x-sender="examachine@gmail.com"; x-conformance=sidf_compatible Received-SPF: Pass (mail3-smtp-sop.national.inria.fr: domain of examachine@gmail.com designates 209.85.213.52 as permitted sender) identity=mailfrom; client-ip=209.85.213.52; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="examachine@gmail.com"; x-sender="examachine@gmail.com"; 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@mail-vk0-f52.google.com) identity=helo; client-ip=209.85.213.52; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="examachine@gmail.com"; x-sender="postmaster@mail-vk0-f52.google.com"; x-conformance=sidf_compatible IronPort-PHdr: =?us-ascii?q?9a23=3ATZ9lJxxx7AEnL4rXCy+O+j09IxM/srCxBDY+r6Qd?= =?us-ascii?q?2uoTIJqq85mqBkHD//Il1AaPBtSHrakZwLCP4+jJYi8p2d65qncMcZhBBVcuqP?= =?us-ascii?q?49uEgeOvODElDxN/XwbiY3T4xoXV5h+GynYwAOQJ6tL1LdrWev4jEMBx7xKRR6?= =?us-ascii?q?JvjvGo7Vks+7y/2+94fdbghMizexe71/IRW5oQnPq8UbgpZpJ7osxBfOvnZGYf?= =?us-ascii?q?ldy3lyJVKUkRb858Ow84Bm/i9Npf8v9NNOXLvjcaggQrNWEDopM2Yu5M32rhbD?= =?us-ascii?q?VheA5mEdUmoNjBVFBRXO4QzgUZfwtiv6sfd92DWfMMbrQ704RSiu4qF2QxLzli?= =?us-ascii?q?wJKyA2/33WisxojaJUvhShpwBkw4XJZI2ZLedycr/Bcd8fQ2dOWdtfVzFaAoOk?= =?us-ascii?q?cYQAE/YBM+hfr4n4vVQOrB2+DhSoCO7gzjJEg3n71rA43es8CwHLxA4vH9wOvn?= =?us-ascii?q?rar9v7KbkcXvyuwabS0TnOdelb1Svh5IXKdB0qvPGCXah3ccrU0UQhGBnFgU+Q?= =?us-ascii?q?qIf4Jj2U1+cNs3WB7+V6UeKklmkqpB9+oze1w8cjkJXGhoIUylDC6yp024k1Jd?= =?us-ascii?q?iiR056Zd6oCodftyafN4ZvRM4pXm9muCE/yrIcuJ67ejAHx449xx/QavyHbZKE?= =?us-ascii?q?4hX5VOaeOTt4hXRleKi+hxmo60SgxPf8WtG00VlQripFld7MumoR2BzU78iLUv?= =?us-ascii?q?x9/kSk2TaO1QDf8OZEIVo7lafdNpUvwaYwm4INvUjfGiL6gkb7ga+Mekk65+Sl?= =?us-ascii?q?5f7rb7X4qpKaKoR6kBvxMr40lcy6Gek4MhYBX2yc+emk0b3s50z5QLFTgv0oka?= =?us-ascii?q?nVrInWJcobq6KnGQNV3YEj6xGwDzeiztsUh2UILFVAeB6fjojpPU/BIOzgAPuh?= =?us-ascii?q?n1ihlC1nyvPGM7H7HJnBM3bOnK3hcLpj80JczRA8zdFb55JaELEBJ/fzV1fvu9?= =?us-ascii?q?3XFBA5Nha7zPrnCNV80IMRR3mCAqCcMKzIsF+I4vgjLPWLZI8QoDr9MeQq5+by?= =?us-ascii?q?jX8lnl8QZbWm0oESaHC8B/hmJ0SZYWHwgtoaCmcLvg8+TPTwh1GYUD5TYWyyX6?= =?us-ascii?q?Mm6T0hBoKmF9SLeof4r7WLxia2GtVtbWBLEF2WWSPnfo+eWvoILjmZIsJ7nyYs?= =?us-ascii?q?Wr2oSotn3har4lzU0b1ie8fO8zxQkoDgycJ846WHmAE78DV/D8Wb3kmCSmh1mi?= =?us-ascii?q?UDQDpgj/M3mlB01lrWifswuPdfD9EGoq4QXw=3D=3D?= X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: =?us-ascii?q?A0AJAQDN/XxYhjTVVdFdGwEBAQMBAQEJA?= =?us-ascii?q?QEBFgEBAQMBAQEJAQEBgw4BAQEBAXQKeBEHg0qKB5IVgjaNS4UrggsqhXgCgX8?= =?us-ascii?q?HPxgBAQEBAQEBAQEBARIBAQEICwsKHTCCMxuCGwEBAQMBIx0BGxIGBQEDAQsGA?= =?us-ascii?q?wILDQ0dAgIhAQERAQUBChIGExKIVQEDCwUIDpEYkQw/jAOCAwUBHIMJBYNQChk?= =?us-ascii?q?nAwpVgXcBAQEBAQUBAQEBAQEaAgYSixqCUBuCCoJZgl4FhyQMiG2KZTiGXYZ+h?= =?us-ascii?q?ASBd1GEPYNNhhuKGIcOFB6BFA8QgU0SHU8Ug2spIIFtOzWIbgEBAQ?= X-IPAS-Result: =?us-ascii?q?A0AJAQDN/XxYhjTVVdFdGwEBAQMBAQEJAQEBFgEBAQMBAQE?= =?us-ascii?q?JAQEBgw4BAQEBAXQKeBEHg0qKB5IVgjaNS4UrggsqhXgCgX8HPxgBAQEBAQEBA?= =?us-ascii?q?QEBARIBAQEICwsKHTCCMxuCGwEBAQMBIx0BGxIGBQEDAQsGAwILDQ0dAgIhAQE?= =?us-ascii?q?RAQUBChIGExKIVQEDCwUIDpEYkQw/jAOCAwUBHIMJBYNQChknAwpVgXcBAQEBA?= =?us-ascii?q?QUBAQEBAQEaAgYSixqCUBuCCoJZgl4FhyQMiG2KZTiGXYZ+hASBd1GEPYNNhhu?= =?us-ascii?q?KGIcOFB6BFA8QgU0SHU8Ug2spIIFtOzWIbgEBAQ?= X-IronPort-AV: E=Sophos;i="5.33,240,1477954800"; d="scan'208,217";a="209389842" Received: from mail-vk0-f52.google.com ([209.85.213.52]) by mail3-smtp-sop.national.inria.fr with ESMTP/TLS/AES128-GCM-SHA256; 16 Jan 2017 18:12:59 +0100 Received: by mail-vk0-f52.google.com with SMTP id r136so77070165vke.1 for ; Mon, 16 Jan 2017 09:12:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=+njywJ+vUqMnPKXriatgOOUW8uZPHr+cCzJoB3AdCT4=; b=gE4Zi2vSs2ejGdEdmP50oDzuiQevADvWEFGwr6rTEtCFdXsM8SgdOrPchXDwwQHbF7 vUcZuGpCdTeRA0ZRD1o1LiUSQqjRX4MK56x9MUwRafz6SNU1UQpu2xvvOtxQEryyVgYZ X+VoAnFO5R6uHzYCWsh4rsyYVagZlJj0nkfUImWXqN0VtEvq8hVU61NfaCTMpz7K/u+v kIT27pX0lBaoo4dZ3L7u2va61VZJCbSd/5js88KlWWPcU5oC/iTduzMI1GzqeqD5NJQd vmJ3csl30T6AVAR06X9OhN1TSEiibdL9p0MAaFCQZy7Tt9680fRne56wUZZD05L+A/o9 CDwg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=+njywJ+vUqMnPKXriatgOOUW8uZPHr+cCzJoB3AdCT4=; b=lh+AMhgBkCNGAr77SzL8QMv/Q+TDTunA5HPsdpm8t0RV1x6KBnjVZVjmZqfH4LtngL 9H+TXFc4zryk+JCskUaZJtUdC4uZvHbOOZdsD8rHfPgsripUXoIhWtJRT3DML1OTySWp XTVj0rJKNKt99EOBuWIjDcLfdhYEwNl/ej0lbnEArW2Pofb3Osz2/CZllLR6c/HWIY4h 3Vj9whOEWHkHwJfltXGJ4pQ3mVWcyqxOJ6U448XSj3PTmJ841EKsYnikFOwWQfpYLihr iCiQXWUc1vrBBdUvD+lomS9qSxhYBwrrL+6HqZlwJ/DDhukO9yH57+mkEdal24dmy2+V qfFw== X-Gm-Message-State: AIkVDXJNfmmXZhJCoeYHE4EFYmmdhisGSGpbrN/JS0Z85nzGDMiq5bxUAxRR9LTrlFCS4Tc+wDN9aeb0NfopNQ== X-Received: by 10.31.32.77 with SMTP id g74mr14359829vkg.122.1484586777630; Mon, 16 Jan 2017 09:12:57 -0800 (PST) MIME-Version: 1.0 Received: by 10.176.91.214 with HTTP; Mon, 16 Jan 2017 09:12:57 -0800 (PST) In-Reply-To: References: <20170101152022.GA1291@Magus.localnet> From: Eray Ozkural Date: Mon, 16 Jan 2017 20:12:57 +0300 Message-ID: To: Gabriel Scherer Cc: Caml List Content-Type: multipart/alternative; boundary=001a11469b2484de290546394b41 Subject: Re: [Caml-list] ANN: BER MetaOCaml N104, for OCaml 4.04.0 --001a11469b2484de290546394b41 Content-Type: text/plain; charset=UTF-8 Thank you, that's indeed relevant! On Mon, Jan 16, 2017 at 4:25 PM, Gabriel Scherer wrote: > For fast just-in-time compilation of OCaml code, you may be interested > in Benedikt Meurer's work on OCamlJit2 (the article is well-written > and easy to read): > > Just-In-Time compilation of OCaml byte-code > Benedikt Meurer, 2010 > https://arxiv.org/abs/1011.6223 > > On Mon, Jan 16, 2017 at 2:18 PM, Eray Ozkural > wrote: > > Hi Oleg, > > > > I have a question. Have you ever designed at length how to implement a > super > > fast *interpreted* version of metaocaml, or let me put it this way: do > you > > think if that is possible at all? > > > > Best, > > > > Eray > > > > On Sun, Jan 1, 2017 at 6:20 PM, Oleg wrote: > >> > >> > >> BER MetaOCaml N104 is a strict superset of OCaml 4.04.0 for ``writing > >> programs that generate programs''. BER MetaOCaml adds to OCaml the > >> type of code values (denoting ``program code'', or future-stage > >> computations), and two basic constructs to build them: > >> quoting and splicing. The generated code can be printed, stored in a > >> file -- or compiled and linked-back to the running program, thus > >> implementing run-time code optimization. A well-typed BER MetaOCaml > >> program generates only well-scoped and well-typed programs: > >> The generated code shall compile without type errors. > >> Staging-annotation-free BER MetaOCaml is identical to > >> OCaml; BER MetaOCaml can link to any OCaml-compiled library (and > >> vice versa); findlib and other tools can be used with BER MetaOCaml as > >> they are, in their binary form. > >> > >> BER MetaOCaml N104 comes with one minor and two notable improvements. > >> The minor improvement is the availability of the native MetaOCaml. If > >> the generator is compiled in native mode (using metaocamlopt), the > >> dynamically generated and run code will be natively-compiled as > >> well. The lack of native mode was the most frequently heard criticism > >> of MetaOCaml, although in my experience it hardly even > >> matters. Off-line code specialization seems to be far more prevalent > >> and useful than online one. Anyway, here we have it. > >> > >> The notable new features -- not seen in MetaOCaml (or MetaML, for that > >> matter) -- are generating pattern-matching expression with the > >> statically unknown number of clauses, and let-insertion as a > >> primitive. To wit, |genlet exp| inserts |let freshname = exp in ...| > >> somewhere in the generated code and returns |..| (unless > |exp| > >> is already syntactically a value such as a variable reference). > >> The let-statement is inserted at the most appropriate place. > >> > >> BER MetaOCaml N104 should be available though OPAM, hopefully soon. > >> In the meanwhile, it is available as a set of patches to the > >> OCaml 4.04.0 distribution. > >> http://okmij.org/ftp/ML/ber-metaocaml-104.tar.gz > >> See the INSTALL document in that archive. You need the source > >> distribution of OCaml 4.04.0, see the following URL for details. > >> > >> For more explanations, please see > >> http://okmij.org/ftp/ML/MetaOCaml.html > >> as well as ChangeLog and NOTES.txt in the BER MetaOCaml distribution. > >> > >> > >> -- > >> Caml-list mailing list. Subscription management and archives: > >> https://sympa.inria.fr/sympa/arc/caml-list > >> Beginner's list: http://groups.yahoo.com/group/ocaml_beginners > >> Bug reports: http://caml.inria.fr/bin/caml-bugs > > > > > > > > > > -- > > Eray Ozkural, PhD. Computer Scientist > > Founder, Gok Us Sibernetik Ar&Ge Ltd. > > http://groups.yahoo.com/group/ai-philosophy > -- Eray Ozkural, PhD. Computer Scientist Founder, Gok Us Sibernetik Ar&Ge Ltd. http://groups.yahoo.com/group/ai-philosophy --001a11469b2484de290546394b41 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Thank you, that's indeed relevant!

On Mon, Jan 16, 2017 at 4:25 PM= , Gabriel Scherer <gabriel.scherer@gmail.com> wrote:=
For fast just-in-time compilation of OCa= ml code, you may be interested
in Benedikt Meurer's work on OCamlJit2 (the article is well-written
and easy to read):

=C2=A0 Just-In-Time compilation of OCaml byte-code
=C2=A0 Benedikt Meurer, 2010
=C2=A0 https://arxiv.org/abs/1011.6223

On Mon, Jan 16, 2017 at 2:18 PM, Eray Ozkural <examachine@gmail.com> wrote:
> Hi Oleg,
>
> I have a question. Have you ever designed at length how to implement a= super
> fast *interpreted* version of metaocaml, or let me put it this way: do= you
> think if that is possible at all?
>
> Best,
>
> Eray
>
> On Sun, Jan 1, 2017 at 6:20 PM, Oleg <oleg@okmij.org> wrote:
>>
>>
>> BER MetaOCaml N104 is a strict superset of OCaml 4.04.0 for ``writ= ing
>> programs that generate programs''.=C2=A0 BER MetaOCaml add= s to OCaml the
>> type of code values (denoting ``program code'', or future-= stage
>> computations), and two basic constructs to build them:
>> quoting and splicing. The generated code can be printed, stored in= a
>> file -- or compiled and linked-back to the running program, thus >> implementing run-time code optimization. A well-typed BER MetaOCam= l
>> program generates only well-scoped and well-typed programs:
>> The generated code shall compile without type errors.
>> Staging-annotation-free BER MetaOCaml is identical to
>> OCaml; BER MetaOCaml can link to any OCaml-compiled library (and >> vice versa); findlib and other tools can be used with BER MetaOCam= l as
>> they are, in their binary form.
>>
>> BER MetaOCaml N104 comes with one minor and two notable improvemen= ts.
>> The minor improvement is the availability of the native MetaOCaml.= =C2=A0 If
>> the generator is compiled in native mode (using metaocamlopt), the=
>> dynamically generated and run code will be natively-compiled as
>> well. The lack of native mode was the most frequently heard critic= ism
>> of MetaOCaml, although in my experience it hardly even
>> matters. Off-line code specialization seems to be far more prevale= nt
>> and useful than online one. Anyway, here we have it.
>>
>> The notable new features -- not seen in MetaOCaml (or MetaML, for = that
>> matter) -- are generating pattern-matching expression with the
>> statically unknown number of clauses, and let-insertion as a
>> primitive. To wit, |genlet exp| inserts=C2=A0 |let freshname =3D e= xp in ...|
>> somewhere in the generated code and returns |.<freshname>.| = (unless |exp|
>> is already syntactically a value such as a variable reference).
>> The let-statement is inserted at the most appropriate place.
>>
>> BER MetaOCaml N104 should be available though OPAM, hopefully soon= .
>> In the meanwhile, it is available as a set of patches to the
>> OCaml 4.04.0 distribution.
>>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0http://okm= ij.org/ftp/ML/ber-metaocaml-104.tar.gz
>> See the INSTALL document in that archive. You need the source
>> distribution of OCaml 4.04.0, see the following URL for details. >>
>> For more explanations, please see
>>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0http://okmij.org/ftp= /ML/MetaOCaml.html
>> as well as ChangeLog and NOTES.txt in the BER MetaOCaml distributi= on.
>>
>>
>> --
>> Caml-list mailing list.=C2=A0 Subscription management and archives= :
>> https://sympa.inria.fr/sympa/arc/caml-list
>> Beginner's list:
http://groups.yahoo.com/g= roup/ocaml_beginners
>> Bug reports: http://caml.inria.fr/bin/caml-bugs<= br> >
>
>
>
> --
> Eray Ozkural, PhD. Computer Scientist
> Founder, Gok Us Sibernetik Ar&Ge Ltd.
> http://groups.yahoo.com/group/ai-philosophy=



--
=
Eray Ozku= ral, PhD. Computer Scientist
Founder, Gok Us Sibernetik Ar&Ge Ltd. <= br>http://groups.yahoo.com/group/ai-philosophy
--001a11469b2484de290546394b41--