Re: Dylan vs Julia
Răzvan Rotaru <[email protected]> Fri, 14 Feb 2014 19:03:37 +0200
| Newsgroups | gmane.comp.lang.dylan.gwydion.devel |
|---|---|
| Message-ID | <CAP33cnYOiyKy7g3LHF1dnCD+9z3wBT8-r1VKLevy5cuaw5XG7A@mail.gmail.com> |
On 14 February 2014 12:29, Gour <[email protected]> wrote: > Hello, > > while reading different stuff about Julia I did stumble upon its > Wikipedia page ( > http://en.wikipedia.org/wiki/Julia_%28programming_language%29) > where there is table comparing Julia with Common Lisp, Fortress and > Dylan. > > I'm not interested neither for Lisp nor for Fortress (which anyway seems > to be not alive), but wonder how does Julia compare with Dylan in > general. > > Afaik, one of the differences is that Julia JIT-ed, while Dylan produces > native executables which might impact the performance for end user. > Impact in what sense? Positive or negative? IMHO comparing performance of JIT and native executables in general, is wrong. There are more factors involved in the play. One would expect JIT to perform worse, because of the compilation overhead. It is however capable of doing optimisations at runtime which is not possible with a compiler, simply because it has more information available. I know for example that Java is capable of inlining a function at runtime, when it sees that it is called many times, and after a while to un-inline it, if it decides it is better to do so. And all that while your application runs. I guess that JIT systems are more dynamic in nature, and tend to be more suited for dynamic languages, while classic compilers traditionally leverage static type systems to deliver performance. I would worry more about static vs dynamic typing when looking at languages, rather than the actual technology chosen for the implementation. There are excellent and poor compilers, like there are excellent and poor JITs. Traditionally, dynamic languages were far behind static ones when it comes to performance. But this is changing. Java is the big player here (yes, Java is dynamic ... sort of). Julia is also an excellent example of a dynamic language with great performance. And LLVM helped a lot getting there. I wonder if compiling Julia to native code would produce faster code or not. > > Anything else which might be important to know and/or some reasons why > the creators of Julia were not e.g. happy with Dylan (amongst many other > languages) and pursued designing Julia? > Julia is designed for scientific computing, which means it is built to crunch numbers, and comes with an infrastructure to do this on big grids. It has matlab inspired syntax (which I find a little bit weird). Even e and pi are global constants. It has a lot of interesting features, I was tempted for a while to use it for my next project. But I didn't like their macro system. I don't know how it compares to dylan macros, since I am still learning these. They essentially have a special syntax for calling macros, which I consider a mistake. Macros are seen as a powerful but dangerous weapons, so they are fenced a little bit, to prevent users from hurting themselves. Their type system is brilliant (I haven't seen a dynamic language with type inference before), and is one of the secrets of achieving that performance. I don't know dylan, but I would guess that there are two major factors why they decided to build julia instead of using dylan: - fast numeric computing, executed on big grids - matlab syntax > > In the past I was playing with Haskell, but found that there is too much > monad talk and the language had too steep learning curve for some of > potential contributors to the project - multi-platfom GUI (desktop) app. > Yeah, Haskell is a beast, and hard to tame. This is probably one of the reasons it failed to become popular. I remember somebody saying that whoever manages to learn Haskell is too tired to use it anymore. My biggest disappointment with Haskell is their decision to use the type system to separate the pure from the unpure of the functional programming world. A immutable integer has a different type than a multable integer. This has a lot of unpractical consequences, IMHO. > > Later I was evaluating D, Ada, OCaml, F#, Nimrod, Rust...some are nice > languages, but most are lacking bindings for developing GUI desktop > applications and/or are more suitable as 'system' and not 'general > programming' language, iow. fiddling with low(er)-level stuff like > pointers etc. - we want to avoid C(++) - or have strange syntax like Rust. > > Iow. we're looking for some 'general programming' language suitable for > desktop app which is has good-enough performance and provide more > type-safety than e.g. Python (we have to call 3rd party lib for > computing planetary ephemeris and would like to use sqlite3 as app's > storage format). > The biggest library ecosystem that you can currently find is on the Java platform. Love or hate it, it's the safest place you can be, if you care about libraries. And the best news is that you don't need to deal with Java anymore to get into this ecosystem: you have Scala, Clojure and Groovy, just to name a few. When I'm choosing a language/technology to invest in, my number one feature to look for are macros. I consider them to be the most powerful tool that you can have at your disposal (see *http://paulgraham.com/hundred.html <http://paulgraham.com/hundred.html>*). Then, the second feature is multi-core. This is new, and mandatory, given the current hardware development. A winning strategy/technology has not yet emerged. Erlang seems to be the wise old man, (with long white beard) that has found the answer long time ago, but is seen as an insane old man by everyone else. Clojure is inspired from Erlang, and has some revolutionary ideas in this area. > > I saw a thread which 'claimed' that e.g. Julia is e.g not quicker than > Python/Cython although it seems it was due usage of int32, but wonder > what could one expect from Dylan? > Last time I checked Python was slower than Java. I would bet that Julia beats both Java and Python in terms of performance. > > So, anyone somewhat familiar with boh Julia & Dylan can share what would > be some of Dylan's pros in comparison with the Julia? > > Are there some major features missing in either language which I am not > seeing or the two can't be easily compared at all? > > > Sincerely, > Gour > > p.s. I sent almost the same meesage to julia-user and I'm not trolling, > but simply interested for any input no matter of bias to help me decide > better. > > -- > It is far better to discharge one's prescribed duties, even though > faultily, than another's duties perfectly. Destruction in the course > of performing one's own duty is better than engaging in another's > duties, for to follow another's path is dangerous. > > http://www.atmarama.net | Hlapicina (Croatia) | GPG: 52B5C810 > _______________________________________________ > hackers mailing list > [email protected] > https://lists.opendylan.org/mailman/listinfo/hackers > _______________________________________________ hackers mailing list [email protected] https://lists.opendylan.org/mailman/listinfo/hackers