Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
pron
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
59 ms
·
751.
▲
by
pron
1y ago
When it comes to desktop apps much of the memory is paged out to disk anyway when a program is not focused.
752.
▲
by
pron
1y ago
> The biggest current knock against Java I see is JNI Then you'd be happy to learn that it's been superseded by FFM: https://openjdk.org/jeps/454 (not in all situations, but in almost all). > The second
753.
▲
by
pron
1y ago
As refcounting and tracing are the two primary starting points for garbage collection, they're its two pillars so to speak (e.g. https://web.eecs.umich.edu/~weimerw/2012-4610/reading/bacon-... ), I don&
754.
▲
by
pron
1y ago
Modern tracing-moving GCs offer very efficient memory management algorithms that are often hard to beat on performance. Their price isn't so much performance anymore as memory footprint, while manual memory management (and refcounting
755.
▲
by
pron
1y ago
GraalVM is a separate product developed by an unrelated team. Its enterprise flavour is not considered an enterprise flavour of the JDK. The closest to an enterprise JDK from Oracle I can think of is the "Enterprise Performance Pack&qu
756.
▲
by
pron
1y ago
You can ask the JVM to dump the actual instructions ( https://javanexus.com/blog/printing-assembly-code-hotspot-ji... ). Just note that there may be differences between the very old APIs (as in your example), and the new
757.
▲
by
pron
1y ago
The only thing that's paid is support, and the OpenJDK folks are Oracle employees (well, the ~90% of them who do ~95% of the work on OpenJDK). OpenJDK is an Oracle project in the same sense that Chromium is a Google project. In fact, O
758.
▲
by
pron
1y ago
Sure, using arenas is very often straightforward, but it also very often isn't. For example, say you have a server. It's very natural to have an arena for the duration of some request. But then things could get complicated. Say th
759.
▲
by
pron
1y ago
Arenas are fantastic when they work; when they don't, you're in a place that's neither simple nor particularly efficient. Generational tracing garbage collectors automatically work in a manner similar to arenas (sometimes wor
760.
▲
by
pron
1y ago
> It’s the same as other layers we have like auto-vectorization where you don’t know if it’s working without performance analysis. The complexity compounds and reasoning about performance gets harder because the interactions get more com
761.
▲
by
pron
1y ago
Rust is as old now as Java was when JDK 6 came out. But it's not just Java. Look at Fortran, C, C++, JS, C#, PHP, Ruby, Go, and even the late-bloomer Python - no popular language had an adoption rate as low as Rust at its rather advanc
762.
▲
by
pron
1y ago
But C++ is over 40 years old, and Java et al. displaced it in like five minutes. And that the footprint savings aren't worth much is pretty much the point. If you get 1GB/core and you use less, then you can't run more program
763.
▲
by
pron
1y ago
It's perfectly valid to choose RAM over CPU. What isn't valid is believing that this tradeoff doesn't exist. However, cloud deployments are usually more CPU-constrained than RAM constrained, so it's important to know tha
764.
▲
by
pron
1y ago
> The talk you're so excited about actually shows this asymptote. Oh, I see the confusion. That asymptote is for the hypothetical case where the allocation rate grows to infinity (i.e. remains constant per core and we add more cores
765.
▲
by
pron
1y ago
Smalltalk had design mistakes aplenty. Comparing the downsides of the languages you like less with the upsides of the languages you like more is not a great way to understand why things are done the way they're done. Usually, it's
766.
▲
by
pron
1y ago
> Nah, in the model you're imagining now the program takes infinite time. Wat? Where did you get that? > That's because your model is of a GC system - where ensuring no garbage really would need infinite time and a language
767.
▲
by
pron
1y ago
> That talk is mainly a GC person assuring you and perhaps themselves that all this churn is actually desirable. While "Actually this was a terrible idea and I regret it" ... The speaker is one of the world's leading exper
768.
▲
by
pron
1y ago
> Rust achieves practical minimization, if not outright eradication, of a set of errors even in practice. And not just memory safety errors. It achieves something in one way, while requiring you to pay some price, while other languages a
769.
▲
by
pron
1y ago
I have no idea what it's using its CPU on, whether it has anything to do with memory management, or what memory management algorithm is in use. Obviously, the GC doesn't need to do any compaction if the program isn't allocati
770.
▲
by
pron
1y ago
> It goes without saying that memory compaction involves a whole lot of extra traffic on the memory subsystem It doesn't go without saying that compaction involves a lot of memory traffic, because memory is utilised to reduce the fr
771.
▲
by
pron
1y ago
> It turns out that using more RAM costs you more CPU Yes, memory bandwidth adds another layer of complication, but it doesn't matter so much once your live set is much larger than your L3 cache. I.e. a 200MB live set and a 100GB li
772.
▲
by
pron
1y ago
We also got Java and Python (and VB for a while), which means there is no intrinsic, irrational bias against those approaches. A romantic view of those languages tends to ignore their serious shortcomings at the time they were presented. It
773.
▲
by
pron
1y ago
> The RAM trade off is excellent for normal sizes but if you scale enormously the trade off eventually reverses I don't think you've watched the talk. The minimal RAM-per-core is quite high, and often sits there unused even t
774.
▲
by
pron
1y ago
> In a better, saner world, we'd writing Ada++ not C++. As someone who worked on safety-critical air-traffic-control software in the nineties, I can tell you that our reasons for shifting to C++ were completely sane. Ada had some co
775.
▲
by
pron
1y ago
> The problem with this statement is that without a memory safety invariant your code doesn't compose Yes, but that holds for any correctness property, not just the 0.0001% of them that memory safe languages guarantee. That's
776.
▲
by
pron
1y ago
But software isn't developed for its own sake. It's built to serve some purpose, and it's through its purpose(s) that the selection pressures work. It's like Betamax fans saying that people were wrong to want a longer re
777.
▲
by
pron
1y ago
It isn't optional, and yet it's also not at any cost, or we'd all be programming in ATS/Idris. From those languages' vantage point, the guarantees Rust makes are almost indistinguishable from C. Yet no one says, &qu
778.
▲
by
pron
1y ago
> we already have enough unsafe languages as it is By that logic, we definitely have enough safe languages as it is, as there are many more. But this safe/unsafe dichotomy is silly, and is coloured by languages that are unsafe in
779.
▲
by
pron
1y ago
Similar to Java: String.chars().count(), String.codePoints().count(), and, for historical reasons, String.getBytes(UTF-8).length
780.
▲
by
pron
1y ago
In Java, " ".codePoints().count() ==> 5 " ".chars().count() ==> 7 " ".getBytes(UTF_8).length ==> 17 (HN doesn't render the emoji in comments, it seems)
More ›