HNHacker News
TopNewBestAskShowJobs

Olreich

711 karma · joined July 9, 2012

submissionscomments
Olreich··on Parquet: An efficient, binary file format for table data
Accounting wants to work with a portion of the Parquet database. Your options are: give them data in CSV/Excel formats, or hire a dev to work for accounting full time and still have them constantly complaining about having to wait on the dev to get them the data they need.

The programmers, data scientists, and other technical fields should never process data in Excel, but you can’t expect that of the whole organization, so exporting to it is important. At this point, I’d recommend XSLX as the export format because it’s harder to mess up the encoding, but libraries exist for CSV and others as well.

Olreich··on Nearly 40% of software engineers will only work remotely
> Suffer a 10-15% degredation in communications.

If your team is split across 3 timezones and 5 cities already, you're going to damage your communications even further by making everyone go into the office again.

Olreich··on 20M digits of pi in 1 minute using Julia
Y-cruncher is closed source, there’s no way to know the number of lines of code it uses compared to Julia.
Olreich··on “Clean” code, horrible performance
Never look at the dispatch of a big company’s Java code base then. It’s dynamic dispatch 400 layers deep for a single network call or file op or small amount of math. Sure those are more expensive operations, but the dynamic dispatch has continually out scaled the problem.
Olreich··on “Clean” code, horrible performance
Product velocity is not increased by spending a ton of time on complex type hierarchies and premature extensibility. It’s increased by having fewer classes and simpler functions that are faster to write tests for to get good coverage via end-to-end tests. The patterns of OOP increase the amount of time spent not solving the business needs. They also infuse the entire system with unnecessary slowness.
Olreich··on “Clean” code, horrible performance
If this is going to be a library where that’s a desirable feature, architect it for that feature. In the example, one easy way would have the coefficient table be expandable/replaceable. If you really need to run arbitrary user code, then write an interface that the user will conform to and call their code. You don’t even need OOP support to do that easily, just typed function pointers.
Olreich··on “Clean” code, horrible performance
To summarize: if you make the problem complex enough, then the specific performance methods used in the article don’t work. But hey, why not take your complex example? If you apply a polymorphic approach to Bézier curves and polygons, then you still get a 1.5x slowdown compared to a switch statement. If you have any commonality between your implementations of area for them, it’s harder to find, which could be worth 2x or more. If there is a common algorithm for calculating all polygons and curves, wasting work for simple shapes, but vastly improving cache and predictor performance, then you could be leaving another 5x on the table. Orienting the code around operations instead of types is still a win for performance with similar cognitive load compared to type hierarchies.

You’re right that once you’ve done the 15x performance gain that Casey demonstrates, the code is pretty brittle and prone to maintenance problems if the requirements change a lot. But I think we can have our cake and eat it too by maintaining our code with the simple path available to fall back to if we get a complicated new requirement. Need to add in complex cases that weren’t thought of before? Add them to new switch cases that are slower, and then keep looking for more performant ways of calculating things of need be.

Olreich··on I disapprove of what you say but I will defend to the death your right to say it
And you hit the struggle right there. Absolute is not the goal, even for free-speech absolutionists. What you define regular speech to be is different to what other people define, and while that might be okay, there is no consensus among any majority or even significant plurality of people about where the actual line between protected and non-protected speech should be.
Olreich··on Meta to ask many managers to become individual contributors or leave
I find it far more plausible that managers are paid more because of the default fiefdom hierarchy that you find in most corporate systems than because of anything inherent to the day-to-day job. CEO doesn’t think people lower on the totem pole should be paid more than them, so they hire people at lower income levels. Same for the VPs and the Directors and the layers of middle management until you get down to the ICs.
Olreich··on Major standard library changes in Go 1.20
You don’t even solve the problem by moving the memory on-die, as the majority of time is not spent sending the signal on traces, it’s waiting for the relatively slow memory to find, read, and send the data on the bus.

Expanding the cache so everything fits in it is one way to achieve the performance uplift of cache hits, but cache is expensive compared to memory, and current cache sizes are tiny compared to RAM. If cache gets 50x bigger tomorrow, chips will get at least 10x as hot, power-hungry, and expensive.

Olreich··on Ask HN: Strategies for working with engineers that are too smart?
Which of these is better is a matter of distance and scope. If x is only used locally and within a screen or two of the declaration, adding a data structure screens or files away will make things harder to parse. If x is used in many places, passed around to many functions, or is otherwise far away from where it’s needed, it should be replaced with something that has better naming and more robust structure. If it’s the latter, you should rename it away from x as well, as the name of the variable is the first thing that should get documented as you increase distance. If you have a `Status` type already, then you should use that even if X is hyper-local.

Of note, the nesting here seems suspect, why not use a three item tuple or a flattened data class? In many cases I find where people start arguing about naming or abstraction, there’s a way to simplify things further so it’s readable for everyone and easier to use inline. I always look for those now when I’m reaching for “you should rename this” or “you should restructure this” kind of comments.

Olreich··on Amazon to Lay Off over 17,000 Workers, More Than First Planned
There are brilliant devs at Amazon. There are poor devs at Amazon. The quality of the dev has very little bearing on promotion and hiring from what I can tell. Story telling and document writing appear to be the only things that are graded on a scale, everything else is pass/fail.
Olreich··on Modules, not microservices
Their programs interact with different APIs and constraints on many different sets of hardware. 5 different major hardware targets, 8 operating systems, and hundreds of versions of driver software. It’s hard to do all that well and keep things validated to continue running with minimal ability to update and support it. Web programs barely work on two browsers. Server targets are generally reduced to a single target (Docker or a specific distribution of Linux).

Their tiny data is rendering millions of polygons with real-time lighting, asset loading in the background, low latency input handling, etc. at 60fps+. If my API responds to the user in 100ms, they’re ecstatic. If their game responds to the user in 100ms (5-10 dropped frames) even a few times, they’re likely to ask for a refund or write a bad review, hurting sales.

The constraints are different, but game programmers do the same kinds of optimization social networks do, just for different problems. They avoid doing the N^2 version of lighting, path finding, physics simulations, etc. Social networks avoid it when searching through their graphs.

I think the web and other big tech companies should try thinking about problems the way game programmers do.

Olreich··on Ask HN: Concepts that clicked only years after you first encountered them?
Recursion is an obfuscated way to run a loop with a stack. At first it seems like magic, and makes things so much easier. When trying to replicate it the first time actually using a loop and stack it’s really hard to get right. But by the time you’ve done it two or three times, it’s as easy as breathing.

Similar, OOP is an obfuscated way to run a function with a context. The first time you separate the data in the context from an object, it’ll be hard to get it right and make it easier than to just use Objects and Methods. But once you’ve done it two or three times, it’s as easy as breathing.

You can optimize loading the context to be better than copying a bunch of unaligned data in lots of ways, but polymorphism is a common way to get there.

Olreich··on Ask HN: What is your favorite front end state management solution?
Things are faster than you’d expect. Tables with millions of items don’t work in any framework, but tables with a hundred items work in all of them. Since no one has really cracked the nut on performant UIs with lots of things going on, anything homegrown will be simpler and performant enough compared to the major competition.
Olreich··on What if your entire worldview was just because of near-zero interest rates?
Fun part of that is that the political systems are flawed as well and actively resist hiring new politicians who are more principled. In the US, it’s almost impossible to win without endorsement from Dem or Rep parties. Anywhere that does First Past the Post will devolve to two party rule at scale. Many countries have authoritarian regimes, so elections don’t matter. Even just drawing political lines is fraught and liable to bias against the will of the people based on existing precedent. Money in politics provides advantages to the rich and corporate interests.

Politicians are motivated to keep constituents happy, but only so far. The political systems generally provide a significant buffer for politicians to act on behalf of themselves or their donors and not get replaced.

Olreich··on Dear JetBrains, Don't mess with your UI
I think you would be shocked at how often UX designers get greenlit to make a refresh based on vague things like the current code base being hard to use or keeping up with the Joneses of other products or just to have new marketing pictures that look "modern". The default assumption that this effort was made without proper consideration is right more often than its wrong.

Maligning the devs? Not so much. Wanting them to show their work and explain why they think looking more like VSCode is a good idea? Very much so.

Olreich··on Staff Engineer Archetypes (2020)
I think that's because a good amount of 1x engineers could be 10x engineers if given the right kinds of support. When leadership makes sure they have that support, they become 10x engineers. If you only ever see clusters of 10x engineers, it's more likely to be about the factors around them than the engineers themselves.
Olreich··on Staff Engineer Archetypes (2020)
Abstraction is not a panacea. It's often the root cause of significant technical debt. Abstracting as late as possible is often the best course of action, as it give you more information about how to abstract from the initial implementation.
Olreich··on Staff Engineer Archetypes (2020)
> They lay operational traps everywhere in their quest to get things done fast (like directly embedding config data in code to avoid fixing the config format).

Specific to your example, rather than the sentiment, I think embedding config in code is highly valuable when you don't have a lengthy deployment cycle and have direct access to the source. It gives your compiler more information which can help prevent bad configurations (which are the cause of failures more often than anything else from what I've seen). Developers also have a better shot at feeling how badly configurable a particular component is when the configuration is code. It's much easier to hide the overly-configurable systems under a rug when the configuration is far away from implementation, in a DSL, in a different repository, or only visible at deployment.

Olreich··on Ask HN: How do I learn to communicate effectively?
Good communication requires empathy. Frame the entire conversation around understanding where the other person is coming from and what they know, and then add whatever knowledge you're trying to share. Without empathy for the audience, you're likely to explain too much, explain too little, or come off harsh or cold or whatever. Most communication strategies are designed to encourage empathy indirectly. You can generally skip them by focusing on empathy directly. The one strategy I think works well and doesn't come naturally from empathy is framing any opinions you have explicitly as your own: "I think X is the best" instead of "X is the best".
Olreich··on Learning Is Remembering
Anki is great for higher level learning as well. Instead of having just individual words, have full sentences or even paragraphs. If you can read it aloud and understand it, then you can mark it as learned, but if you need to use the definition or explanation for any of it, mark it as unlearned. Once you have a decent initial vocabulary and grammar, this is far more effective at pushing things into long-term memory. Most of language is contextual, so anything to increase the amount of context on an individual card will help with getting better holistic knowledge of the language.
Olreich··on Turns are better than radians
Got a reference for what that looks like with current notation? The internet is basically just showing the starting equation and ending equation and skipping all the intermediaries.
Olreich··on Turns are better than radians
If you go watch math lectures, there's a bunch of "x means Puppy Constant" or, "let's substitute in k for the Real component", or "let's signify <CONCEPT> by collecting these terms into a variable". My argument wouldn't be to replace ALL the variables with meaningful names, just the ones with a lot of meaning that a reader might not understand. It'd also be great if constants, variables, and functions all got naming conventions. Lowercase letters are variables, all caps for constants, etc. It saves a little bit on writing to shorten the variable names, but if the goal of math is to share and spread knowledge within the community or without, better naming and less-memorization would both help. You can also rename things for the working out and use friendlier names for the final equations, just tell people how you're renaming them and everyone will follow along and the programmers will stop trying to sell you one readable code.

Most importantly the flat dismissal and horror that many express when someone brings up adjusting the symbolic traditions of Maths should be investigated. Engage with why you feel so strongly that anything other than rigid adherence to tradition is sacrilege. Based on what I've heard, in order to be a great Mathematician, you need to hold onto tradition lightly and think outside the box. Rigid adherence to tradition doesn't sound like that to me.

Olreich··on Jonathan Blow on Societal Collapse (2019)
He's also claimed that our computers are 2+ orders of magnitude off the productivity that should be achievable while reaching his goals. It's not so much that all software of old was amazing, it's that we really have lost something when RemeDyBG is 1000x faster than Visual Studio, with Visual Studio having hundreds of years of development effort and RemeDyBG has a couple years of development effort.

His philosophy is that if we built software differently, we could build it faster and it would be faster. The emphasis on garbage collection and borrow checkers and everything else related to memory management misses the point (memory arenas are way better for the vast majority of use cases). The emphasis on Object-Oriented code is awful. The paradigm of RAII is completely counterproductive. There are very specific issues that Blow takes on, not just a general feeling of malaise.

Olreich··on Improving Postgres text search speed
It’s almost never faster to do two queries. But DBs are complicated query engines with sophisticated compilers, so you have to go in and try to convince the compiler to optimize the way you want that will make the query fast. EXPLAIN_ANALYZE is your best friend for understanding what the compiler thinks is best. And then you can adjust the query to convince it that it should do something faster.

In this specific case, I’d bet that having the FROM and JOIN tables reversed would be enough to get even better performance than 2 queries: `SELECT * FROM os JOIN o …`.

Olreich··on Ask HN: What's the next big thing that few people are talking about?
So what is the definition of a real hologram? Lots of points of light in 3D outside of the media projecting it seems like exactly what I’d expect for a hologram.
Olreich··on What’s going on with Google and Facebook hiring freezes?
Estimates put the workforce for AWS at ~100k-200k right now. AWS income is ~80b right now according to their Q2 earnings release. Based on these numbers, a person working for AWS is making Amazon ~$400k in revenue. The profit for AWS at the moment is 30% according to the Q2 filings and nets out to ~$24b. So, assuming 200k employees for AWS which is very software-developer heavy says they are making at least $120k per developer in AWS. If they think they can continue that trend, they should be hiring every last engineer they can get for less than $280k a year. If they think they can grow their margin, they should be hiring up to an even higher number.
Olreich··on How much health insurers pay for almost everything is about to go public
> “What we’re learning from the hospital data is that insurers are really bad at negotiating”

Do the insurers have any incentive to negotiate well? Since their customers are not very price-sensitive (since they aren't marketing directly to patients or doctors), I would imagine they don't have a huge incentive to do anything but apply a markup to whatever prices the hospital tells them it costs.

Olreich··on New UUID Formats
This article mostly just says: "If your data is small, then 56 bits is fine". Which is true. But if you are at 56 bits in your UUID, then just use an integer PK with 64 bits and you'll be fine a good deal longer. If your data might get large, an extra 64 bits to get a full 128bit UUID isn't expensive, and encoding in Base36 still yields 25 character UUIDs, which are pretty manageable: "abcdef-01234-56789-ghi-jklmno" (6-5-5-3-6, or max of a u16 for digits). I'm honestly shocked no UUID library makes it easy to export in Base36 with that grouping, it's very neat and tidy and easy to remember.
← PreviousPage 4 of 9Next →