Re : ANN: Dao language 1.0.1 with SDL and OpenGL bindings

Thank you,

Could you quickly enumerate what are the advantages of Dao comparing with other existing interpreted languages like Java,Python,Perl,Ruby ?
Is it possible to compile Dao code to native machine code ?

Julien

— En date de?: Ven 5.6.09, Limin Fu a ?crit?:de: Limin Fu
Objet: [SDL] ANN: Dao language 1.0.1 with SDL and OpenGL bindings
?: sdl at lists.libsdl.org
Date: Vendredi 5 Juin 2009, 22h15

Hi,

Dao is a simple yet powerful object-oriented programming language with
many advanced features including, soft (or optional) typing, BNF-like
macro system, regular expression, multi-dimensional numeric array,
closure, coroutine, asynchronous function call for concurrent
programming etc. Dao provides a rich set of standard data types,
methods and libraries. Dao is implemented as a light and efficient
virtual machine with very transparent C programming interfaces, which
make it easy to extend Dao with C/C++ or embed Dao into C/C++ programs.

Currently a number of modules have been included, in particular, modules binding SDL and OpenGL are included. Most of the functions are wrapped as they are, namely, with the same function prototypes their C versions. Most of the structures are also wrapped as well. This release might be useful for somebody wants to play with SDL and OpenGL.

An IDE named Dao Studio for Dao is also released at the same time as Dao. This IDE includes a syntax highlighted code editor and console, and supports Edit&Continue debugging mode.

Links:
http://www.daovm.net

http://www.daovm.net/dao/gallery_en
http://www.daovm.net/dao/download_en

Have fun,

Limin Fu

-----La pi?ce jointe associ?e suit-----


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

Java is not interpreted! :)On Mon, Jun 8, 2009 at 10:20 AM, julien CLEMENT wrote:

Thank you,

Could you quickly enumerate what are the advantages of Dao comparing with
other existing interpreted languages like Java,Python,Perl,Ruby ?
Is it possible to compile Dao code to native machine code ?

Julien

— En date de : Ven 5.6.09, Limin Fu a ?crit :

De: Limin Fu
Objet: [SDL] ANN: Dao language 1.0.1 with SDL and OpenGL bindings
?: sdl at lists.libsdl.org
Date: Vendredi 5 Juin 2009, 22h15

Hi,

Dao is a simple yet powerful object-oriented programming language with many
advanced features including, soft (or optional) typing, BNF-like macro
system, regular expression, multi-dimensional numeric array, closure,
coroutine, asynchronous function call for concurrent programming etc. Dao
provides a rich set of standard data types, methods and libraries. Dao is
implemented as a light and efficient virtual machine with very transparent C
programming interfaces, which make it easy to extend Dao with C/C++ or embed
Dao into C/C++ programs.

Currently a number of modules have been included, in particular, modules
binding SDL and OpenGL are included. Most of the functions are wrapped as
they are, namely, with the same function prototypes their C versions. Most
of the structures are also wrapped as well. This release might be useful for
somebody wants to play with SDL and OpenGL.

An IDE named Dao Studio for Dao is also released at the same time as Dao.
This IDE includes a syntax highlighted code editor and console, and supports
Edit&Continue debugging mode.

Links:
http://www.daovm.net
http://www.daovm.net/dao/gallery_en
http://www.daovm.net/dao/download_en

Have fun,

Limin Fu

-----La pi?ce jointe associ?e suit-----


SDL mailing list
SDL at lists.libsdl.org <http://mc/compose?to=SDL at lists.libsdl.org>
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

That’s right, the source is compiled into byte code which is itself interpreted :slight_smile:

— En date de?: Lun 8.6.09, Paulo Pinto a ?crit?:de: Paulo Pinto
Objet: Re: [SDL] Re : ANN: Dao language 1.0.1 with SDL and OpenGL bindings
?: “A list for developers using the SDL library. (includes SDL-announce)”
Date: Lundi 8 Juin 2009, 10h53

Java is not interpreted! :slight_smile:

On Mon, Jun 8, 2009 at 10:20 AM, julien CLEMENT <@Julien_Clement1> wrote:

Thank you,

Could you quickly enumerate what are the advantages of Dao comparing with other existing interpreted languages like Java,Python,Perl,Ruby ?
Is it possible to compile Dao code to native machine code ?

Julien

— En date de?: Ven 5.6.09, Limin Fu a ?crit?:

De: Limin Fu
Objet: [SDL] ANN: Dao language 1.0.1 with SDL and OpenGL bindings
?: sdl at lists.libsdl.org

Date: Vendredi 5 Juin 2009, 22h15

Hi,

Dao is a simple yet powerful object-oriented programming language with
many advanced features including, soft (or optional) typing, BNF-like
macro system, regular expression, multi-dimensional numeric array,
closure, coroutine, asynchronous function call for concurrent
programming etc. Dao provides a rich set of standard data types,
methods and libraries. Dao is implemented as a light and efficient
virtual machine with very transparent C programming interfaces, which
make it easy to extend Dao with C/C++ or embed Dao into C/C++ programs.

Currently a number of modules have been included, in particular, modules binding SDL and OpenGL are included. Most of the functions are wrapped as they are, namely, with the same function prototypes their C versions. Most of the structures are also wrapped as well. This release might be useful for somebody wants to play with SDL and OpenGL.

An IDE named Dao Studio for Dao is also released at the same time as Dao. This IDE includes a syntax highlighted code editor and console, and supports Edit&Continue debugging mode.

Links:
http://www.daovm.net

http://www.daovm.net/dao/gallery_en
http://www.daovm.net/dao/download_en

Have fun,

Limin Fu

-----La pi?ce jointe associ?e suit-----


SDL mailing list
SDL at lists.libsdl.org

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org


SDL mailing list

SDL at lists.libsdl.org

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

-----La pi?ce jointe associ?e suit-----


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

In what current JVM may I ask?

It depends on which JVM you run the bytecodes. You cannot say that Java is
interpreted since it depends on the implementation, there is
nothing in the language specification that says “you are only allowed to
have implement interpreters for this language”.

You have JVMs that compile all bytecodes before execution, others do only
parcial compilation depending on a specific threshold, others are
100% interpreters, and you can even compile to pure native code without a
JVM being available. So you cannot say the language is interpreted.–
Paulo

On Mon, Jun 8, 2009 at 10:54 AM, julien CLEMENT wrote:

That’s right, the source is compiled into byte code which is itself
interpreted :slight_smile:

— En date de : Lun 8.6.09, Paulo Pinto <@Paulo_Pinto> a ?crit :

De: Paulo Pinto <@Paulo_Pinto>
Objet: Re: [SDL] Re : ANN: Dao language 1.0.1 with SDL and OpenGL bindings
?: “A list for developers using the SDL library. (includes SDL-announce)” <
sdl at lists.libsdl.org>
Date: Lundi 8 Juin 2009, 10h53

Java is not interpreted! :slight_smile:

On Mon, Jun 8, 2009 at 10:20 AM, julien CLEMENT <clementj2005 at yahoo.fr<http://mc/compose?to=clementj2005 at yahoo.fr> wrote:

Thank you,

Could you quickly enumerate what are the advantages of Dao comparing with
other existing interpreted languages like Java,Python,Perl,Ruby ?
Is it possible to compile Dao code to native machine code ?

Julien

— En date de : *Ven 5.6.09, Limin Fu <phoolimin at gmail.com<http://mc/compose?to=phoolimin at gmail.com>

  • a ?crit :

De: Limin Fu <phoolimin at gmail.com<http://mc/compose?to=phoolimin at gmail.com>

Objet: [SDL] ANN: Dao language 1.0.1 with SDL and OpenGL bindings
?: sdl at lists.libsdl.org <http://mc/compose?to=sdl at lists.libsdl.org>
Date: Vendredi 5 Juin 2009, 22h15

Hi,

Dao is a simple yet powerful object-oriented programming language with
many advanced features including, soft (or optional) typing, BNF-like macro
system, regular expression, multi-dimensional numeric array, closure,
coroutine, asynchronous function call for concurrent programming etc. Dao
provides a rich set of standard data types, methods and libraries. Dao is
implemented as a light and efficient virtual machine with very transparent C
programming interfaces, which make it easy to extend Dao with C/C++ or embed
Dao into C/C++ programs.

Currently a number of modules have been included, in particular, modules
binding SDL and OpenGL are included. Most of the functions are wrapped as
they are, namely, with the same function prototypes their C versions. Most
of the structures are also wrapped as well. This release might be useful for
somebody wants to play with SDL and OpenGL.

An IDE named Dao Studio for Dao is also released at the same time as Dao.
This IDE includes a syntax highlighted code editor and console, and supports
Edit&Continue debugging mode.

Links:
http://www.daovm.net
http://www.daovm.net/dao/gallery_en
http://www.daovm.net/dao/download_en

Have fun,

Limin Fu

-----La pi?ce jointe associ?e suit-----


SDL mailing list
SDL at lists.libsdl.org <http://mc/compose?to=SDL at lists.libsdl.org>
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org


SDL mailing list
SDL at lists.libsdl.org <http://mc/compose?to=SDL at lists.libsdl.org>
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

-----La pi?ce jointe associ?e suit-----


SDL mailing list
SDL at lists.libsdl.org <http://mc/compose?to=SDL at lists.libsdl.org>
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

I’m not against Java, I just see that although there may not be restrictions in theory, in practice it happens that Java is used with virtual machines which are interpreted. I don’t know any examples of compiled java. That’s why I put it along with python and friends.
I should have said “languages which are not compiled” to avoid confusion. I know java can be compiled, but in reality, it’s not used this way.

— En date de?: Lun 8.6.09, Paulo Pinto a ?crit?:de: Paulo Pinto
Objet: Re: [SDL] Re : ANN: Dao language 1.0.1 with SDL and OpenGL bindings
?: “A list for developers using the SDL library. (includes SDL-announce)”
Date: Lundi 8 Juin 2009, 11h13

In what current JVM may I ask?

It depends on which JVM you run the bytecodes. You cannot say that Java is interpreted since it depends on the implementation, there is
nothing in the language specification that says “you are only allowed to have implement interpreters for this language”.

You have JVMs that compile all bytecodes before execution, others do only parcial compilation depending on a specific threshold, others are
100% interpreters, and you can even compile to pure native code without a JVM being available. So you cannot say the language is interpreted.


Paulo

On Mon, Jun 8, 2009 at 10:54 AM, julien CLEMENT <@Julien_Clement1> wrote:

That’s right, the source is compiled into byte code which is itself interpreted :slight_smile:

— En date de?: Lun 8.6.09, Paulo Pinto a ?crit?:

De: Paulo Pinto
Objet: Re: [SDL] Re : ANN: Dao language 1.0.1 with SDL and OpenGL bindings

?: “A list for developers using the SDL library. (includes SDL-announce)”
Date: Lundi 8 Juin 2009, 10h53

Java is not interpreted! :slight_smile:

On Mon, Jun 8, 2009 at 10:20 AM, julien CLEMENT <@Julien_Clement1> wrote:

Thank you,

Could you quickly enumerate what are the advantages of Dao comparing with other existing interpreted languages like Java,Python,Perl,Ruby ?
Is it possible to compile Dao code to native machine code ?

Julien

— En date de?: Ven 5.6.09, Limin Fu a ?crit?:

De: Limin Fu
Objet: [SDL] ANN: Dao language 1.0.1 with SDL and OpenGL bindings
?: sdl at lists.libsdl.org

Date: Vendredi 5 Juin 2009, 22h15

Hi,

Dao is a simple yet powerful object-oriented programming language with
many advanced features including, soft (or optional) typing, BNF-like
macro system, regular expression, multi-dimensional numeric array,
closure, coroutine, asynchronous function call for concurrent
programming etc. Dao provides a rich set of standard data types,
methods and libraries. Dao is implemented as a light and efficient
virtual machine with very transparent C programming interfaces, which
make it easy to extend Dao with C/C++ or embed Dao into C/C++ programs.

Currently a number of modules have been included, in particular, modules binding SDL and OpenGL are included. Most of the functions are wrapped as they are, namely, with the same function prototypes their C versions. Most of the structures are also wrapped as well. This release might be useful for somebody wants to play with SDL and OpenGL.

An IDE named Dao Studio for Dao is also released at the same time as Dao. This IDE includes a syntax highlighted code editor and console, and supports Edit&Continue debugging mode.

Links:
http://www.daovm.net

http://www.daovm.net/dao/gallery_en
http://www.daovm.net/dao/download_en

Have fun,

Limin Fu

-----La pi?ce jointe associ?e suit-----


SDL mailing list
SDL at lists.libsdl.org

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org


SDL mailing list

SDL at lists.libsdl.org

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

-----La pi?ce jointe associ?e suit-----


SDL mailing list
SDL at lists.libsdl.org

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org


SDL mailing list

SDL at lists.libsdl.org

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

-----La pi?ce jointe associ?e suit-----


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

Hi, sorry to disagree with you but Java is used compiled in many production
systems:

  • Sun’s JVM Hotspot compiles all method invocations that are called more
    than 1500 times. Do you want to have everything compiled? Just use
    -XX:CompileThreshold=0;
  • The JRockit JVM
  • Mobiles using the ARM processor with the Jazelle execution engine
    translate bytecodes on the fly to ARM instructions (Nokia 6120 Classic is
    one example);
  • Sun’s SPOT jvm (Squawk) uses ahead of time compilation when deploying
    applications to the SPOT

As you can see quite a few examples.

Please note I am not a Java fanboy. I use whatever tool is best for a
certain job, because languages are just that, tools.

But many Java myths are no longer true nowadays.

Stopping my off topic discussion here, if anyone feels like commenting use
my private email.–
Paulo

On Mon, Jun 8, 2009 at 11:26 AM, julien CLEMENT wrote:

I’m not against Java, I just see that although there may not be
restrictions in theory, in practice it happens that Java is used with
virtual machines which are interpreted. I don’t know any examples of
compiled java. That’s why I put it along with python and friends.
I should have said “languages which are not compiled” to avoid confusion. I
know java can be compiled, but in reality, it’s not used this way.

— En date de : Lun 8.6.09, Paulo Pinto <@Paulo_Pinto> a ?crit :

De: Paulo Pinto <@Paulo_Pinto>
Objet: Re: [SDL] Re : ANN: Dao language 1.0.1 with SDL and OpenGL bindings
?: “A list for developers using the SDL library. (includes SDL-announce)” <
sdl at lists.libsdl.org>
Date: Lundi 8 Juin 2009, 11h13

In what current JVM may I ask?

It depends on which JVM you run the bytecodes. You cannot say that Java is
interpreted since it depends on the implementation, there is
nothing in the language specification that says “you are only allowed to
have implement interpreters for this language”.

You have JVMs that compile all bytecodes before execution, others do only
parcial compilation depending on a specific threshold, others are
100% interpreters, and you can even compile to pure native code without a
JVM being available. So you cannot say the language is interpreted.


Paulo

On Mon, Jun 8, 2009 at 10:54 AM, julien CLEMENT <clementj2005 at yahoo.fr<http://mc/compose?to=clementj2005 at yahoo.fr> wrote:

That’s right, the source is compiled into byte code which is itself
interpreted :slight_smile:

— En date de : *Lun 8.6.09, Paulo Pinto <@Paulo_Pintohttp://mc/compose?to=@Paulo_Pinto

  • a ?crit :

De: Paulo Pinto <@Paulo_Pintohttp://mc/compose?to=@Paulo_Pinto

Objet: Re: [SDL] Re : ANN: Dao language 1.0.1 with SDL and OpenGL bindings
?: “A list for developers using the SDL library. (includes SDL-announce)”
<sdl at lists.libsdl.org <http://mc/compose?to=sdl at lists.libsdl.org>>
Date: Lundi 8 Juin 2009, 10h53

Java is not interpreted! :slight_smile:

On Mon, Jun 8, 2009 at 10:20 AM, julien CLEMENT <clementj2005 at yahoo.fr<http://mc/compose?to=clementj2005 at yahoo.fr> wrote:

Thank you,

Could you quickly enumerate what are the advantages of Dao comparing with
other existing interpreted languages like Java,Python,Perl,Ruby ?
Is it possible to compile Dao code to native machine code ?

Julien

— En date de : *Ven 5.6.09, Limin Fu <phoolimin at gmail.com<http://mc/compose?to=phoolimin at gmail.com>

  • a ?crit :

De: Limin Fu <phoolimin at gmail.com<http://mc/compose?to=phoolimin at gmail.com>

Objet: [SDL] ANN: Dao language 1.0.1 with SDL and OpenGL bindings
?: sdl at lists.libsdl.org <http://mc/compose?to=sdl at lists.libsdl.org>
Date: Vendredi 5 Juin 2009, 22h15

Hi,

Dao is a simple yet powerful object-oriented programming language with
many advanced features including, soft (or optional) typing, BNF-like macro
system, regular expression, multi-dimensional numeric array, closure,
coroutine, asynchronous function call for concurrent programming etc. Dao
provides a rich set of standard data types, methods and libraries. Dao is
implemented as a light and efficient virtual machine with very transparent C
programming interfaces, which make it easy to extend Dao with C/C++ or embed
Dao into C/C++ programs.

Currently a number of modules have been included, in particular, modules
binding SDL and OpenGL are included. Most of the functions are wrapped as
they are, namely, with the same function prototypes their C versions. Most
of the structures are also wrapped as well. This release might be useful for
somebody wants to play with SDL and OpenGL.

An IDE named Dao Studio for Dao is also released at the same time as Dao.
This IDE includes a syntax highlighted code editor and console, and supports
Edit&Continue debugging mode.

Links:
http://www.daovm.net
http://www.daovm.net/dao/gallery_en
http://www.daovm.net/dao/download_en

Have fun,

Limin Fu

-----La pi?ce jointe associ?e suit-----


SDL mailing list
SDL at lists.libsdl.org <http://mc/compose?to=SDL at lists.libsdl.org>
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org


SDL mailing list
SDL at lists.libsdl.org <http://mc/compose?to=SDL at lists.libsdl.org>
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

-----La pi?ce jointe associ?e suit-----


SDL mailing list
SDL at lists.libsdl.org <http://mc/compose?to=SDL at lists.libsdl.org>
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org


SDL mailing list
SDL at lists.libsdl.org <http://mc/compose?to=SDL at lists.libsdl.org>
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

-----La pi?ce jointe associ?e suit-----


SDL mailing list
SDL at lists.libsdl.org <http://mc/compose?to=SDL at lists.libsdl.org>
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

Ok, thank you Paulo for those annotations,

Julien

— En date de?: Lun 8.6.09, Paulo Pinto a ?crit?:de: Paulo Pinto
Objet: Re: [SDL] Re : ANN: Dao language 1.0.1 with SDL and OpenGL bindings
?: “A list for developers using the SDL library. (includes SDL-announce)”
Date: Lundi 8 Juin 2009, 12h37

Hi, sorry to disagree with you but Java is used compiled in many production systems:

  • Sun’s JVM Hotspot compiles all method invocations that are called more than 1500 times. Do you want to have everything compiled? Just use -XX:CompileThreshold=0;

  • The JRockit JVM

  • Mobiles using the ARM processor with the Jazelle execution engine translate bytecodes on the fly to ARM instructions (Nokia 6120 Classic is one example);

  • Sun’s SPOT jvm (Squawk) uses ahead of time compilation when deploying applications to the SPOT

As you can see quite a few examples.

Please note I am not a Java fanboy. I use whatever tool is best for a certain job, because languages are just that, tools.

But many Java myths are no longer true nowadays.

Stopping my off topic discussion here, if anyone feels like commenting use my private email.


Paulo

On Mon, Jun 8, 2009 at 11:26 AM, julien CLEMENT <@Julien_Clement1> wrote:

I’m not against Java, I just see that although there may not be restrictions in theory, in practice it happens that Java is used with virtual machines which are interpreted. I don’t know any examples of compiled java. That’s why I put it along with python and friends.

I should have said “languages which are not compiled” to avoid confusion. I know java can be compiled, but in reality, it’s not used this way.

— En date de?: Lun 8.6.09, Paulo Pinto a ?crit?:

De: Paulo Pinto
Objet: Re: [SDL] Re : ANN: Dao language 1.0.1 with SDL and OpenGL bindings

?: “A list for developers using the SDL library. (includes SDL-announce)”
Date:
Lundi 8 Juin 2009, 11h13

In what current JVM may I ask?

It depends on which JVM you run the bytecodes. You cannot say that Java is interpreted since it depends on the implementation, there is
nothing in the language specification that says “you are only allowed to have implement interpreters for this language”.

You have JVMs that compile all bytecodes before execution, others do only parcial compilation depending on a specific threshold, others are
100% interpreters, and you can even compile to pure native code without a JVM being available. So you cannot say the language is interpreted.


Paulo

On Mon, Jun 8, 2009 at 10:54 AM, julien CLEMENT <@Julien_Clement1> wrote:

That’s right, the source is compiled into byte code which is itself interpreted :slight_smile:

— En date de?: Lun 8.6.09, Paulo Pinto a ?crit?:

De: Paulo Pinto

Objet: Re: [SDL] Re : ANN: Dao language 1.0.1 with SDL and OpenGL bindings

?: “A list for developers using the SDL library. (includes SDL-announce)”
Date: Lundi 8 Juin 2009, 10h53

Java is not interpreted! :slight_smile:

On Mon, Jun 8, 2009 at 10:20 AM, julien CLEMENT <@Julien_Clement1> wrote:

Thank you,

Could you quickly enumerate what are the advantages of Dao comparing with other existing interpreted languages like Java,Python,Perl,Ruby ?
Is it possible to compile Dao code to native machine code ?

Julien

— En date de?: Ven 5.6.09, Limin Fu a ?crit?:

De: Limin Fu
Objet: [SDL] ANN: Dao language 1.0.1 with SDL and OpenGL bindings
?: sdl at lists.libsdl.org

Date: Vendredi 5 Juin 2009, 22h15

Hi,

Dao is a simple yet powerful object-oriented programming language with
many advanced features including, soft (or optional) typing, BNF-like
macro system, regular expression, multi-dimensional numeric array,
closure, coroutine, asynchronous function call for concurrent
programming etc. Dao provides a rich set of standard data types,
methods and libraries. Dao is implemented as a light and efficient
virtual machine with very transparent C programming interfaces, which
make it easy to extend Dao with C/C++ or embed Dao into C/C++ programs.

Currently a number of modules have been included, in particular, modules binding SDL and OpenGL are included. Most of the functions are wrapped as they are, namely, with the same function prototypes their C versions. Most of the structures are also wrapped as well. This release might be useful for somebody wants to play with SDL and OpenGL.

An IDE named Dao Studio for Dao is also released at the same time as Dao. This IDE includes a syntax highlighted code editor and console, and supports Edit&Continue debugging mode.

Links:
http://www.daovm.net

http://www.daovm.net/dao/gallery_en
http://www.daovm.net/dao/download_en

Have fun,

Limin Fu

-----La pi?ce jointe associ?e suit-----


SDL mailing list
SDL at lists.libsdl.org

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org


SDL mailing list

SDL at lists.libsdl.org

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

-----La pi?ce jointe associ?e suit-----


SDL mailing list
SDL at lists.libsdl.org

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org


SDL mailing list

SDL at lists.libsdl.org

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

-----La pi?ce jointe associ?e suit-----


SDL mailing list
SDL at lists.libsdl.org

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org


SDL mailing list

SDL at lists.libsdl.org

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

-----La pi?ce jointe associ?e suit-----


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

Hi,

There are some advantages of Dao with respect to the language you mentioned:

(1) optional (soft) typing: which means you can either declare the types of
variables explicitly, or let the interpreter to infer the types from the
program (implicit typing). The explicit types and inferred types are checked
at compiling time, so that more bugs can be detected at the compiling stage
than in languages such perl, python and ruby etc. With implicit typing, Dao
is more flexible than Java, and with the compiling time type checking, Dao
is type safer than perl, python and ruby etc.

(2) meta programming: Dao has a unique macro system which is very
expressive.

(3) simple: simpler than these languages; Whether it is an advantage, it
will depend on your POV.

(4) transparent interfaces to C/C++: because of this transparency, a
automated tool was easy created by myself using Dao, to wrap some C/C++
libraries automatically from the header files. The announced bindings to SDL
and OpenGL was generated by this tool. Other libraries such as GSL,
GraphicsMagich, MathGL, LibXML, ZLib and VTK etc. are also generated by this
tool.

(5) efficient: in some cases it is very efficient compared with perl, python
and ruby etc. Actually the efficiency of Dao depends very much on how
frequent function calls there are in the program. In programs thare are not
many frequenct function calls, Dao is very efficient (compared to
interpereted languages of course).

Currently, Dao does not compile to native machine codes, probably it will be
done through using LLVM in the future. Just to mention, Dao included an
experimental and simple Just-In-Time compiler for X86, this JIT compiler is
not stable yet, but in time it will be improved.

Limin

2009/6/8 julien CLEMENT > Thank you,

Could you quickly enumerate what are the advantages of Dao comparing with other existing interpreted languages like Java,Python,Perl,Ruby ?
Is it possible to compile Dao code to native machine code ?

Julien


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

As you can see quite a few examples.

Please note I am not a Java fanboy. I use whatever tool is best for a
certain job, because languages are just that, tools.

But many Java myths are no longer true nowadays.

The same methods are going into other traditionally interpreted
languages, too. V8 and Tracemonkey (and possibly the new Apple one
that I forget the name) both generate native code when JITting. The
"Unladen Swallow" project is working on making Python faster,
including adding native code generation. And so on.

There was a paper about garbage collection that I saw a little while
ago that said GC could be just as fast as manual memory management,
but that in order to “wait for the right moments” to GC, memory usage
for equivalent work and performance was around 5 times that of what
you’d need if you manually managed memory. That might be a problem in
some cases, but overall, it’s not fundamentally doomed either.On Mon, Jun 8, 2009 at 6:37 AM, Paulo Pinto wrote:


http://pphaneuf.livejournal.com/

As you can see quite a few examples.

Please note I am not a Java fanboy. I use whatever tool is best for a
certain job, because languages are just that, tools.

But many Java myths are no longer true nowadays.

The same methods are going into other traditionally interpreted
languages, too. V8 and Tracemonkey (and possibly the new Apple one
that I forget the name) both generate native code when JITting. The
"Unladen Swallow" project is working on making Python faster,
including adding native code generation. And so on.

The problem with Java (and most managed code languages) is that
it creates so many layers of abstraction that you can’t penetrate,
leading to all sorts of ugly abstraction inversions and a fair number of
things you just can’t do.

Pure OOP, for example. It sounds like a good idea at first, until you
try to do something that doesn’t map well to the object paradigm.
Then things get ugly real fast. See
http://steve-yegge.blogspot.com/2006/03/execution-in-kingdom-of-nouns.html
for a great illustration of the problem.

As for JIT compilation, am I the only one who thinks that it’s a
Very Bad Thing from a maintenance perspective? If something
goes wrong in a native program, you can open it up in a debugger
and trace through at any layer of abstraction, right down to the
assembly code level if necessary, which it is sometimes. I’ve seen
glitches that don’t make any sense until I’m at the ASM level,
because the compiler was doing something weird while optimizing.

If you distribute a native, compiled binary, you can be sure that every
user is running the same machine code, and you can debug like that
if necessary. But if you your code gets JITted, and the JITter optimizes
the program to the current hardware configuration like a lot of them do
these days, you’re potentially distributing a different set of machine
code for every single machine it runs on. What happens if it makes a
mistake on one specific CPU that you don’t have, and a small
percentage of users come to you with bug reports that are impossible
to reproduce?>----- Original Message ----

From: Pierre Phaneuf
Subject: Re: [SDL] Re : ANN: Dao language 1.0.1 with SDL and OpenGL bindings
On Mon, Jun 8, 2009 at 6:37 AM, Paulo Pinto wrote:

If you distribute a native, compiled binary, you can be sure that every
user is running the same machine code, and you can debug like that
if necessary. ?But if you your code gets JITted, and the JITter optimizes
the program to the current hardware configuration like a lot of them do
these days, you’re potentially distributing a different set of machine
code for every single machine it runs on. ?What happens if it makes a
mistake on one specific CPU that you don’t have, and a small
percentage of users come to you with bug reports that are impossible
to reproduce?

That’s absolutely right, but it looks like this is the way things are
going, so we’ll have to live with this (I’m not saying anything
whether I like it or not, I actually don’t like Java myself, and I was
"defending" it earlier, just stating some facts).

It’s already the case even in most C or C++ games, with the shaders,
that get compiled to all sorts of native formats, possibly varying
from one GPU model to another within a single family, depending on how
"performance-minded" the driver is…

If you hit a bug in the JITter, the shader compiler, LLVM runtime, or
other things like that, well, good luck. ;-)On Mon, Jun 8, 2009 at 12:41 PM, Mason Wheeler wrote:


http://pphaneuf.livejournal.com/

So it seems we’ll keep on discussing the issue. :slight_smile:

This seems like a non problem to me. With most of the so called native
languages you have as
much control over the generated code as with managed languages.

Sure you can check which type of ASM gets generated for a given code pattern
but that is about it.
Then you either rewrite the code in such a way that you get a different ASM
or you have to write
your code snippet in ASM. This last option is also available in most managed
languages.

And with JITed code, my application is always optimized to the available
environment, whereas with
native binaries I’ll need to have multiple versions depending on what I am
supporting.

As for the abstractions. I can track down that complaint back to the first
FORTRAN compiler.

I like my abstractions. Sure low level control is nice to have, but do you
really need it for every
single type of application out there?

As I said already languages are just tools. I will gladly use C today, C#
next week and ASM in
one month. I am language agnostic, it all depends on the problem at hand.–
Paulo

On Mon, Jun 8, 2009 at 6:41 PM, Mason Wheeler wrote:

The problem with Java (and most managed code languages) is that
it creates so many layers of abstraction that you can’t penetrate,
leading to all sorts of ugly abstraction inversions and a fair number of
things you just can’t do.

Pure OOP, for example. It sounds like a good idea at first, until you
try to do something that doesn’t map well to the object paradigm.
Then things get ugly real fast. See
http://steve-yegge.blogspot.com/2006/03/execution-in-kingdom-of-nouns.html
for a great illustration of the problem.

As for JIT compilation, am I the only one who thinks that it’s a
Very Bad Thing from a maintenance perspective? If something
goes wrong in a native program, you can open it up in a debugger
and trace through at any layer of abstraction, right down to the
assembly code level if necessary, which it is sometimes. I’ve seen
glitches that don’t make any sense until I’m at the ASM level,
because the compiler was doing something weird while optimizing.

If you distribute a native, compiled binary, you can be sure that every
user is running the same machine code, and you can debug like that
if necessary. But if you your code gets JITted, and the JITter optimizes
the program to the current hardware configuration like a lot of them do
these days, you’re potentially distributing a different set of machine
code for every single machine it runs on. What happens if it makes a
mistake on one specific CPU that you don’t have, and a small
percentage of users come to you with bug reports that are impossible
to reproduce?


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

I like my abstractions. Sure low level control is nice to have, but do you really need it for every
single type of application out there?

For anything non-trivial, yes, absolutely yes. Any abstraction that you can’t get beneath is
evil, because the computer doesn’t actually run at any abstract level. Aabstraction is about
hiding the details of what’s really going on so you can concentrate on the higher-level task
of making the program do what you want it to do. This makes initially writing code easier,
but at the expense of debugging and maintenance, (which you tend to spend far more time
on than the initial writing,) because when you need to debug something, it’s because you
thought you were telling it to do one thing, but what really ended up happening was
something different. And the more layers of insulation between what you’ve written and
what really ended up happening, the harder it is to figure out what went wrong and why,
unless the bug was something obvious that jumps out at you as soon as you re-read the
code. This is what Joel Spolsky calls The Law of Leaky Abstractions, which every
programmer ought to be familiar with.

As I said already languages are just tools. I will gladly use C today, C# next week and ASM in
one month. I am language agnostic, it all depends on the problem at hand.

I have a slightly different view of that. Languages are tools, so why use a defective tool?
That’s why I avoid managed code.>From: Paulo Pinto

Subject: Re: [SDL] Re : ANN: Dao language 1.0.1 with SDL and OpenGL bindings

missed a rather obvious one:
GCJ (GNU Compiler for Java) http://gcc.gnu.org/java/

It’s part of GCC (GNU Compiler Collection), which is the standard compiler for
mingw and most unix based operating systems.On Monday, 8 June 2009 06:37:53 Paulo Pinto wrote:

Hi, sorry to disagree with you but Java is used compiled in many production
systems:

It was on purpose. :slight_smile:

RedHat start distributing it together with Eclipse before Sun opened up
Java, but I am unaware of production systems really making use of it.–
Paulo

On Tue, Jun 9, 2009 at 11:42 AM, Kenneth Bull wrote:

On Monday, 8 June 2009 06:37:53 Paulo Pinto wrote:

Hi, sorry to disagree with you but Java is used compiled in many
production
systems:

missed a rather obvious one:
GCJ (GNU Compiler for Java) http://gcc.gnu.org/java/

It’s part of GCC (GNU Compiler Collection), which is the standard compiler
for
mingw and most unix based operating systems.


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

Mason Wheeler wrote:

I like my abstractions. Sure low level control is nice to have, but do you really need it for every
single type of application out there?

For anything non-trivial, yes, absolutely yes. Any abstraction that you can’t get beneath is
evil, because the computer doesn’t actually run at any abstract level. Aabstraction is about
hiding the details of what’s really going on so you can concentrate on the higher-level task
of making the program do what you want it to do. This makes initially writing code easier,
but at the expense of debugging and maintenance, (which you tend to spend far more time
on than the initial writing,) because when you need to debug something, it’s because you
thought you were telling it to do one thing, but what really ended up happening was
something different. And the more layers of insulation between what you’ve written and
what really ended up happening, the harder it is to figure out what went wrong and why,
unless the bug was something obvious that jumps out at you as soon as you re-read the
code. This is what Joel Spolsky calls The Law of Leaky Abstractions, which every
programmer ought to be familiar with.

As I said already languages are just tools. I will gladly use C today, C# next week and ASM in
one month. I am language agnostic, it all depends on the problem at hand.

I have a slightly different view of that. Languages are tools, so why use a defective tool?
That’s why I avoid managed code.

I hope you know that x86 “native” code is also managed code as it is JIT
compiled by the current CPU’s to micro level instructions. :)>> From: Paulo Pinto

Subject: Re: [SDL] Re : ANN: Dao language 1.0.1 with SDL and OpenGL bindings