Click here to Skip to main content
15,912,756 members

Survey Results

Code Optimization   [Edit]

Survey period: 12 Mar 2001 to 18 Mar 2001

Is code that just works good enough for you? Or are you someone that strives to make it work well. (contributed by James R. Twine)

OptionVotes% 
I do the research, and make the whole thing as fast/efficient as possible.14025.97
I try to optimize a few critical areas here and there.33161.41
If it works, it works. That is good enough for me.325.94
Works well? You should be lucky the damn thing launches!213.90
Optimization does not matter these days.152.78



 
GeneralRe: Pathetic Java code-->crawls to snail's speed Pin
David Cunningham17-Mar-01 15:22
cofounderDavid Cunningham17-Mar-01 15:22 
GeneralRe: Pathetic Java code-->crawls to snail's speed Pin
James R. Twine18-Mar-01 15:48
James R. Twine18-Mar-01 15:48 
GeneralRe: Pathetic Java code-->crawls to snail's speed Pin
15-Mar-01 10:52
suss15-Mar-01 10:52 
GeneralRe: Pathetic Java code-->crawls to snail's speed Pin
James R. Twine16-Mar-01 11:10
James R. Twine16-Mar-01 11:10 
GeneralRe: Pathetic Java code-->crawls to snail's speed Pin
CodeGuy17-Mar-01 9:06
CodeGuy17-Mar-01 9:06 
GeneralRe: Pathetic Java code-->crawls to snail's speed Pin
James R. Twine17-Mar-01 11:31
James R. Twine17-Mar-01 11:31 
GeneralRe: Pathetic Java code-->crawls to snail's speed Pin
20-Mar-01 6:58
suss20-Mar-01 6:58 
GeneralRe: Pathetic Java code-->crawls to snail's speed Pin
James R. Twine21-Mar-01 3:39
James R. Twine21-Mar-01 3:39 
> Right. How much Java training do you have? I wouldn't feel qualified to comment
> on Smalltalk since I don't use it regularly. How much do you use Java?

   I would not comment on things that I do not know about (to do so would be stupid), and that should be *enough* for everyone else to know.  But just for those that do not know any better to not ask, here is a small list:

     o Learned Java over 4 years ago.
     o Implemented several small scale applications, like chat servers and clients (thin). Both browser-hosted and standalone.
     o Implemented some some other "utility" applications for use during development.
     o Studied and implemented several multi-threaded Java applications, employing techniques found in some older Java "performance" books, more recently "High-Performance JAVA Platform Computing" (a really good book, BTW).

> A coworker had created a simple test of C++ IO and std::map performance [...]

   I hope you used a good STL implementation.  And stored pointers to the strings in the map, and not references, so that the objects would not be copied each time the map had to reallocate (people make that mistake all the time).  (And I noticed that I misphrased my comment.  I am referring to C++ code that you control, not libraries that are written by Lord-knows-who, and perform Lord-knows-how-bad.)  OK...  Good.  We have one "link" so far.

> I'm sure you would be willing to post links, right?

   Be wary of who you choose to fence with, and attempt to copy concepts from.
    http://www.sosnoski.com/Java/Compare.html
    http://sprout.stanford.edu/uli/java_cpp.html
    http://www.javaworld.com/javaworld/jw-02-1998/jw-02-jperf.html
    http://www.dl.ac.uk/TCSC/UKHEC/JASPA/node8.html
   (Some of the above links show Java to be better in some areas, just to show that I am not only posting the links that agree with me.)  But here is the best "link" of all: is anyone out there using a Java VM (and matching SDK) that was actually written in Java for anything "real" (so-called high performance)?  Ever wonder why?

> The lawyers don't want a failure of a VM in a reactor to put them at risk.

   Now I know you are not saying that the disclaimer should just be ignored. Which brings me back to what I said before.  Does everyone even know that the disclaimers are there, let alone pay attention to them?

> Based on the way VC messes up code with optimizations enabled, they should
> also have a disclaimer

   Maybe.  Or you can turn them off, and do not try to have the compiler fix some of your mistakes for you.

> Is the purpose of your program memory management? NO. I rarely WANT to worry about that.

   True, the purpose of few programs is Memory Management.  I never said that the purpose of code would be Memory Management.  But anyone that is concerned about performance should be concerned about how their code is (mis)using memory.

> And as far as having a "broken" understanding of what new is, Java just has
> a different one. They are different languages after all.

   A "Broken understanding" with regard to how it works in C++. And yes, different languages; with different features, concerns, and USES.

> Is this real?? Any language can be used stupidly.

   And as we have recently seen, anybody can be stupid as well.

> I once worked tech support for a comipler vendor and had to explain to a user
> with 10+ years experience that you had to call delete when you new'ed something.

   Entropy abounds.

> Lisp has a GC. Are all Lisp programmers stupid?

   People are not trying to use Lisp as the solution to all development the same way that some people and companies are embracing Java.  That is what this thread is about.  Lisp has its place, and so does Java.

> [Re: bait] And this means???

   Lookup its meaning WRT postings on the Internet.

> And others refuse to accept that Java has a place. Both sides are wrong.

   Which is why I have said, many times already, that Java does have a place.  The trick is knowing where the line between using Java for something, and using C++ for something, is drawn (and in some cases blurred).

> I know plenty of people in many companies working in Java. So I still don't
> understand the post.

   Are these people trying to use Java as a be-all-end-all solution?  If not, you are lucky.  If so, you should understand the problem a bit more.  If you fail to understand any of my earlier posts, the fault lies with you.  I cannot explain things any simplier than I already have.

> Best Wishes also.

   And to you as well.

   Peace!








-=- James
GeneralRe: Pathetic Java code-->crawls to snail's speed Pin
23-Mar-01 7:44
suss23-Mar-01 7:44 
Generalnot many programs Pin
12-Mar-01 4:51
suss12-Mar-01 4:51 
GeneralRe: not many programs Pin
Christian Graus12-Mar-01 12:25
protectorChristian Graus12-Mar-01 12:25 
GeneralLittle modification of third option Pin
Slavo Furman12-Mar-01 2:36
Slavo Furman12-Mar-01 2:36 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.