Live data from Hacker News

Graal and Truffle could accelerate programming language design

medium.com

181–190 of 204 posts

Re: Graal and Truffle could accelerate programming language design

#181
post #56

Earlier quoted context omitted.

> BASIC is a good demonstration of why the platonic ideal language is wrong That's often my point when people bring up arguments against a language that seems a bit more complex (Perl), or for language simplicity (Python). Some complexity falls into a sliding scale where there is more cognitive load while learning, but it pays of in the every day usage. The siple example of an extreme end of this is APL. If you can i…

> If you can internalize and understand the extremely concise and powerful syntax and semantics of the language (I haven't), you can do amazing things very quickly Not to mention figuring out how to type APL -- that's where I got stuck.

Try J then. It uses the ASCII character set, and has added some concepts that APL seems to be adopting. [1] And it is amazing what you can do once you have put some time into it. Jd and Jdb, both database apps for J beat Spark/Shark and others at the big data game. I'd call that pretty powerful. Similar to the way qdb/k is used a lot in the finance sector for ticker data, but J is opensource. [1] jsoftware.com

Re: Graal and Truffle could accelerate programming language design

#182

> Since the dawn of computing our industry has been engaged on a never ending quest to build the perfect language. Except it really hasn't. The industry is going to use whatever language has the bare minimum feature set they value at the moment and no more. Call me cynical but my point of view is: if the industry were really striving for perfection, there would be no COBOL or BASIC, for instance. Lisp had already bee…

The majority never picks the best and markets do not optimize as much as some people think. Whether it's movies, arts, books, music, politicians, keyboards or programming languages, the most popular choices are practically never the best ones. Which is probably why a technocracy in which every voter must pass a fact-based proficiency test before being allowed to vote might trump democracy. Not sure, just wanted to ch…

You used 'trump' next to 'democracy' ;)

The majority and optimizing markets are at odds in your statement. Look at qdb/k, it is very expensive, programmers cost a bunch, but it is used by the big financial houses. I am sure they are glad it is not too popular and affordable.

I do agree that I don't like central planning, and design by committee, but those are different than your market statement or technocracy comment.

Movies, arts, books, music...horses for courses, best for what moment? I like action films, I like high-brow, arthouse stuff too. Same with books. I am glad I have a choice for the moment at hand.

When I was a young intellect, I succumbed to that elitist attitude of 'the best', and 'they don't know what's good for themselves' which is funny because I grew up in a poor, working-class neighborhood in Brooklyn in the late 60s/early 70s. Elitists were the guys from NY as well, but who wore black berets to film class at TSOA/NYU (three in my class alone!).

Re: Graal and Truffle could accelerate programming language design

#183

Here is a video of a Graal/Truffle talk given by a researcher at Oracle (presented at Mozilla in 2013): https://air.mozilla.org/one-vm-to-rule-them-all/

This is quite outdated. here is an overview of Graal/Truffle papers and tutorials: https://wiki.openjdk.java.net/display/Graal/Publications+and...

[deleted]

Re: Graal and Truffle could accelerate programming language design

#184

Before anyone gets too excited, make sure you look at what a compiler using Truffle actually looks like, and remember that Java is far from an ideal language for writing a compiler. I'll use their SimpleLanguage (their primary tutorial lang) as an example. Parser [1] shows how lack of sum types makes code messy. Lots of "factory.createStringLiteral" kind of calls. At least Java has a mature parser generator. Implemen…

Urrgh. This just reminds me of why I gave up on android app development, and the JVM ecosystem as a whole: it tests my ability to put up with bullshit.

I agree. I wanted to really write native Android apps, not HTML5 or even use the NDK with C/C++. It is just too much stuff. The downloads, the verbosity of Java, the lack of a slick toolchain (Android Studio is getting close, I guess), and a slew of other incoherencies.

I don't cut slack for Obj-C on iOS either.

I've had great fun with two products for Android/iOS and Mac/PC/Linux:

[1] Godot game engine. I followed the introduction and had an app on my Android phone in 10 minutes. A little hack in the background, but hey, for gaming it is great.

[2] 8th - a dialect of Forth - you write Forth-like 8th, and voilà it's running on your Anroid, PC, Mac, iOS device!

[1] https://godotengine.org/

[2] http://8th-dev.com/about8th.html#cross

Re: Graal and Truffle could accelerate programming language design

#185

Earlier quoted context omitted.

What would that look like?

((:include "stdio.h") (const char * message = "Like this.\n") (int main ((int argc) (char * * argv)) (printf message) (return 0)))

Ah.

Re: Graal and Truffle could accelerate programming language design

#186
post #184

Earlier quoted context omitted.

Urrgh. This just reminds me of why I gave up on android app development, and the JVM ecosystem as a whole: it tests my ability to put up with bullshit.

I agree. I wanted to really write native Android apps, not HTML5 or even use the NDK with C/C++. It is just too much stuff. The downloads, the verbosity of Java, the lack of a slick toolchain (Android Studio is getting close, I guess), and a slew of other incoherencies. I don't cut slack for Obj-C on iOS either. I've had great fun with two products for Android/iOS and Mac/PC/Linux: [1] Godot game engine. I followed t…

I have not used godot up to now, as I am wary of engines that require me to learn a scripting language used nowhere else. Is it any good?

Oh, and I've heard React Native's not so bad for mobile.

Re: Graal and Truffle could accelerate programming language design

#187

There's actually a fairly long history of cross-language VMs, with various degrees of success. What usually happens is that they work fine for languages that look, semantically, basically like the native language on the VM. So LLVM works well as long as your language is mostly like C (C, C++, Objective-C, Rust, Swift). Parrot works if you language is mostly like Perl 6 (Perl, Python, PHP, Ruby). .NET works if your la…

I agree with your entire comment. However, I also agree the point the op authors make about tooling being reimplemented time and time again, taking years to get anywhere near the point represented by the 1st 9-point wishlist. What the programming field could do, which would be awesome, would be to implement language category backends that follow your "mostly like" categorization. These backends would be engineered to…

We already that in the form of Lisp and Smalltalk. Sadly that's not what the majority of programmers want to use.

Re: Graal and Truffle could accelerate programming language design

#188

Here is a video of a Graal/Truffle talk given by a researcher at Oracle (presented at Mozilla in 2013): https://air.mozilla.org/one-vm-to-rule-them-all/

This is quite outdated. here is an overview of Graal/Truffle papers and tutorials: https://wiki.openjdk.java.net/display/Graal/Publications+and...

Is this one less outdated? https://www.youtube.com/watch?v=FJY96_6Y3a4

Re: Graal and Truffle could accelerate programming language design

#189

> Since the dawn of computing our industry has been engaged on a never ending quest to build the perfect language. Except it really hasn't. The industry is going to use whatever language has the bare minimum feature set they value at the moment and no more. Call me cynical but my point of view is: if the industry were really striving for perfection, there would be no COBOL or BASIC, for instance. Lisp had already bee…

> "They had to ditch the (almost) perfect wheel for a cheaper square one."

Lisp was slower than C when speed mattered most. If you can't see why that would be an issue, I suggest trying to write a game for a home computer from the 1980s.

Re: Graal and Truffle could accelerate programming language design

#190

Earlier quoted context omitted.

To be fair, Oracle gives you things such as VirtualBox, MySql, Java, Netbeans etc for free. That's not too bad for an 'evil' company.

No it doesn't, they are made by Sun Microsystems, they are free because of Sun, not Oracle.

They were project from Sun Microsystems originally, but Sun Microsystems doesn't exist anymore. Oracle have chosen to keep some of the Sun products open/free (they've closed support for others, such as OpenSolaris, which was continued through an open-source fork).
Post reply on HN