• 0 Posts
  • 74 Comments
Joined 1 year ago
cake
Cake day: June 14th, 2023

help-circle

  • addie@feddit.ukto196@lemmy.blahaj.zoneI don't make the (rule)s
    link
    fedilink
    arrow-up
    17
    arrow-down
    2
    ·
    2 days ago

    I feel that ‘gender’ is probably a misleading term for the languages that have ‘grammatical gender’, it rarely has anything to do with genitalia. ‘Noun class’, where adjectives have to decline to agree with the class would fit better in most cases.

    English essentially does not have decline adjectives, except for historical outliers like blond/e where no-one much cares if you don’t bother, and uses his / hers / its / erc using a very predictable rule. So no ‘grammatical gender’.







  • Because if you disable browser autocomplete, what’s obviously going to happen is that everyone will have a text file open with every single one of their passwords in so that they can copy-paste them in. So prevent that. But what happens if you prevent that is that everyone will choose terrible, weak passwords instead. Something like September2025! probably meets the ‘complexity’ requirement…


  • addie@feddit.uktoProgrammer Humor@programming.devPsychopath Dev
    link
    fedilink
    arrow-up
    49
    arrow-down
    4
    ·
    edit-2
    27 days ago

    A bit like when we renamed all the master/slave terminology using different phrasing that’s frankly more useful a lot of the time, I think it’s about time we got rid of this “child” task nonsense. I suggest “subtask”. Then we can reword these books into something that no-one can make stupid jokes about any more, like “how to keep your subs in line” and “how to punish your subs when they’ve misbehaved”.


  • Well now. When we’ve been enforcing password requirements at work, we’ve had to enforce a bizarre combination of “you must have a certain level of complexity”, but also, “you must be slightly vague about what the requirements actually are, because otherwise it lets an attacker tune a dictionary attack against you”. Which just strikes me as a way to piss off our users, but security team say it’s a requirement, therefore, it’s a requirement, no arguing.

    “One” special character is crazy; I’d have guessed that was a catch-all for the other strange password requirements:

    • can’t have the same character more than twice in a row
    • can’t be one of the ten-thousand most popular passwords (which is mostly a big list of swears in russian)
    • all whitespace must be condensed into a single character before checking against the other rules

    We’ve had customers’ own security teams asking us if we can enforce “no right click” / “no autocomplete” to stop their users in-house doing such things; I’ve been trying to push back on that as a security misfeature, but you can’t question the cult thinking.



  • addie@feddit.uktoxkcd@lemmy.world2982: Water Filtration
    link
    fedilink
    English
    arrow-up
    44
    arrow-down
    1
    ·
    28 days ago

    The joke about adding well water back in again at the end is “correct”. Reverse osmosis removes 100% of the solids from the water, but drinking water usually contains small quantities of solids - you can see a breakdown on the label of some bottled water. Completely pure water would leach all of the solids that have built up on the insides of water pipes over the decades, and leaches away the protective oxide layer from metal pipework, causing it to corrode surprisingly rapidly. It also tastes pretty shitty - kind of “dead”. So a small amount of high-solids water is mixed back in after RO to bring the water back to normal levels.

    All that other shit in the diagram? No. Purification and treatment takes place after the mixing step, it would be crazy not to.




  • addie@feddit.ukto196@lemmy.blahaj.zoneRule
    link
    fedilink
    arrow-up
    13
    ·
    1 month ago

    It’s been a perpetual source of surprise to me that curry houses are so ‘non-specific’. Pakistan and India together make about 1.7 billion people, about a third of the planet’s population, and I’d have thought an easy way to distinguish a restaurant would be to offer something more region-specific, but it’s fairly rare.

    Here in the UK, the majority of curry houses are Bangladeshi - used to be the vast majority, now it’s more like 2/3rds. We’ve a couple of ‘more specific’ chains - both Bundobust and Dishoom do Mumbai-style, and they’re both fantastic - and there’s a few places that do well with the ‘naturally vegan’ cuisines, but mostly you can go in to a restaurant and expect the usual suspects will be on the menu.

    Same goes for Chinese restaurants - I don’t believe that a billion people all eat the same food, it’s too big a place for the same ingredients to be in season all the time. Why are they not more specific, more often?



  • You can write an unmaintainable fucking mess in any language. Rust won’t save you from cryptic variable naming, copy-paste code, a complete absence of design patterns, dreadful algorithms, large classes of security issues, unfathomable UX, or a hundred other things. “Clean code” is (mostly) a separate issue from choice of language.

    Don’t get me wrong - I don’t like this book. It manages to be both long-winded and facile at the same time. A lot of people seem to read it and take the exact wrong lessons about maintainability from it. I think that it would mostly benefit from being written in pseudocode - concentrating on any particular language might distract from the message. But having a few examples of what a shitfest looks like in a few specific languages might help


  • My old job had a lot of embedded programming - hard real-time Z80 programming, for processors like Z800s and eZ80s to control industrial devices. Actually quite pleasant languages to do bit-twiddling in, and it’s great to be able to step through the debugger and see that what the CPU is running is literally your source code, opcode by opcode.

    Back when a computers were very simple things - I’m thinking a ZX Spectrum, where you can read directly from the input ports and write directly into the framebuffer, no OS in your way just code, then assembly made a lot of sense, was even fun. On modem computers, it is not so fun:

    • x64 is just a fucking mess

    • you cannot just read and write what you want, the kernel won’t let you. So you’re going to be spending a lot of your time calling system routines.

    • 99% of your code will just be arranging data to suit the calling convention of your OS, and doing pointless busywork like stack pointer alignment. Writing some macros to do it for you makes your code look like C. Might as well just use C, in that case.

    Writing assembly makes some sense sometimes - required for embedded, you might be writing something very security conscious where timing is essential, or you might be lining up some data for vectorisation where higher-level languages don’t have the constructs to get it right - but these are very small bits of code. You would be mad to consider “making the whole apple pie” in assembly.


  • PS3 most certainly had a separate GPU - was based on the GeForce 7800GTX. Console GPUs tend to be a little faster than their desktop equivalents, as they share the same memory. Rather than the CPU having to send eg. model updates across a bus to update what the GPU is going to draw in the next frame, it can change the values directly in the GPU memory. And of course, the CPU can read the GPU framebuffer and make tweaks to it - that’s incredibly slow on desktop PCs, but console games can do things like tone mapping whenever they like, and it’s been a big problem for the RPCS3 developers to make that kind of thing run quickly.

    The cell cores are a bit more like the ‘tensor’ cores that you’d get on an AI CPU than a full-blown CPU core. They can’t speak to the RAM directly, just exchange data between themselves - the CPU needs to copy data in and out of them in order to get things in and out, and also to schedule any jobs that must run on them, they can’t do it themselves. They’re also a lot more limited in what they can do than a main CPU core, but they are very very fast at what they can do.

    If you are doing the kind of calculations where you’ve a small amount of data that needs a lot of repetitive maths done on it, they’re ideal. Bitcoin mining or crypto breaking for instance - set them up, let them go, check in on them occasionally. The main CPU acts as an orchestrator, keeping all the cell cores filled up with work to do and processing the end results. But if that’s not what you’re trying to do, then they’re borderline useless, and that’s a problem for the PS3, because most of its processing power is tied up in those cores.

    Some games have a somewhat predictable workload where offloading makes sense. Got some particle effects - some smoke where you need to do some complicated fluid-and-gravity simulations before copying the end result to the GPU? Maybe your main villain has a very dramatic cape that they like to twirl, and you need to run the simulation on that separately from everything else that you’re doing? Problem is, working out what you can and can’t offload is a massive pain in the ass; it requires a lot of developer time to optimise, when really you’d want the design team implementing that kind of thing; and slightly newer GPUs are a lot more programmable and can do the simpler versions of that kind of calculation both faster and much more in parallel.

    The Cell processor turned out to be an evolutionary dead end. The resources needed to work on it (expensive developer time) just didn’t really make sense for a gaming machine. The things that it was better at, are things that it just wasn’t quite good enough at - modern GPUs are Bitcoin monsters, far exceeding what the cell can do, and if you’re really serious about crypto breaking then you probably have your own ASICs. Lots of identical, fast CPU cores are what developers want to work on - it’s much easier to reason about.


  • There’s three regions missing here - region 0 is “worldwide”, region 7 is “special purpose”, Oscar screening DVDs and the like, and region 8 is “international waters” for cruise ships and things. You can set several regions on the same disk, to make a 2/4/5 and the like. Set each region as a bit, and you can store that in a single byte - that makes it very easy to flash the firmware on DVD players to decide which disks they can play. Aus/NZ will want content in English and Latin America will want Spanish or Portuguese, so the DVD consortium can still get up to their often-illegal, certainly immoral, price fixing and bullshit.

    Really, fuck DVDs. So much potential in the increased capacity, and then it was mired in crap like this and “disabled user operations” so that you can’t skip trailers. Time to raise the black flag and set sail for prosperous waters, me hearties.