Java is actually pretty fast if you don't do stupid things. It's just that Java programmers tend to produce pretty complex OO code with lots of small objects that kill performance. But still, compared to other "modern" languages like Python or Ruby, Java is very fast.
I could turn your claim on its head and state that explicit memory management is part of the reason software is as buggy as it was in 1997.
Explicit memory management is a form of premature optimization and it's error prone: bugs, sometimes serious security bugs, can be introduced (use after free anyone?). So while it's obvious that my claim is true, you provided no evidence for yours.
a) you posted nothing proving your claim. It's really not that difficult to manage memory. I've written several data structures in C using malloc/free without much trouble.
b) since we are using psudo proof: Garbage collection breeds lazy and unskilled programmers which leads to aweful software like Batman. Not to mention how awful it is to bounce pointers all over the place raping the cache, and wasting tons of cpu cycles cleaning up and allocating memory whe its not needed.
11 comments
2 u/criminalmacabre 24 Jun 2015 23:49
They don't teach that in programming? Here in spain they hammer you about the von newman machine, components of a computer and how memory works.
1 u/icemaze 24 Jun 2015 20:17
Thank Knuth for garbage collection.
3 u/CirdanValen 24 Jun 2015 21:13
Garbage collection is part of the reason software still runs as slow as it did in 1997
3 u/SuperImaginativeName 24 Jun 2015 21:14
Lol what? Have you actually used any modern languages since 1997? And no not shitty Java, that's slow for everything.
1 u/geist 24 Jun 2015 21:43
Hey! Don't diss Java.
0 u/adrianN 25 Jun 2015 20:34
Java is actually pretty fast if you don't do stupid things. It's just that Java programmers tend to produce pretty complex OO code with lots of small objects that kill performance. But still, compared to other "modern" languages like Python or Ruby, Java is very fast.
1 u/icemaze 25 Jun 2015 09:35
I could turn your claim on its head and state that explicit memory management is part of the reason software is as buggy as it was in 1997.
Explicit memory management is a form of premature optimization and it's error prone: bugs, sometimes serious security bugs, can be introduced (use after free anyone?). So while it's obvious that my claim is true, you provided no evidence for yours.
0 u/CirdanValen 25 Jun 2015 16:26
a) you posted nothing proving your claim. It's really not that difficult to manage memory. I've written several data structures in C using malloc/free without much trouble.
b) since we are using psudo proof: Garbage collection breeds lazy and unskilled programmers which leads to aweful software like Batman. Not to mention how awful it is to bounce pointers all over the place raping the cache, and wasting tons of cpu cycles cleaning up and allocating memory whe its not needed.
1 u/icemaze 25 Jun 2015 17:30
You did not address my claims. GC is less error prone, and the performance hit is often (not always, but often) justified.
You want proof that manual memory management is error prone? Here it is. Wait, here's some more.
You want proof that GC performs BETTER than manual memory management for SOME (not all) workloads? Here it is
Can you please quit your jihad against GC and try to embrace a more balanced view?
0 u/Scaliwag 01 Jul 2015 03:22
Garbage collection does not necessarily mean tracing garbage collection.
Reference counting works fine most of the time, unless you're doing some real-time software.
0 u/POSE 30 Jun 2015 09:59
I bookmarked this. Thanks.