[-] FizzyOrange@programming.dev 13 points 3 weeks ago

Yeah... I have 100k rep (almost exactly!) and I don't use it any more. It doesn't have the network effects, so even if there is a question that AI can't answer (which does still happen despite what some people seem to think), I don't go to Stackoverflow, I go somewhere else. A forum, GitHub repo discussions, even IRC once (OpenOCD still uses that for some weird reason - they were extremely helpful though).

It had a good run. RIP.

[-] FizzyOrange@programming.dev 13 points 7 months ago

Terrible title. The article is about the risks of everyone using GitHub. That doesn't mean GitHub is destroying the open source ecosystem. In fact it's the complete opposite - GitHub massively helps the open source ecosystem. That's why everyone uses it in the first place!

[-] FizzyOrange@programming.dev 13 points 1 year ago

They won't ban corporate VPNs.

[-] FizzyOrange@programming.dev 12 points 1 year ago

TL;DR: yes.

[-] FizzyOrange@programming.dev 13 points 1 year ago

Gotta agree on the name. Please choose meaningful names especially for low level components like drivers, libraries and CLI tools. It's fine for end-user facing applications to have unique names like Blender, Krita, Inkscape, Chrome, etc. But nobody wants to have to look up what the name of random system packages is.

[-] FizzyOrange@programming.dev 13 points 1 year ago

Use -ffast-math... if you dare. Or just use

inline double position_from_steps(int steps) {
  return (2.0 * PI / 4096.0) * steps;
};

The reason it doesn't optimise it into one multiplication is because that isn't actually the same calculation. Floating point numbers aren't real numbers, so it isn't true that (a * b) / c == (a / c) * b. Since the "optimisation" would actually change the semantics, compilers don't do it by default.

-ffast-math says "hey I don't care about reliable semantics; just do whatever to make it fast". But it also does a load of stuff that you may find surprising. so you really shouldn't use it. Much better just to reorganise your code.

You can also use -funsafe-math-optimizations which is the more specific subset of -ffast-math that does this particular optimisation. See https://gcc.gnu.org/wiki/FloatingPointMath

Also I would question if it matters. This micro-optimisation will make zero difference on x86. On a microcontroller (I assume what you're actually using if you're encoding motor positions) it might matter a bit more but double check your microcontroller even has an FPU. Lots don't. Even if it does, doing it in integer space will probably be faster (though not necessarily).

[-] FizzyOrange@programming.dev 13 points 2 years ago

This totally might be true, but the fact that he got as far as measuring the same latency on X and Wayland... and then just gave up and is like "well never mind what the measurements say, it's definitely Wayland"... Hmm.

You gotta do the measurements. It's probably not even that hard, all you need is a USB mouse emulator (any microcontroller with USB peripheral support can do this and there are tons of examples) and a photodiode.

You don't even need to worry about display latency if you are just comparing X with Wayland.

[-] FizzyOrange@programming.dev 13 points 2 years ago

... in one benchmark.

[-] FizzyOrange@programming.dev 13 points 2 years ago

This, of course, only works on little-endian machines. On big-endian machines, c has to be bytereversed.

Interesting advantage of little endian!

[-] FizzyOrange@programming.dev 13 points 2 years ago

Yeah... It's going to take a whole lot more than $1m for this. I am skeptical.

Also not super enthused about another browser written in C++. I skimmed some of their code and it seems pretty high quality, but still... this is going to be chock full of security bugs.

Servo is definitely the more interesting project.

[-] FizzyOrange@programming.dev 12 points 2 years ago

I mean... let's just hope he isn't doing this professionally.

[-] FizzyOrange@programming.dev 13 points 2 years ago

A recent notable example is xz, but there’s also event-stream npm package a few years ago that got infected with Bitcoin stealing code.

They're asking if the entire project is somehow fake, not if it's a real project that got backdoored. That's obviously impossible to tell just based on stars, language quality, and similar heuristic signals.

view more: ‹ prev next ›

FizzyOrange

0 post score
0 comment score
joined 2 years ago