|
||
|
GP Mailing List
ATXGPSIG List
|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re:
Hi
Even then I think that the JIT generated code cannot be as optimized as any
other language without an intermediate ByteCode. It's just a feeling, I might be
wrong though.
On the other hand if u can do things in Java that was better implemented than in
C++ because of the language structure/features then Java will be faster for that.
IMHO speed is gain much more in the upper level design/implementation than at low
level code except in the case of inner loops. And AFAIK there is a Paretto law
that rules "20% of the code has the 80% of the execution time". So u may well
code your game in whatever is more suitable to the upper design/implementation
and then profile and optimize as necessary.
Fernando
Bob Pendleton wrote:
> "Idahosa I. Edokpayi" wrote:
> >
> > Whoa.. so you are saying Java becomes x86 machine code through the use of
> > JIT compilers? Scary... I must do something to slow the JAVA juggernaut and
> > protect my beloved C++! I have heard that the actual implementation on most
> > systems is very sketchy. The best programmers at Microsoft tried and could
> > not get java to work 100% right.
>
> I assume that you tongue is firmly in your cheek, right? :-)
>
> Yes, Java becomes x85 machine code on x86 machines. I don't know about
> it being "sketchy" The language is very well defined. Based on what I
> read in the court finding about what Microsoft has done to undermine I
> suspect there may be something else behing anything coming out of MS
> about Java. Any way... MS proudly claims on their IE web site that their
> JVM/JIT is much faster than any other JVM/JIT for the x86.
>
> I am aware of problems with the Java IO model that make it unsuitable
> for building large servers without adding something like select()
> through JNI. My only other reservations about Java are that the media
> APIs and the 3D API are still in beta and are bound to change before
> final release and will have bugs that you won't find in more mature
> software. But, those are teething problems. They will pass in a year or
> two.
>
> Bob P.
>
> >
> > Idahosa Edokpayi
> >
> > -----Original Message-----
> > From: gameprogrammer-owner@gameprogrammer.com
> > [mailto:gameprogrammer-owner@gameprogrammer.com]On Behalf Of Bob
> > Pendleton
> > Sent: Friday, November 19, 1999 9:40 PM
> > To: gameprogrammer@gameprogrammer.com
> > Subject: Re:
> >
> > I'm not following you here. Java is compiled to byte code. Byte code can
> > be executed in the standard three ways. You can build a CPU that
> > executes it. Which Sun and several other companies is doing. You can
> > interpret it. Or, you can recompile it and run it as native code. JIT
> > compilers recompile the byte code into native code for the machine you
> > are running on. They are called "Just In Time" compilers because they do
> > the compilation at load time. In either case the cross platform binary
> > is the Java byte code.
> >
> > Since there are now JIT compilers for all the common platforms Java runs
> > as native compiled code on all the common platforms. The byte code is
> > cross platform and the performance is that of native compiled code for
> > most platforms.
> >
> > I do happen to think that Java encourages better design. And, I know
> > from personal experience that I can produce more working code faster
> > using Java than I can using C or C++. I can't really see any reason why
> > I would prefer C, or C++ to Java for most programming tasks. A project
> > I'm working on right now does combine Java with C. I use the C code to
> > access a win32 API that isn't available in standard Java. I use JNI to
> > access a .dll the accesses the API for me. There is no measurable
> > difference in performance between test code written in pure C and in
> > Java+C.
> >
> > I hope this explains what I meant. If I missed your point please explain
> > further.
> >
> > Bob P.
> >
> > "Idahosa I. Edokpayi" wrote:
> > >
> > > If you forget about Native JIT compilers... (which couldn't possibly
> > produce
> > > a cross-platform binary in any way that I know of) There simply isn't any
> > > way JAVA could come close in speed since it is interpreted. The only
> > > advantage might be if it was easier to use than C++, or encouraged better
> > > design.
> > >
> > > Idahosa Edokpayi
> > >
> > > -----Original Message-----
> > > From: gameprogrammer-owner@gameprogrammer.com
> > > [mailto:gameprogrammer-owner@gameprogrammer.com]On Behalf Of ByteSavers
> > > International
> > > Sent: Thursday, November 18, 1999 1:44 AM
> > > To: gameprogrammer@gameprogrammer.com
> > > Subject: Re:
> > >
> > > At 10:14 PM 11/17/99 -0600, you wrote:
> > > >You know, I heard exactly the same kind of arguments about C versus C++
> > > >when C++ was new. And I heard the same kind of arguments about Fortran
> > > >versus Pascal when Pascal was new. (Even I'm not old enough to have been
> > > >around when Fortran came out...) Truth is that commercial games are
> > > >being written in Java. There was an issue of Game Developer that covered
> > > >the problems. And, the difference in performance between C++ and Java is
> > > >almost gone.
> > >
> > > Yes, but it makes a little more sense given the way that Java is
> > > interpreted.
> > > BTW, you forgot the arguments about BASIC before that 8)
> > > Of course BASIC still is slow, but oh well 8)
> > >
> > > -Phil/CERisE
> > > SomeOtherPerson: we have no cheese in the house!
> > > SomeOtherPerson: err..we do, but it's non-fat tasteless garbage
> > > CERisE8192: Well that's because you're pathetic weight-watchers ;)
> > > SomeOtherPerson: it almost ruined my sunday night...
> > >
> > > 6:20-ish 10/18/99
> > >
> > > =================================================================
> > > The GameProgrammer.Com mailing list is for the open discussion
> > > of any topic related to the art, science, and business of
> > > programming games. This list is especially tolerant of beginners.
> > > We were all beginners once
> > >
> > > To SUBSCRIBE or UNSUBSCRIBE please visit:
> > > http://gameprogrammer.com/mailinglist.html
> > >
> > > =================================================================
> > > The GameProgrammer.Com mailing list is for the open discussion
> > > of any topic related to the art, science, and business of
> > > programming games. This list is especially tolerant of beginners.
> > > We were all beginners once
> > >
> > > To SUBSCRIBE or UNSUBSCRIBE please visit:
> > > http://gameprogrammer.com/mailinglist.html
> > =================================================================
> > The GameProgrammer.Com mailing list is for the open discussion
> > of any topic related to the art, science, and business of
> > programming games. This list is especially tolerant of beginners.
> > We were all beginners once
> >
> > To SUBSCRIBE or UNSUBSCRIBE please visit:
> > http://gameprogrammer.com/mailinglist.html
> >
> > =================================================================
> > The GameProgrammer.Com mailing list is for the open discussion
> > of any topic related to the art, science, and business of
> > programming games. This list is especially tolerant of beginners.
> > We were all beginners once
> >
> > To SUBSCRIBE or UNSUBSCRIBE please visit:
> > http://gameprogrammer.com/mailinglist.html
> =================================================================
> The GameProgrammer.Com mailing list is for the open discussion
> of any topic related to the art, science, and business of
> programming games. This list is especially tolerant of beginners.
> We were all beginners once
>
> To SUBSCRIBE or UNSUBSCRIBE please visit:
> http://gameprogrammer.com/mailinglist.html
=================================================================
The GameProgrammer.Com mailing list is for the open discussion
of any topic related to the art, science, and business of
programming games. This list is especially tolerant of beginners.
We were all beginners once
To SUBSCRIBE or UNSUBSCRIBE please visit:
http://gameprogrammer.com/mailinglist.html
|
|