C++ Vs Java

Please support our C++ advertiser: Intel Parallel Studio Home
Reply

Join Date: Jul 2007
Posts: 29
Reputation: xander85 is an unknown quantity at this point 
Solved Threads: 1
xander85's Avatar
xander85 xander85 is offline Offline
Light Poster

Re: C++ Vs Java

 
0
  #41
Jul 21st, 2007
Originally Posted by Killer_Typo View Post
java compilers and the java runtime environment are created using C++


learning both C and C++ is good but you may find yourself trying to unteach yourself things from C when you work in C++.

Second that!
Reply With Quote Quick reply to this message  
Join Date: Apr 2005
Posts: 16,248
Reputation: jbennet is a name known to all jbennet is a name known to all jbennet is a name known to all jbennet is a name known to all jbennet is a name known to all jbennet is a name known to all 
Solved Threads: 540
Moderator
Featured Poster
jbennet's Avatar
jbennet jbennet is offline Offline
Moderator

Re: C++ Vs Java

 
0
  #42
Jul 21st, 2007
why dont they rewrite the java VM in assembley it would be faster. maybe its too big.
If i am helpful, please give me reputation points.
Reply With Quote Quick reply to this message  
Join Date: Nov 2004
Posts: 6,143
Reputation: jwenting is just really nice jwenting is just really nice jwenting is just really nice jwenting is just really nice 
Solved Threads: 212
Team Colleague
jwenting's Avatar
jwenting jwenting is offline Offline
duckman

Re: C++ Vs Java

 
0
  #43
Jul 21st, 2007
because there's no need to. It's plenty fast enough as it is, and the way it's coded now a lot of the codebase is platform independent (meaning it compiles equally well for all platforms Sun supports), reducing lead time and investment drastically.
If written in assembly (or worse, Visual Basic) they'd have to rewrite the entire thing for each hardware and operating system platform supported, which by now has reached quite a number (Sun supporting both 32 and 64 bit versions of Windows, Solaris, and Linux, for a total of something like 10 different distributions).
As people are clearly allowed to attack me but I'm not allowed to defend myself, I no longer post to this site.
Reply With Quote Quick reply to this message  
Join Date: Feb 2007
Posts: 539
Reputation: thekashyap will become famous soon enough thekashyap will become famous soon enough 
Solved Threads: 50
thekashyap's Avatar
thekashyap thekashyap is offline Offline
Posting Pro

Re: C++ Vs Java

 
2
  #44
Jul 21st, 2007
Originally Posted by jbennet View Post
Hey, is the Java VM written in C++ ?
Yeah, I first noticed that "java" executable is written in C/C++ when I had some hotspot error and it wrote down a core file, whose pstack showed calls from main()->createVM()... So it's C at least if not C++.
You can execute "file java" on unix to see this. Also if you have some tools to list out names in a file like nm, or c++filt...

Anyway, that is no scale to say that C/C++ is better than Java.

For the original question, I would say that decide the industry (telecome, services, product-based, web-services...) you wanna go to, and pick based on that. If you donno which industry then just leave C/C++ and Core Java all 3 of them, shouldn't take you long to learn the languages. It will surely take some time to actually be good at programming in ANY 3 of them. Coz write code and write good are different things.
Abt java, given that apart from core java you have a 100 other things you can learn e.g. J2EE itself is a Pandora's box.

A personal note: every time I have interviewed a candidate for a job in my projects, I have looked for language/theoretical knowledge and good attitude in freshers (just outa collage) and programming knowledge in candidates with prior experience.
Are you Agile.. ?
Reply With Quote Quick reply to this message  
Join Date: Feb 2007
Posts: 539
Reputation: thekashyap will become famous soon enough thekashyap will become famous soon enough 
Solved Threads: 50
thekashyap's Avatar
thekashyap thekashyap is offline Offline
Posting Pro

Re: C++ Vs Java

 
0
  #45
Jul 21st, 2007
Originally Posted by jwenting View Post
If written in assembly (or worse, Visual Basic) they'd have to rewrite the entire thing for each hardware and operating system platform supported...
JRE is platform specific. You can't ftp /usr/bin/java from *nix to a windows machine and expect to run a java program using that.
By not writing it in assembly they don't save on that front. I presume, it's just that it's easier to do it in C/C++ than in asm.
Are you Agile.. ?
Reply With Quote Quick reply to this message  
Join Date: Nov 2004
Posts: 6,143
Reputation: jwenting is just really nice jwenting is just really nice jwenting is just really nice jwenting is just really nice 
Solved Threads: 212
Team Colleague
jwenting's Avatar
jwenting jwenting is offline Offline
duckman

Re: C++ Vs Java

 
0
  #46
Jul 21st, 2007
I know that full well. The BINARIES are platform specific.
A lot of the SOURCE of the JVM however isn't.
As people are clearly allowed to attack me but I'm not allowed to defend myself, I no longer post to this site.
Reply With Quote Quick reply to this message  
Join Date: Jul 2007
Posts: 8
Reputation: ioillusion is an unknown quantity at this point 
Solved Threads: 0
ioillusion's Avatar
ioillusion ioillusion is offline Offline
Newbie Poster

Re: C++ Vs Java

 
0
  #47
Jul 23rd, 2007
Originally Posted by jbennet View Post
why dont they rewrite the java VM in assembley it would be faster. maybe its too big.
On a project of that scale, compilers for modern chips would probably optimize the code better than (most) programmers.
Reply With Quote Quick reply to this message  
Join Date: Jun 2005
Posts: 2,052
Reputation: Rashakil Fol is just really nice Rashakil Fol is just really nice Rashakil Fol is just really nice Rashakil Fol is just really nice 
Solved Threads: 139
Team Colleague
Rashakil Fol's Avatar
Rashakil Fol Rashakil Fol is offline Offline
Super Senior Demiposter

Re: C++ Vs Java

 
3
  #48
Jul 23rd, 2007
Originally Posted by jbennet View Post
why dont they rewrite the java VM in assembley it would be faster. maybe its too big.
Correctness is more important than speed.
All my posts may be redistributed under the GNU Free Documentation License.
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the C++ Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC