jmcomets
Joined 12 years ago
Joined 12 years ago
unsigned add_v5(unsigned x, unsigned y) {
if (x == y) return 2 * x;
return x + y;
}
Results in: add_v5(unsigned int, unsigned int):
lsl w8, w0, #1
add w9, w1, w0
cmp w0, w1
csel w0, w8, w9, eq
ret
(armv8-a clang 21.1.0 with O3)If compiler folks can chime in, I'm curious why incrementing in a loop can be unrolled and inspected to optimize to an addition, but doubling the number when both operands are equal can't?
2) C++, my employer's choice. Their rationale: easier to hire people with experience, internal codebase is mostly C++ so tooling/people more versed.
3) Rust. For me it's just easier overall to work with. It takes me an hour or so to get my head back into Rust's standard library and idioms/quirks, but afterwards it feels much better to work with: dev. workflow, testing, expressiveness. Plus it catches programming errors for me every once in a while.
4) I wish Rust had wider adoption by the industry. It's always compared to C/C++/Java/Go and the usual argument boil down to "not enough people use it".
5) I wish C++ had better compiler error messages. I have to rely on instinct when it's not scrolling through nested template/SFINAE errors to understand what's happening. Rust tells me "here's what's wrong" 99% of the time.
We visited an old school basement, which was used as a bunker for members of the Resistance. The school itself was razed and rebuilt over at some point, but the Catacombs still hold traces of this period. Being there felt very...intimate. Nothing like you'd see in a museum or a documentary, we were in the same place as those back then.
A couple things I wanted to point out when reading this:
- RTO does not imply sharing a 3D space with those you collaborate with (e.g. distributed teams).
- There is no data that proves that in-person work is more "creative" or "collaborative", simply because it's not measurable.
- You assume Google's intentions to always driven by data rather than appealing to stakeholders.
Also consider who would be more likely to respond in this thread: people heavily invested in or against remote work (since there is no actual data). Always-relevant XKCD: https://xkcd.com/386/
My opinion is that indexes should be either logical (ex: used for exclusion constraints) or purely for performance (tradeoff space for better QPS). Query patterns change, specs change, so monitoring your DB's performance is the way to go.
I want languages to do less magic, not more, since I read code more than I write it.
Also anecdotal, but I've met my share of early bird programmers. I often wonder how much of these habits are driven by ~~stereotypes~~ culture, since theoretically your energy level depends mostly on your lifestyle.
Now, you could also have a well organized test suite that goes from most obvious to most detailed, split into sections for each use-case, but this sounds a lot more tedious than "write a one-line comment describing the unit test".
I wouldn't consider this "a few buttons", it's enough to turn off the less savvy users