![]() |
Aspen
For anyone interested in new languages, Aspen is a new programming language that is being developed by a grad student at Purdue. Myself and another undergraduate are being used to see how easy the language is to learn and where improvements can be made.
The idea behind Aspen is to provide a language that requires less code, retains the power and comparable performance of C++, and includes a runtime manager that dynamically allocates threads to handle loads. Aspen is tailored to networking programs such as a webserver. The language is not publicly released yet but the initial paper on Aspen can be found here: http://cobweb.ecn.purdue.edu/~vpai/P...ya-ppopp07.pdf There is still much work to be done and the designer is on an internship at Intel, but hopefully Aspen will be ready for release by the end of the year. |
So.. Which aspects of this language require the invention of a new language, rather than the introduction of libraries atop an existing language?
|
I've read the abstract. One could wonder what "less lines of code" means, ultimately. One could also question the statistical significance of the numbers quoted. Is the language deemed to be useful in other than web applications, with the same perceived benefits? Are these issues addressed, with scientific soundness, in the remainder of the paper?
|
Quote:
Quote:
Quote:
Quote:
Quote:
|
The paper doesn't go into many details of the language syntax. For instance, what does the >>> operator do, and how are objects chained via the ||| operator? What features does the language have that would prevent it from being implemented as a C++ library?
Would it be possible to provide a few additional code examples? |
Quote:
:
somevar >>> othervar;i.e. :
funct1() ||| funct2(x) ||| funct3() >>> resultvar;To answer your question about the ||| operator, there are two flavors of this. One is in the root module declaration. Specified under "Flow:" the ||| tells the parser to establish queue and everything else needed to flow output from module x to module y. The other use of ||| is within program that takes return values from a function and pipes them into another function. :
funct1(x) ||| funct2(y) ||| funct3(z) >>> resultvar;Quote:
Im not sure if I am authorized to distribute sample code yet. I'll check on that as well. |
Quote:
Quote:
:
resultvar = funct1 z $ funct2 y $ funct3 xQuote:
|
Forgive my ignorance, but I do not know the answer to your question and my coworkers have not been detailed in their responses. I'll post one of their responses and answer what I can, and hopefully you can come to your own conclusion.
One response to your question. Quote:
:
/* The following are forward declarations to reference code not found in this particular source file. I dont believe all of these are necessary for an echo server but seem to be placed in out of habit by the programmer.I said its trivial because Aspen literally handles everything in this example. The built-in functions NetworkInput and NetworkOutput do all the work. We simply tell where NetworkInput should send its payload. The Empty Module is regrettably necessary at the moment. Due to a bug in the compiler, Aspen will give an error if you do not include a user-made module. Keep in mind, not only does Aspen make programming easier by interpreting a logical flowchart, but the above code is a parallelized echo server that will exhibit excellent scalability and load balancing. Id be happy to answer any questions about the example code as well as take modification suggestions. |
As an update and clarification, Aspen is a source to source compiler. So presumably anything that can be done in C/C++ can be done in Aspen. Im told that with macro's, there really isnt anything about Aspen that cannot be done in a library, but the motivation to write a new language is ease of programming.
Aspen's focus is to not limit parallelism possibilities, but at the same time only exposing a necessary level of parallelism to the programmer. |
| All times are GMT -5. The time now is 2:33 AM. |
Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC