That requires some form of self describing format and will probably look like a sparse matrix in the end.
- 0 Posts
- 9 Comments
It might also introduce spurious data dependencies
Those need to be in the in smallest cache or a register anyway. If they are in registers, a modern, instruction reordering CPU will deal with that fine.
to store a bit you now need to also read the old value of the byte that it’s in.
Many architectures read the cache line on write-miss.
The only cases I can see, where byte sized bools seems better, are either using so few that all fit in one chache line anyways (in which case the performance will be great either way) or if you are repeatedly accessing a bitvector from multiple threads, in which case you should make sure that’s actually what you want to be doing.
C/C++ considers an nonzero number, as your true value but false is only zero. This would allow you to guard against going from true to false via bit flip but not false to true.
Other languages like rust define 0 to be false and 1 to be true and any other bit pattern to be invalid for bools.
anton@lemmy.blahaj.zoneto Open Source@lemmy.ml•GNU Taler v1.0 released and is operating in Switzerland1·7 days agomostly present in fairytales these days
It’s also the currency in the german language donald duck comics.
anton@lemmy.blahaj.zoneto Ask Lemmy@lemmy.world•What's your plan for the Zombie Apocalypse?3·10 days agoHaving the weight of 10 cars on the footprint of one can be a problem, even if the ferry can normally transport 100.
You should look out for IFVs from an airborne unit.
anton@lemmy.blahaj.zoneto Ask Lemmy@lemmy.world•What's your plan for the Zombie Apocalypse?3·10 days agoAre you sure the ferry could take the tank?
anton@lemmy.blahaj.zoneto Uplifting News@lemmy.world•Luigi Mangione's legal defense fund hits $1 million in donationsEnglish1·14 days agoDeath penalty cases drag on long and if he gets acquitted, I have a feeling the money will go other people’s legal funds.
anton@lemmy.blahaj.zoneto Uplifting News@lemmy.world•Luigi Mangione's legal defense fund hits $1 million in donationsEnglish1·14 days agoIf they had a case, they would have to cheat so blatantly.
- The made up snich.
- The prosecutor withholding evidence.
- The media spectacle to taint potential jurors.
- The officer turning on their body cam on after handling the backpack for a few minutes and then “finding” the gun and manifesto.
That boolean can indicate if it’s a fancy character, that way all ASCII characters are themselves but if the boolean is set it’s something else. We could take the other symbol from a page of codes to fit the users language.
Or we could let true mean that the character is larger, allowing us to transform all of unicode to a format consisting of 8 bits parts.