Re: Python interpreter speed

2009-04-21 Thread Terry Reedy
Fabio Zadrozny wrote: Further, I have an accounting software which was previously in java, but now in python and the performance gain is ausom. Yes it depends on how we write the code but comparing the 2 at least at the middle layer and front-end (pygtk) python is faster than java. Infact I am m

Re: Python interpreter speed

2009-04-21 Thread Fabio Zadrozny
> Further, I have an accounting software which was previously in java, but > now in python and the performance gain is ausom. > > Yes it depends on how we write the code but comparing the 2 at least at > the middle layer and front-end (pygtk) python is faster than java. > Infact I am most certain t

Re: Python interpreter speed

2009-04-20 Thread Stefan Behnel
Tim Roberts wrote: > The Python you're thinking of (CPython) is compiled to an intermediate > language, which is then interpreted by an interpreter loop, somewhat > remeniscent of Forth. It takes more cycles per instruction to run that > interpreter loop than it does to run the machine language, b

Re: Python interpreter speed

2009-04-20 Thread Tim Roberts
Ryniek90 wrote: > >Standard Python interpreter's implementation is written in C language. C >code while compilation, is compilled into machine code (the fastest >code). Python code is compiled into into byte-code which is also some >sort of fast machine code. So why Python interpreter is slower

Re: Python interpreter speed

2009-04-20 Thread Krishnakant
On Mon, 2009-04-20 at 20:12 +0100, Tim Wintle wrote: > > I can't remember Java properly, but... > > Firstly, speed will depend on what you're writing. I dont' actually know > how much slower python is, but I'm sure there are some things that run > faster in python. > I know many instences which

Re: Python interpreter speed

2009-04-20 Thread Tim Wintle
On Sun, 2009-04-19 at 18:11 +0200, Ryniek90 wrote: > Hi. > > Standard Python interpreter's implementation is written in C language. C > code while compilation, is compilled into machine code (the fastest > code). Python code is compiled into into byte-code which is also some > sort of fast mach

Re: Python interpreter speed

2009-04-19 Thread Pascal Chambon
Hello I'm not expert in low level languages, but I'd say that Python and Java are "compiled" to bytecodes of similar level. The difference lies in the information contained in those bytecodes : java is statically typed, so attribute access and other basic operations are rather quick, allowing

Re: Python interpreter speed

2009-04-19 Thread Krishnakant
I don't mean to start a flame war, but a productive debate will be wonderful. I have been writing heavy applications in java for a few years untill recent past. My experience is that python is not just fast but also zippy and smooth when it comes to running the applications. Infact I have a coupl

Python interpreter speed

2009-04-19 Thread Ryniek90
Hi. Standard Python interpreter's implementation is written in C language. C code while compilation, is compilled into machine code (the fastest code). Python code is compiled into into byte-code which is also some sort of fast machine code. So why Python interpreter is slower than Java VM? B