@cvi said in How in the hell does this feature work?:
@ben_lubar said in How in the hell does this feature work?:
Apart from CPU cache stuff,
Yeah, apart from what's probably the main bottleneck on a modern system, the difference is pretty negligible...
Besides, the innermost loop essentially extracts a few bits from each pixel channel and then compares it to some magic values (of which you can keep all three sets in the cache, incidentally). The first part (extracting the bits) is the same for each payload. You do it three times, but only need to do it once. (I'm assuming that the branch is taken relatively rarely.)
Well, we are talking web scale, where it's apparently dandy to consume 1.6GB of RAM to serve a mostly idle website, so inefficient loops are perfectly cromulent!