msc-projects-14.html
changeset 341 c3ae73992b49
parent 340 13e54dac5ff0
child 342 699d7815bf17
equal deleted inserted replaced
340:13e54dac5ff0 341:c3ae73992b49
    89   (remember Python and Ruby both need nearly 30 seconds to process 28(!) <code>a</code>s, and Scala's
    89   (remember Python and Ruby both need nearly 30 seconds to process 28(!) <code>a</code>s, and Scala's
    90   official matcher maxes out at 4,600 <code>a</code>s). My matcher is approximately
    90   official matcher maxes out at 4,600 <code>a</code>s). My matcher is approximately
    91   85 lines of code and based on the concept of 
    91   85 lines of code and based on the concept of 
    92   <A HREF="http://lambda-the-ultimate.org/node/2293">derivatives of regular expressions</A>.
    92   <A HREF="http://lambda-the-ultimate.org/node/2293">derivatives of regular expressions</A>.
    93   These derivatives were introduced in 1964 by <A HREF="http://en.wikipedia.org/wiki/Janusz_Brzozowski_(computer_scientist)">
    93   These derivatives were introduced in 1964 by <A HREF="http://en.wikipedia.org/wiki/Janusz_Brzozowski_(computer_scientist)">
    94   Janusz Brzozowski</A>, but according to this 
    94   Janusz Brzozowski</A>, but according to this
    95   <A HREF="http://www.cl.cam.ac.uk/~so294/documents/jfp09.pdf">paper</A> had been lost in the &ldquo;sands of time&rdquo;.
    95   <A HREF="http://www.cl.cam.ac.uk/~so294/documents/jfp09.pdf">paper</A> had been lost in the &ldquo;sands of time&rdquo;.
    96   The advantage of derivatives is that they side-step completely the usual 
    96   The advantage of derivatives is that they side-step completely the usual 
    97   <A HREF="http://hackingoff.com/compilers/regular-expression-to-nfa-dfa">translations</A> of regular expressions
    97   <A HREF="http://hackingoff.com/compilers/regular-expression-to-nfa-dfa">translations</A> of regular expressions
    98   into NFAs or DFAs, which can introduce the exponential behaviour exhibited by the regular
    98   into NFAs or DFAs, which can introduce the exponential behaviour exhibited by the regular
    99   expression matchers in Python and Ruby.
    99   expression matchers in Python and Ruby.
   157   efficient machine code that can be run on a CPU or virtual machine.
   157   efficient machine code that can be run on a CPU or virtual machine.
   158   A compiler for a simple functional language generating X86 code is described
   158   A compiler for a simple functional language generating X86 code is described
   159   <A HREF="https://github.com/chameco/Shade">here</A>.
   159   <A HREF="https://github.com/chameco/Shade">here</A>.
   160   I recently implemented a very simple compiler for an even simpler functional
   160   I recently implemented a very simple compiler for an even simpler functional
   161   programming language following this 
   161   programming language following this 
   162   <A HREF="http://www.cs.princeton.edu/~dpw/papers/tal-toplas.pdf">paper</A> 
   162   <A HREF="https://www.cs.princeton.edu/~dpw/papers/tal-toplas.pdf">paper</A> 
   163   (also described <A HREF="http://www.cs.princeton.edu/~dpw/papers/tal-tr.pdf">here</A>).
   163   (also described <A HREF="https://www.cs.princeton.edu/~dpw/papers/tal-tr.pdf">here</A>).
   164   My code, written in <A HREF="http://www.scala-lang.org/">Scala</A>, of this compiler is 
   164   My code, written in <A HREF="http://www.scala-lang.org/">Scala</A>, of this compiler is 
   165   <A HREF="http://www.dcs.kcl.ac.uk/staff/urbanc/compiler.scala">here</A>.
   165   <A HREF="http://www.dcs.kcl.ac.uk/staff/urbanc/compiler.scala">here</A>.
   166   The compiler can deal with simple programs involving natural numbers, such
   166   The compiler can deal with simple programs involving natural numbers, such
   167   as Fibonacci numbers or factorial (but it can be easily extended - that is not the point).
   167   as Fibonacci numbers or factorial (but it can be easily extended - that is not the point).
   168   </p>
   168   </p>
   621 </TD>
   621 </TD>
   622 </TR>
   622 </TR>
   623 </TABLE>
   623 </TABLE>
   624 
   624 
   625 <P>
   625 <P>
   626 <!-- hhmts start --> Last modified: Sun Nov  9 22:52:32 GMT 2014 <!-- hhmts end -->
   626 <!-- hhmts start --> Last modified: Sun Nov  9 23:00:48 GMT 2014 <!-- hhmts end -->
   627 <a href="http://validator.w3.org/check/referer">[Validate this page.]</a>
   627 <a href="http://validator.w3.org/check/referer">[Validate this page.]</a>
   628 </BODY>
   628 </BODY>
   629 </HTML>
   629 </HTML>