Follow Slashdot blog updates by subscribing to our blog RSS feed

 



Forgot your password?
typodupeerror
×
Java Programming IT Technology

Have a Nice Steaming Cup of Java 5 859

wap writes "The language/VM/religion that everyone loves to hate is now serving another cup: Java 1.5 is ready for download. The new features of 1.5 have been discussed here before. I, for one, welcome our new virtual machine overlord. I have been using the release candidate, and startup times are noticeably faster, as is overall performance, and the new features like typesafe collections and static imports are great to have. Let the Java flames begin!"
This discussion has been archived. No new comments can be posted.

Have a Nice Steaming Cup of Java 5

Comments Filter:
  • by NoInfo ( 247461 ) * on Thursday September 30, 2004 @08:49AM (#10393153) Homepage Journal
    "This release was made possible by our world-wide development community.

    Oh, yeah, and ridiculously large settlement payments by Microsoft."

  • I wait! (Score:5, Insightful)

    by orangeguru ( 411012 ) on Thursday September 30, 2004 @08:50AM (#10393168) Homepage
    I wait for the first bug reports ... and version 1.5.1 ...
  • Finally! (Score:4, Informative)

    by arhar ( 773548 ) on Thursday September 30, 2004 @08:51AM (#10393178)
    I've been waiting for this for a long time! Now waiting for Eclipse to release a working plugin (well, there's this [genady.net] ,but it's not that great.
    • Eclipse 3.1 betas (Score:5, Informative)

      by trajano ( 220061 ) on Thursday September 30, 2004 @09:31AM (#10393518) Homepage Journal
      The Eclipse 3.1 betas support 1.5 constructs. I normally use the integration builds.
      • Re:Eclipse 3.1 betas (Score:4, Interesting)

        by Mechanik ( 104328 ) on Thursday September 30, 2004 @10:07AM (#10393964) Homepage
        Now we just need to be able to build Eclipse itself using Java 1.5. I really really want to use 1.5 in my Eclipse plugins. I want real container classes dammit! :-P

        Currently you probably could build Eclipse using 1.5, but the Eclipse release engineering folks are still building using 1.4 (or at least, they were as of a month or so ago, and I haven't seen any mailing list traffic to the contrary). There won't be any official builds of Eclipse done with 1.5 for a while yet I think.


        Mechanik
  • Java is to C as ... (Score:4, Interesting)

    by SamSeaborn ( 724276 ) on Thursday September 30, 2004 @08:52AM (#10393182)
    Java is as far above C as C is above Assembly.

    Microsoft was right to be afraid, developing in Java is a delight.

    Sam

    • Java is as far above C as C is above Assembly.
      I was about to mod this as Funny, but then I realized that you weren't making a joke.

      Back in the day, the tagline was "C -- all the speed of assembly, with all the programming ease of assembly."

      --
      Free gmail invites [slashdot.org]
  • by Offwhite98 ( 101400 ) on Thursday September 30, 2004 @08:52AM (#10393187) Homepage
    After they took all that time to rewrite it with the latest API they claim they can closely track Sun releases. This will be the first big thing since then, so it will be a test of Apple to get it out quickly.
  • Passe... (Score:5, Funny)

    by gowen ( 141411 ) <gwowen@gmail.com> on Thursday September 30, 2004 @08:53AM (#10393190) Homepage Journal
    Don't you know, we don't hate Java anymore. These days we all love Java due to its major new feature -- its not C#
    • Considering that nearly 100% of the justification I've heard from people who like C# is along the lines of "It's not Java".

      ...

      Come to think of it, this entire situation is sort of starting to sound like, um, something else...
    • Re:Passe... (Score:4, Interesting)

      by spellraiser ( 764337 ) on Thursday September 30, 2004 @09:31AM (#10393530) Journal
      Yes, it's not C#, but it is getting closer and closer to being C/C++ (or something very very close). For instance, Java 5 borrows features heavily from C. Just take a look at some of the new features:

      - Generic Types (AKA templates)
      - Enumerated Types
      - Static Import (usage of this looks quite similar to the #define method)
      - Formatted Output / Input (printf/scanf style)
      - Varargs

      I like this trend. These, among other changes in version 5, are all steps towards reducing the awkwardness in the Java syntax that many people complain about. Java is a young, evolving language that still has a lot of potential.

      It is a bit funny, though, that this evolution takes the form of borrowing stuff from an ancient language. Maybe C just got things right in the first place, huh?

      /me puts on a flameproof suit

      • Re:Passe... (Score:3, Informative)

        by iabervon ( 1971 )
        Actually, C/C++ had a lot of good ideas, but it took a while for Java to get them right. The new Generic Types add compile-time typechecking and remove a lot of typecasting without adding a huge amount of complexity to the language like C++ templates do, and without causing multiple copies of the code to be generated. Enums in Java are full-fledged classes of actual objects with methods, unlike in C where they are just markers (they are object constants instead of integer constants; no difference in efficie
      • by Kenneth Stephen ( 1950 ) on Thursday September 30, 2004 @01:00PM (#10396128) Journal

        Generics in Java have a smaller scope, when compared to C++ templates. The objective in Java is to provide a type-safety mechanism for containers. In C++, it is much more than that. Unfortunately, it is this extra ability in C++ that makes for some really complex code. Not sure if this has already been mentioned in this story, but it has been theorized that C++ templates are themselves turing complete (though I havent seen a proof to that effect).

        I'm a bit puzzled by all the generics nay-sayers. I have tried out the feature, and they augment the language. I have yet to see a downside to this feature in Java (unless one counts the inability of the compiler to fully utilize the additional type-safety in compiler error messages). What is all the flap about?

  • J2EE --> 1.3.1 still (Score:5, Interesting)

    by tezza ( 539307 ) on Thursday September 30, 2004 @08:54AM (#10393194)
    If you develop apps targeted at Websphere 4, say, they're still 1.3.1 spec.

    I look longingly at typed collections to save yet another ClassCastException on anonymous iterators. *sigh* oh well, maybe 6 years from now...

    • by tmasssey ( 546878 ) on Thursday September 30, 2004 @09:01AM (#10393237) Homepage Journal
      I've been disappointed with IBM's response to Java lately. The last version easily downloaded for Windows is 1.3. The only way I was able to get Java 1.4 for Windows was to download the MQ Series client (like 200MB big!) and pull the JDK out of that...

      I wonder if IBM will have a 1.5 JDK? For a company that is putting a lot of juice behind Java, it seems odd that they don't make the JDK available to others...

      • IBM no longer ships standalone JDKs- according to the license with SUN, they only ship JDK included in a product. IBM will definately have a 1.5 JDK, just don't hold your breath.
    • by robbyjo ( 315601 )
      Are you sure? J2EE is 1.4 [sun.com] already.

    • by koehn ( 575405 ) * on Thursday September 30, 2004 @09:20AM (#10393413)
      First off, Websphere 4.0 is J2EE 1.2 only. You need Websphere 5.0 to get to J2EE 1.3.1. In Websphere 5.1, you at least get JDK 1.4, and a few J2EE 1.4 tidbits (JSTL 1.1, for example).

      However, your ClassCastExceptions will only get bumped to compile time in JDK 1.5, true. But I must admit that in eight years of Java programming, I've never had this particular problem where it didn't take more than a few seconds to find the source of the bug.

      I really just want the metadata stuff (which was obviously ripped off from C#, but it's a great idea). That, and EJB 3.0, which gets rid of the stupid deployment descriptors.
  • by antifoidulus ( 807088 ) on Thursday September 30, 2004 @08:56AM (#10393203) Homepage Journal
    we still gotta wait....come on Steve, get out of the hospital and give us our static imports and generics!
  • by melted keyboard ( 798559 ) on Thursday September 30, 2004 @08:56AM (#10393207)
    Now let the slashdotting commence!
  • Release notes (Score:5, Informative)

    by BlurredOne ( 813043 ) on Thursday September 30, 2004 @08:57AM (#10393212)
    If any one is interested in reading the release notes, they can be found at http://java.sun.com/j2se/1.5.0/docs/relnotes/featu res.html [sun.com]
  • by mukund ( 163654 ) on Thursday September 30, 2004 @08:58AM (#10393221) Homepage

    I, for one, welcome our new virtual machine overlord.

    Dude you know you are not supposed to say these things in the story itself.

  • useful or bloat? (Score:5, Interesting)

    by N3wsByt3 ( 758224 ) on Thursday September 30, 2004 @09:01AM (#10393233) Journal
    Well, some may call the 1.5 as being increasingly bloatware, but, why in some aspects this may be true, I think all by all there are considerable improvements over the former releases, especially 1.4.2.

    JVM 1.4.2 (at least some sub-versions) were riddled with bugs, which, for instance, become apparent when people use systems that rely on it in a special way, as with Freenet. It comes as no surprise, that there were numerous reports of some errors on OSX and BSD, as well as on linux, when running JVM 1.4.2. For some time, we had to say "If you experience any difficulties, please try/revert to JVM 1.4.1 or 1.5.x and see if that solves the problem."

    It is crazy to recommend reverting, but the main devls of java were unwilling to remedy the bugs in 1.4.2, claiming it was a Freenet-problem, while our devls said it was a JVM problem. Though it must be said some within freenet claim their is little to no problem with it (probably windows-users, or maybe some sub-versions that worked on specific linux-distributions). Anyway, my advice has always been, and will be (certainly in the light of the stable 1.5 release), to NOT use the 1.4.2, especially when using OSX or another 'nix based OS.

    And also; be sure to get the JRE, and not the full SDK, unless you plan to develop Java software.
  • by ShatteredDream ( 636520 ) on Thursday September 30, 2004 @09:02AM (#10393243) Homepage
    The new For loop may seem to be just syntactic sugar, but it isn't. It really does make the code look a lot cleaner when you are iterating over a collection or an array. The type safe collections are also very handy--no more class cast exceptions and stuff like that.

    It would be nice though if Sun would make Groovy or Jython a standard part of their java distribution. That would definitely make it competitive with .NET
  • by nhnfreespirit ( 809462 ) on Thursday September 30, 2004 @09:06AM (#10393284) Journal
    In typical /. style, as soon as Java is as much as mentioned, everybody expects the flame wars to erupt, and they always do...

    I try to stay pragmatic about the programming languages that I use. For some jobs, Java would be my last choice, and for some it seems a natural fit. When writing hardware near code, or platform dependant stuff on driver level, nobody in their right mind would attempt to use Java. For high level rapid prototyping, Java is a often a quick and easy way of getting things done.
    • The biggest problem with Slashdot Java flaming is that people do not realize what Java is.
      If you compare language to language, say Java to C, C# or even Ruby and Python, it is easy to see why Java is "slow" and "bloated". But Java is to be compared to something like .NET and not just a language.

      Java is a platform. Java provides on-the-fly class loading and verification including digital signing of the code, very fine-grained security model (you can create your own sandbox with whatever security rules you

  • by ancice ( 817863 ) on Thursday September 30, 2004 @09:06AM (#10393290)
    Nice that Java VM is now faster; it's one of the major drawbacks of java on the desktop. But how does this compare with the new and shiny Mono? Mono with its distributed system, and if it still beats Java, then java is in for a tough fight.
    • Sorry, Dude, but the Java VM still is faster than .Net and Mono is significantly slower than .Net (since it is just a basic VM with a basic jit and no runtime optimization)

      Despite the having a slower VM, the .Net programs sometimes can be faster than java programs because they are heavily integrated into windows wheras java has to add abstraction layers for not losing portability.

      But back to Mono it will probably never be able to catchup speedwise with .Net unless they move to another VM which is main
    • Over 50% of the .Net libraries have not been ported to Mono and may never be. Mono is pretty cool but until it is fully ported it will remain years behind Java and .Net. You cant compare them like you cant compare java to perl. Java and .Net are very much competitors and will continue to dominate the industry in their niche. Companies need security (as in a future) for their multimillion projects. It took Java ~6 years to self promote. If Mono severely ramps up their efforts, they MIGHT reach the plateau.
  • by Anonymous Writer ( 746272 ) on Thursday September 30, 2004 @09:08AM (#10393304)
    Java had all this hype about it when it was promoted nearly a decade ago, but it never got anywhere close to the point where you could walk into your local computer store and buy a major software package that could be run on any platform. I recall that Corel was going to attempt to release a WordPerfect that ran using Java, but that's the most I heard of it being adopted by mainsteam software developers. Does anyone think it will ever take?

    • Rather than mod you troll, here's a simple answer.

      >> Does anyone think it will ever take?

      What makes you think it hasn't? A single example: What percentage of Apache Foundation products are written in and/or for Java. Note that Apache Foundation products are used extensively in Enterprise software development, deployment and systems.

      ~cederic
      • Rather than mod you troll, here's a simple answer.

        I honestly wasn't trying to troll. If you walk into a computer store and look at all the off-the shelf consumer-level software products, they're all for Windows. I was hoping that Java would have changed this so that you can buy one of these off-the shelf products and run it on any platform. I know that it has gained acceptance at the enterprise level, I was actually referring to the consumer level.

  • by Brian Blessed ( 258910 ) on Thursday September 30, 2004 @09:08AM (#10393306)
    I thought that the compiled Java would remain compatible with the bytecode format used by previous versions. However, this seems not be the case and I get this message:
    java.lang.UnsupportedClassVersionError: HelloWorld (Unsupported major.minor version 49.0)

    Whilst code that uses the new language features must obviously be compiled with the v1.5 JSDK, this means that it must also be run on the v1.5 JRE.

    This may inhibit the use of Java 5 by projects that want their programs to run on a v1.4 JRE.

    - Brian.
    • by Z-MaxX ( 712880 ) on Thursday September 30, 2004 @09:21AM (#10393427) Journal
      You need to use the "-target 1.4" option to javac to tell it to produce the older version of class files.

    • I would hope that 1.2, 1.3 and 1.4 bytecode would run in the 1.5 JRE. I think it's ambitious to expect 1.5 bytecode to run in a pre-1.5 JRE - the language has new features that such JREs don't know about or support.

      While you could obviously write code that interprets 1.5 bytecode so that it will run on a 1.4 JRE, and make it possible to automagically create that code at compile-time, including it by default in the compiled 1.5 code would be wasteful as it's not required to run in a 1.5 environment.

      So yes
    • by julesh ( 229690 ) on Thursday September 30, 2004 @10:08AM (#10393982)
      I thought that the compiled Java would remain compatible with the bytecode format used by previous versions.

      The bytecode format is still identical. The version number on the file was incremented because classes that depend on assertions could break badly if used on a JVM that doesn't implement them (which is actually a feature of a few classes in java.lang, not a bytecode interpreter feature). Use the '-target' commands recommended by the other posters whenever producing code that doesn't rely on one of the new features.
    • It has been known for a long time (over a year), that Java programs compiled for 1.5 will not run on a 1.4 VM. However, you can use tools like Retroweaver [sf.net] to get 1.4 compatibility. It rewrites the bytecode of your version 1.5 class files into the 1.4 VM format.
  • by jg21 ( 677801 ) * on Thursday September 30, 2004 @09:25AM (#10393469)
    In an interview [sys-con.com] given just last night, the spec lead for 5.0 is asked what in his view the coolest new feature of the language is. Calvin Austin replies: If I just restrict myself to the language it would be metadata (JSR 175). We've only scratched the surface of its potential. For the platform, it's a bytecode insertion for profiling (JSR 163).
  • Swing on OpenGL (Score:5, Informative)

    by tesmako ( 602075 ) on Thursday September 30, 2004 @09:26AM (#10393476) Homepage
    One of the new features of Java 1.5 that has not been mentioned much yet is the OpenGL acceleration of Java2D (which underlies Swing and AWT). Adding the flag
    -Dsun.java2d.opengl=true
    (or by setting the system property in the program) makes pretty much all Java2D calls go directly into OpenGL.

    This does indeed work too, I have played around with it and graphically intensive Swing applications really fly with OpenGL activated (given that your graphics card and drivers are sufficiently bug-free and modern). Read about it here [sun.com]

    And yes, it does work under Linux, and Windows and Solaris (and most likely will under OS X, though that is up to Apple to implement).

    Even without OpenGL acceleration the Swing responsiveness improvements are very impressive, coupled with the much better both default theme and theme mimicking in 1.5 I'd say it is time to retire the Swing troll.

    • Re:Swing on OpenGL (Score:3, Insightful)

      by LDoggg_ ( 659725 )
      The openGL feature is really cool.
      Any idea if there's a way to turn this on or off programatically?

      Having this on the command line is ok, but if someone is using Mesa3d(software openGL on Linux) instead of hardware acceleration, it will be slower than the default rendering path of X11.

      Here's [cox.net] a screenshot of my JTurtle [cox.net] application running on accelerated openGL with jdk1.5 and using the new look and feel.
  • I love the hate (Score:5, Insightful)

    by Featureless ( 599963 ) on Thursday September 30, 2004 @09:30AM (#10393513) Journal
    You can't hate any language as much as some people hate Java until it's really reached critical mass.

    There are two things that make any really big language a target: 1) people start using it for everything, including things its not suited for. 2) junior folks without a lot of compiler or cross-language experiences will cut their teeth on Java, and at that point in one's career it is sometimes considered cool to blame a bad application's flaws on the language it's written in.

    Java has plenty of problems. There are brilliant essays written on it; some of them by Sun engineers. But the complaint linked to in story was so bad by comparison, however, I doin't feel offtopic in addressing some points it raised:

    there are a thousand "super-efficient" .jar libraries required by a "Hello World" app

    No.

    it takes 12 objects instantiated in 4 containers to flip a bit in a byte

    Oh, I see. You're flipping bytes.

    there is the substitution of native performance of compiled code to code compiled "Just Too Late" combined with exceptional memory usage that entails

    The VM is more work. Strangely, you will have trouble finding benchmarks that make other comparable high-level languages look way faster than Java on the same _non-user-facing_ application.

    As always, code in C, assembler, or another specialized language if you really need to.

    The speed thing is well-addressed elsewhere. Enough said for now.

    we get the garbage collector which is scientifically fine-tuned to run just when user is expected to interact with the application in most time sensitive manner

    People love to bitch about client-side Java. It's as if all the flaws they're used to from other client side systems are fine, because they're used to them, and every foible of Java is worth agonizing over as if it were the worst thing in the world.

    I dunno what else to say, but I wrote an enormous graphic-intensive video game in it and it runs fine. And what I did is nothing; somebody cloned the QIII engine to the point where it plays actual Q3A maps (with multiplayer) at respectable framerates.

    Once again, someone shows me a shitty client app written by a team of 30 22 year olds in Thailand and claim it's proof that Java sucks. Congratulations.

    multiple, insideously incompatible with each other, versions of the so-called "universal" VM

    Yes, leaving aside the fact that Microsoft deliberately broke VM compatibility. Not just in one or two big ways. In a lot of little ways. As in on purpose. Great example. Very honest.

    There is a giant test suite. Gets better all the time. Reputable VM's pass it. Most of all, though, I just don't run into the cross-VM problem in the first place unless I'm doing 1.1 development for browsers, see above...

    We actually abandoned DB2 8.x release because noone could deal with the havoc the DB2 admin tools were causing with various other retarded banking related Java apps.

    There we go. The truth outs. You overpaid for a shitty product. Congratulations. You can do that in C or Fortran, too.

    Blame the language, though. Don't blame yourselves for picking a bad app.

    Oh well, time to have me shot on sight.

    Have a nice day.
    • Rapid learning (Score:5, Interesting)

      by GeekDork ( 194851 ) on Thursday September 30, 2004 @09:54AM (#10393820)

      As much as I might hate Java, I repeatedly have to throw this one thing into the fray: I had exactly zero former experience with network programming, and still, I was able to produce a basic telnet-like application in under 30 minutes, using only the Java API doc and some logical thinking. And I only had a very brief introduction into the language. Transferring this to C (although the basic structure is exactly the same with BSD and Java sockets) took me about a week, with all those damn low-level error conditions.

      • Exactly (Score:3, Insightful)

        by Trejkaz ( 615352 )
        And not only was it faster to write in the first place, but the chances are your app will run on Windows out of the box without having to add arbitrary WinSock calls around the place. And it will run on BSD without adding extra network headers and libraries to the makefile after discovering half of them are missing from the default. And it will run on OSX without any knowledge of that platform at all. WORA is indeed real until people try to break it with specifically crafted examples. :-)
      • Re:Rapid learning (Score:5, Insightful)

        by tdrury ( 49462 ) on Thursday September 30, 2004 @11:05AM (#10394767) Homepage
        Sir, I regret to inform you that you've demonstrated "critical thinking" within a hostile forum. You are no longer allowed to read Slasdot. Move along.

        Joking aside, it kills me to see the amount of research and due-diligence that goes into debunking a Microsoft-sponsored benchmark, but when it comes to Java most everyone starts spouting nonsense. People will remember their experiences from 8 years ago, or a bad app, etc. and immediately conclude that Java must suck for every conceivable application.

        Java is a tool - no more, no less. Use it where you think it is useful and leave on the shelf if you don't think it will help solve your current problem. Most mature developers know when and where a tool should be applied.
    • Re:I love the hate (Score:3, Interesting)

      by renoX ( 11677 )
      > You can't hate any language as much as some people hate Java until it's really reached critical mass.

      Untrue, there is no need to wait to hate Java, I tried Java in 98-99 and hated it, its libraries were full of bugs (Swing, the GC was leaky on 1.1.8) and you spent your time working around the bugs.

    • First a disclaimer, I wrote the original post you seem to quote. I do not write Java apps and although I was mostly facetous, here is why I said those things:

      there are a thousand "super-efficient" .jar libraries required by a "Hello World" app

      No.

      Well it certainly feels that way when you try to load those apps. They all have excruciating startup times. Perheaps I am wrong and instead they check the integrity of my bank account or weather in China for my convenience. I dont really care, but 5-6 seconds

  • by phyruxus ( 72649 ) <{moc.oohay} {ta} {knildnapmuj}> on Thursday September 30, 2004 @09:34AM (#10393555) Homepage Journal
    Java Developer needed. Must have 3+ years experience with Java 1.5, to start immediately.
  • by mattdm ( 1931 ) on Thursday September 30, 2004 @09:41AM (#10393646) Homepage

    I work on a minor, highly targetted Linux distribution. I'd love to include Java, and I actually get a lot of requests for it. But, here's an excerpt from the license agreement you'll find if you look to download the software:

    B. License to Distribute Software. Subject to the terms and conditions of this Agreement and restrictions and exceptions set forth in the Software README file, including, but not limited to the Java Technology Restrictions of these Supplemental Terms, Sun grants you a non-exclusive, non-transferable, limited license without fees to reproduce and distribute the Software, provided that (i) you distribute the Software complete and unmodified and only bundled as part of, and for the sole purpose of running, your Programs, (ii) the Programs add significant and primary functionality to the Software, (iii) you do not distribute additional software intended to replace any component(s) of the Software, (iv) you do not remove or alter any proprietary legends or notices contained in the Software, (v) you only distribute the Software subject to a license agreement that protects Sun's interests consistent with the terms contained in this Agreement, and (vi) you agree to defend and indemnify Sun and its licensors from and

    (Yes, it really does just end abruptly without finishing the sentence. That trailing "and" there doesn't lead into the next section; it's just not done. Obviously I'm the only one who bothers to read these things -- *including* the people at Sun. Anyway....)

    My wish to give the software to my users fails almost every test....

    i: I don't want to distribute it for the "sole purpose of running [my] Programs". I want to distribute it so people can run other people's programs, including possibly their own.

    ii: uh, well, actually, my "Programs" don't add any functionality to Java, let alone "significant and primary".

    iii: oops, I include gcc, which has a Java compiler. And I'm definitely not going to drop that.

    iv: ahh, now this one I can agree with -- fine keep your copyright notices, etc.

    v: my distribution as a whole is under the GPL. I'd have to run this by our lawyers, but this looks like it'd conflict by requring additional restrictions (even if I could get special dispensation to deal with the other issues).

    vi: I don't really have the resources to defend and indemnify Sun "from and", even if I wanted to, thanks.

    And frankly, that's why I wish people would stop writing things in Java. It's a pain to deal with. I want to make everything as slick, integrated, and as easy as possible for my end users. Sun makes that impossible for Java applications. If you want your code to be easily integrated and made available to users like mine -- and really, that's users of any Linux distro targetted more broadly than the super-geek sector -- please don't use Java. If you must, at least design it to work with gcj instead of Sun's virtual machine.

    Unless Sun changes the license terms, their Java can never fill the "write once, run anywhere" goal -- but cleanly written source in an open language can.

  • by znerd ( 83191 ) on Thursday September 30, 2004 @09:58AM (#10393864) Homepage
    I did some tests to compare Java 1.4.2_05 with JDK 1.5.0 and I found that 1.4.2_05 is considerably faster when building a project. This mainly involved XSLT processing and Java compilation.

    Test I did: Run 'ant -lib lib checkstyle java' on XINS [sf.net] 0.207)

    Preparation command:
    rm -rf build
    Timed command:
    time ant -lib lib checkstyle java
    I did 3 tests in a row for each Java version. I added the 'user' and 'sys' times and the averaged then. Results on my Gentoo Linux system with 2.6 kernel:
    Java 1.4.2_05
    34.5s
    Java 1.5.0-rc:
    42.9s
    Java 1.5.0:
    41.6s
  • SLOW (Score:3, Insightful)

    by Surt ( 22457 ) on Thursday September 30, 2004 @11:22AM (#10395054) Homepage Journal
    Bah, each new release I try hoping they'll do something about the speed since I like the language better than c/c++.

    Since 1.0 there have been three major speed holdbacks preventing me and many others from adopting java:

    1) array access too slow due to boundary checking (no, their optimizer doesn't work for my cases, and this is a problem a lot of scientists/performance hungry people have).

    #1 has some good solutions on 64-bit platforms developed at the university of georgia, but sun won't include them, nor will they enable a flag on the jvm to turn of bounds checks. GCJ lets you do it, but can't compile everything I need yet.

    2) casting raw memory to objects requires a copy. Java needs a structured object without a header to overcome this, such as the struct proposal, which is in the top 25 rfe's yet has no comment from sun.

    #2 has a well understood solution that sun is apparently too lazy to even consider implementing.

    3) No way to do fast 2d/3d rendered graphics. Too many call overheads & copies.

    Sun needs to ditch AWT/Swing, and probably needs to open source java to overcome this. They've proven their inability to keep up a reasonable mapping to modern featuresets.

    I'm probably going to have to give up and learn c# since I'd like a more modern language with good tools, but java just doesn't have the speed.

He has not acquired a fortune; the fortune has acquired him. -- Bion

Working...