Follow Slashdot blog updates by subscribing to our blog RSS feed

 



Forgot your password?
typodupeerror
×

Comment Re:Oracle matters less thank you'd think (Score 1) 157

Goto isn't used in Linux for performance reasons. It's used because C does not have exceptions and using goto to jump to clean-up code prevents code duplication. Any sufficiently experienced C programmer will encourage you to do the same.

Why not put the cleanup code in a well named function instead? Also, there are plenty of experienced C programmers who loathe gotos.

Comment Re:Oracle matters less thank you'd think (Score 1) 157

I might care about that for operational reasons. For example I don't want a bunch of objects to be collected when my application is otherwise busy, but that wasn't the point.

That I understand. Modern gc algorithms are pretty good, though.

I might have references to objects which I expect to be freed up. I would like to say "this object should be free now" so the VM can say "so, it won't".

That I don't understand. First, one can't possibly know for sure when an object is freeable. Moreover, how could one even say "free up this object"? If you can even say that, then you'd have a pointer to it, giving it a positive reference count! But, secondly, and this is really my question, why should one care? Even if an object is marked for deletion, that memory won't be made available until the VM is good and ready. (When swept.) So, what's the advantage?

By analogy, when I save a file to disk, I don't care what sectors it's written to. The dos worries about that for me, so that I can get on with writing software that addresses the business problem at hand.

Comment Re:It's write once run everywhere with small niggl (Score 1) 157

But that doesn't stop people from doing really stupid things.

Oh, I hear that. The stories we could tell over beers!

But even when using Java's "native mechanism", things like filename case sensitivity can still bite you. And here's another example. When I start a Java thread, does that run in the same OS process or not? And if the answer is "that depends", then that has some serious implications for availability, testing, and even security.

Stroustrup famously quipped that Java is not platform independent -- it's a platform.

Comment Re:It's write once run everywhere with small niggl (Score 1) 157

Seriously, unless you are doing something weird, reasonably OK written java app would run under any platform. There might be some small issues, but cross-platform apps with Java are much much much easier to write than cross-platform apps with anything else.

Sure. If I'm writing an email client or something. But if I'm composing a complex system, then there are performance and functional characteristics that vary, and these could very well make or break the product. I appreciate the desire to defer architectural decisions to the last responsible moment. But picking the OS can drive so many other design decisions, that one should get that right almost from the beginning.

With Java predominantly on the server side instead of in the browser, what exactly is the use case that WORA is supposed to solve? Or put another way, who is writing cross-platform apps?

Comment Re:Java: Was write once run everywhere ever the ca (Score 1) 157

I have been developing server-side code for about a decade, and I have always done my development and testing on Windows, but deployed to either Linux or Solaris, without any platform problems whatsoever.

I find that a little scary.

But I'm curious. Do you do that because as a developer you find Windows more productive for you?

Comment Re:Oracle matters less thank you'd think (Score 1) 157

I have no industrial experience with phone software, so I can't speak to that. But the research surely delivered for software in the large. In the same way that compilers can no longer optimize code as well as virtual machines can, it's a bit conceited to think we could hand-code memory management of complex systems better than the computer itself.

Also, in addition to app performance, the second metric to consider is programmer productivity, and gc's impact there is incalculable.

Slashdot Top Deals

"May your future be limited only by your dreams." -- Christa McAuliffe

Working...