You are not logged in.

#1 2009-12-08 21:59:00

Basu
Member
From: Cornell University
Registered: 2006-12-15
Posts: 296
Website

Higher level than C++, faster than Java, is there such a thing?

I'm currently gathering ideas for a honors thesis where I build a programming language over the course of a year. I'm currently what problem domains such a language should target. I'm wondering if there is a language that is higher-level and easier to program in than C++, but faster to start than Java? In many ways I'm looking for a language that's suitable for writing desktop programs in without having to muck about in manual memory management.  The first thing that comes to my mind is C#/Mono but I've never used and I have know idea how it performs. Any recommendations?


The Bytebaker -- Computer science is not a science and it's not about computers
Check out my open source software at Github

Offline

#2 2009-12-08 22:35:32

ewaller
Administrator
From: Pasadena, CA
Registered: 2009-07-13
Posts: 19,804

Re: Higher level than C++, faster than Java, is there such a thing?

Look at Python or Ruby.  (I prefer Python)


Nothing is too wonderful to be true, if it be consistent with the laws of nature -- Michael Faraday
Sometimes it is the people no one can imagine anything of who do the things no one can imagine. -- Alan Turing
---
How to Ask Questions the Smart Way

Offline

#3 2009-12-08 22:44:32

yasen
Member
From: Bulgaria
Registered: 2009-03-05
Posts: 39

Re: Higher level than C++, faster than Java, is there such a thing?

ewaller wrote:

Look at Python or Ruby.  (I prefer Python)

Both are nice dynamic languages, much higher level than C++, but they're not faster than Java.
I don't know if it is true but I've heard and read that the latest incarnations of the JVM on major platforms are very well optimized and get you C-like performance from your code. No idea if it's true, tho.

Anyway - high level languages that are compiled, off the top of my head - D (own compiler), Vala, Nimrod (both 'compile' to C code).

I would say Haskell, as it is compiled but I gather it's not as much 'high-level', and more like 'whole-other-out-of-this-world-batshit-insane-level'.

Offline

#4 2009-12-08 22:44:33

ataraxia
Member
From: Pittsburgh
Registered: 2007-05-06
Posts: 1,553

Re: Higher level than C++, faster than Java, is there such a thing?

ewaller wrote:

Look at Python or Ruby.  (I prefer Python)

... as you reply to somebody with a Python logo in his avatar lol

To the OP: maybe Haskell? It's quite different, but is both high-level and, as it's compiled, has good performance.

Offline

#5 2009-12-08 22:45:20

Trent
Member
From: Baltimore, MD (US)
Registered: 2009-04-16
Posts: 990

Re: Higher level than C++, faster than Java, is there such a thing?

"faster" is relative.  Not sure what you mean by "faster to start"; assume you mean the time it takes to load the JVM and whatever libraries are needed, so you're looking for a language with low overhead.

In any case, yes, Python is probably a good place to start.  If that's too slow, my next thought would be Perl, but I am well aware that many people would disagree with me.

Offline

#6 2009-12-08 22:45:44

SoleSoul
Member
From: Israel
Registered: 2009-06-29
Posts: 319

Re: Higher level than C++, faster than Java, is there such a thing?

this thread may help you.

Offline

#7 2009-12-08 23:10:59

gajo
Member
Registered: 2008-04-01
Posts: 93
Website

Re: Higher level than C++, faster than Java, is there such a thing?

C# is shit, but that's my personal opinion (and yes, i can actually get some facts for that)
Java is fast, I wouldn't be surprised that on some rare occasions it can be made faster than C++03 since in most cases, you return things by value in C++, while in java reference is fine (though java and C# have no notion of const correctness, not exactly sure for C#, but i think I'm right)
and if you absolutely don't want to do any of the memory management in C++, just use a smart pointer - sometimes you'll end up needing to use them anyhow; only shame about C++'s current standard is that it has only one (hmm?) smart pointer, called auto_ptr which isn't very useful, and iterating through STL's containers requires a lot of code, much more than in other OO languages. (C++0x fixes both of these issues, along with rvalue references - which improve speed while allowing const correct code - you can find most of the new stuff in gcc 4.4 and higher, just compile with -std=c++0x)

some people mentioned functional languages, don't go there if you don't have the time unless you know some already, the syntax, way of thinking, it's quite different, you can't just look at the code and figure out what it's doing, it's no python smile

Offline

#8 2009-12-08 23:11:53

chpln
Member
From: Australia
Registered: 2009-09-17
Posts: 361

Re: Higher level than C++, faster than Java, is there such a thing?

I also think Haskell fills these requirements nicely.  As for seeing how a language performs, the Language Shootout is rather interesting.

Offline

#9 2009-12-09 01:21:44

skottish
Forum Fellow
From: Here
Registered: 2006-06-16
Posts: 7,942

Re: Higher level than C++, faster than Java, is there such a thing?

yasen wrote:

... snip ...

I would say Haskell, as it is compiled but I gather it's not as much 'high-level', and more like 'whole-other-out-of-this-world-batshit-insane-level'.

This is priceless.

Offline

#10 2009-12-09 01:29:55

HashBox
Member
Registered: 2009-01-22
Posts: 271

Re: Higher level than C++, faster than Java, is there such a thing?

I know it's C++, but honestly I think something like QT nearly fits in to the topic of this discussion. It adds enough pre-processing to C++ that it is in some ways like using a different language, and it is sufficiently high level while feeling pretty fast.

Offline

#11 2009-12-09 01:41:57

Basu
Member
From: Cornell University
Registered: 2006-12-15
Posts: 296
Website

Re: Higher level than C++, faster than Java, is there such a thing?

I know that Python starts up early, but I know that it's slower than Java for anything that's longer running or algorithmically intensive. The Java JIT technology is some of the most advanced on the planet. It seems to me that either Haskell or one of the compile-to-C languages are the best shot.
I've heard of Vala, but Nimrod seems very interesting too, especially since it has good bindings. I also like how the compiler for it is well-documented, which is cool since I'm planning on implementing a language soon myself.

Last edited by Basu (2009-12-09 01:42:20)


The Bytebaker -- Computer science is not a science and it's not about computers
Check out my open source software at Github

Offline

#12 2009-12-09 03:16:18

uncholowapo
Member
From: US
Registered: 2009-03-29
Posts: 238

Re: Higher level than C++, faster than Java, is there such a thing?

When I hear "high-level" I think Ada...

Offline

#13 2009-12-09 03:25:19

jwwolf
Member
Registered: 2009-06-29
Posts: 74

Re: Higher level than C++, faster than Java, is there such a thing?

You should check out lolcode

Offline

#14 2009-12-09 04:57:08

ewaller
Administrator
From: Pasadena, CA
Registered: 2009-07-13
Posts: 19,804

Re: Higher level than C++, faster than Java, is there such a thing?

ataraxia,

I confess, I never even look at the avatars -- but it is funny.

Basu, et al.,

I actually took your question to mean in which language would it be possible to create useful programs rapidly.  As such, I stand by Python.  I often use things such as PyQt to prototype C++ Qt projects.

Taken the other way, I agree that if quickly means the time to invoke an instance of a program Python might not be the ideal. 
Stated without proof, my gut feeling is that a compiled language with static links to any libraries is going to be the fastest out of the blocks.


Nothing is too wonderful to be true, if it be consistent with the laws of nature -- Michael Faraday
Sometimes it is the people no one can imagine anything of who do the things no one can imagine. -- Alan Turing
---
How to Ask Questions the Smart Way

Offline

#15 2009-12-09 06:02:50

shock
Member
Registered: 2009-12-05
Posts: 25

Re: Higher level than C++, faster than Java, is there such a thing?

C# which is endorsed by ECMA a lot. Is one such language which is dominating the market right now.

Offline

#16 2009-12-09 07:38:57

pauldonnelly
Member
Registered: 2006-06-19
Posts: 776

Re: Higher level than C++, faster than Java, is there such a thing?

Common Lisp is exactly what you've asked for. If you're actually planning on doing a project, I'll give you the hint that ECL is an implementation to watch if you need to create little binaries. SBCL is a good old standby, and probably the fastest free Lisp for most uses.

You're just looking for inspiration though, right?

Last edited by pauldonnelly (2009-12-09 07:42:51)

Offline

#17 2009-12-09 07:43:43

XFire
Member
From: UK
Registered: 2008-05-11
Posts: 192

Re: Higher level than C++, faster than Java, is there such a thing?

What about Lua? It compiles, but I am ensure to its speed in relation to C++ and Java.


There is a difference between bleeding [edge] and haemorrhaging. - Allan

Offline

#18 2009-12-09 22:47:33

otti
Member
Registered: 2006-12-18
Posts: 64

Re: Higher level than C++, faster than Java, is there such a thing?

Offline

#19 2009-12-09 22:59:30

choener
Member
Registered: 2008-01-10
Posts: 22

Re: Higher level than C++, faster than Java, is there such a thing?

One more for Haskell, this time with a link to Hackage http://hackage.haskell.org/packages/arc … -list.html
Oh, and writing Compilers is a really strong point of Haskell! Or embedding a Domain-specific language.

Offline

#20 2009-12-09 23:21:22

Basu
Member
From: Cornell University
Registered: 2006-12-15
Posts: 296
Website

Re: Higher level than C++, faster than Java, is there such a thing?

I've actually been thinking more about the language that I'm going to develop for my thesis and I'm pretty certain that I'll write the compiler for it in Haskell (if I learn enough of it in one summer). I'm certainly going to look into writing more run-of-the-mill programs and exploring it in general. I'd love to look around the other languages and I will if I can get time. Guess I'll be learning Haskell and Scala together next year.


The Bytebaker -- Computer science is not a science and it's not about computers
Check out my open source software at Github

Offline

#21 2009-12-10 00:04:17

wuischke
Member
From: Suisse Romande
Registered: 2007-01-06
Posts: 630

Re: Higher level than C++, faster than Java, is there such a thing?

You might appreciate Write yourself a scheme in 48 hours, it should give you a quick start on implementing a language on top of Haskell while introducing you to Haskell. (Note: I haven't followed the tutorial yet.)

I found The 90 Minute Scheme to C compiler (the explanation is done in a 90 minutes presentation, writing the compiler takes a bit longer) to be a good overview about source transformations. While I can't apply most of the techniques yet, I finally have an understanding on how such a transformation is done.

Edit: Removed ambiguity.

Last edited by wuischke (2009-12-10 00:04:58)

Offline

#22 2009-12-10 00:48:49

nagnatron
Member
From: Belgrade, Serbia.
Registered: 2009-06-05
Posts: 10

Re: Higher level than C++, faster than Java, is there such a thing?

^ Looks very cool. Thanks.

Offline

#23 2009-12-10 09:52:47

aheaume
Member
Registered: 2009-12-09
Posts: 10

Re: Higher level than C++, faster than Java, is there such a thing?

Basu wrote:

a language that is higher-level and easier to program in than C++, but faster to start than Java?

Isn't this the purpose of Go ?

Offline

#24 2009-12-10 10:43:20

Ranguvar
Member
Registered: 2008-08-12
Posts: 2,549

Re: Higher level than C++, faster than Java, is there such a thing?

D or Haskell, yeah.

Python, maybe, with Unladen Swallow.

Offline

#25 2009-12-10 11:17:06

Stefan Husmann
Member
From: Germany
Registered: 2007-08-07
Posts: 1,391

Re: Higher level than C++, faster than Java, is there such a thing?

ocaml?

Offline

Board footer

Powered by FluxBB