Game optimization sucks in current day because 90% of game developers do not have a rigorous handle on mathematics akin to?

Game optimization sucks in current day because 90% of game developers do not have a rigorous handle on mathematics akin to Ganker automatons.

Thalidomide Vintage Ad Shirt $22.14

DMT Has Friends For Me Shirt $21.68

Thalidomide Vintage Ad Shirt $22.14

  1. 9 months ago
    Anonymous

    yeah that looks like a very maintainable and not buggy way to write things for a game studio

    • 9 months ago
      Anonymous

      That's okay for a singleplayer release.

    • 9 months ago
      Anonymous

      >a ten line function with a well defined input and output and no side effects
      Yes. It rarely gets as good as this outside of toy examples.

      • 9 months ago
        Anonymous

        >no side effects
        a coward's way

    • 9 months ago
      Anonymous

      what's so buggy about it, worst thing about it is the function naming. I would have called it something like Q_invsqrt, but I'm not John Carmack and they probably had their reasons.

      If I wanted to implement it a different way, I would delete everything inside except the return y. Now if you remotely even could tell me from a quick look what this does. It would be impressive

      • 9 months ago
        Anonymous

        >rustroony
        Go back

      • 9 months ago
        Anonymous

        God rust is an ugly language.

      • 9 months ago
        Anonymous

        rust is such a shitty tryhard language

    • 9 months ago
      Anonymous

      why the frick would you need to maintain a pure function that calculates square root?

      • 9 months ago
        Anonymous

        Because it exploits architecture-specific bit shifting "glitch/feature" that may or may not work in future? And because it doesnt give exact square root, just approximation, which may not be accurate enough in your future projects?

  2. 9 months ago
    Anonymous

    i think it's more likely that software projects have gotten so big that it's hundreds of programmers all working on different components of the same software.
    like yeah, developers used to use bitshifting tricks and writing microcontroller code in asm but that's because they had to back then to maximize battery life or performance.
    computers can do so much more now that it would take an eternity to do all of that stuff.

    • 9 months ago
      Anonymous

      That's a non-issue, really, because all it takes to not frick it up is proper management. If there's one thing games today are lacking is proper management - it's all about pushing the product for more profit, which creates haste, and when there's haste, there's absolutely no proper communication between people, departments, the whole project, and most importantly, no proper testing.

      • 9 months ago
        Anonymous

        You can tell this anon has never had a job

        • 9 months ago
          Anonymous

          Dude managers have so little to do and somehow manage to frick that up lmao

          Like all they have to do is make a spreadsheet and keep everyone on the same page. And they manage to frick that up so bad.
          Guess they don't get enough time in between socializing to do actual work.

        • 9 months ago
          Anonymous

          That's a non-issue, really, because all it takes to not frick it up is proper management. If there's one thing games today are lacking is proper management - it's all about pushing the product for more profit, which creates haste, and when there's haste, there's absolutely no proper communication between people, departments, the whole project, and most importantly, no proper testing.

          He is right though. Why do you think modern games routinely fail to deliver on elementary stuff like implementing ladders (starfield)?

          It isnt because these mechanics are some lost archeotech. They are trivial. Its because the game was already worked on months or years before they got to implementing ladders and trying to implement them >>now>> into code that has tons built upon it could cause tons of unforeseen issues. So it is really just project directors not doing their job (knowing what direction you're going and whats needed so you can relay it to regular mooks).

          The job of programmer is to program whats told. The job of manager is to manage and share workloads. If the manager cannot relay the message upwards that this isnt a way to get things done, thats on manager. If the ones in creative control cannot vocalize what they want exactly, thats on them. And please do notice I am not saying managers have creative control (necessarily, exceptions apply)

      • 9 months ago
        Anonymous

        Dude managers have so little to do and somehow manage to frick that up lmao

        • 9 months ago
          Anonymous

          I feel fortunate with managers/project managers I've had in software development, they actually shield devs from business and office shit and bridge the gap between them only when it's relevant.
          I'm actually thankful to have the ones I've had because they shield the devs from constant speculation and ideas that aren't concrete things that the developers should actually implement.

  3. 9 months ago
    Anonymous

    game optimization sucks nowadays because the hardware is now good enough that you don't need that much optimization

    • 9 months ago
      Anonymous

      Could be much better and reach more people.
      I thought these subhumans are be business oriented.

      • 9 months ago
        Anonymous

        The venn diagram for "people with shit hardware" and "people who can't afford your game" is almost a circle.

  4. 9 months ago
    Anonymous

    This function becomes incorrect after 2 decimal places compared to using math.h sqrt btw

    • 9 months ago
      Anonymous

      The whole point was that for the purpose of the engine, that was good enough. That's how optimization works btw.

    • 9 months ago
      Anonymous

      yeah, that's generally how approximation goes. you sacrifice accuracy for speed.
      like the old sonic games used trig functions heavily, but to conserve computing power, they precalculated the values they needed and used a lookup table instead.

  5. 9 months ago
    Anonymous

    undefined behavior

  6. 9 months ago
    Anonymous

    Am a developer.
    You don't need to know math to make software or games except for very small use cases (less than 5%).
    You definitely don't need to know anything more than algebra.

    • 9 months ago
      Anonymous

      Thats your average JS+Angular/React 90 IQ codemonkey everyone

      • 9 months ago
        Anonymous

        Im a pure developer (Java, C++)
        But there is a JS dev here hes fricking moronic so I agree about the 90 iq part. Its probably lower tbh.

        • 9 months ago
          Anonymous

          Thats your average JS+Angular/React 90 IQ codemonkey everyone

          Now I want to mess with him lmao. I will ask him hard logic questions and see him squirm lol.

      • 9 months ago
        Anonymous

        I am an average React codemonkey and I make over half as much as the average gamedev while never having crunch or overtime
        Fun fact: EVERYTHING to do with hardware also pays peanuts with the sole exception of some nvidia divisions.

        • 9 months ago
          Anonymous

          I am an average software tester and I get paid about the same as you barely doing any work at all

      • 9 months ago
        Anonymous

        You know it's true. The vast majority of devs will never need more than basic maths.

    • 9 months ago
      Anonymous

      >You don't need to know math to make software or games
      You do if you want it to be good.

    • 9 months ago
      Anonymous

      Depends on what specialization you're getting into. AI requires deep knowledge in linear algebra and calculus. If you're specializing even deeper into natural language processing, then you also need to learn linguistics.

    • 9 months ago
      Anonymous

      and thats why optimization sucks, theres no passion in people who write games anymore, its just well paying job for normies who dont give a frick about PCs or computer science

  7. 9 months ago
    Anonymous

    they don't need to optimize shit because they can just say "it was made with DLSS in mind" and call it a day

  8. 9 months ago
    Anonymous

    And doom was still running like shit on most computers of the day.

  9. 9 months ago
    Anonymous

    >do not have a rigorous handle on mathematics
    bithacking has very little to do with mathematics and is mostly a relic of time where a single person could make sense of how a compiler works
    deep wizardry isn't some lost art, it's art that simply doesn't exist nowadays outside of some edge cases in networking and in HFT

  10. 9 months ago
    Anonymous

    Except Carmack literally didn't write that and didn't understand how it worked either, he just copied it from some forum or something

    • 9 months ago
      Anonymous

      From some math PhD who described it back in 80s

    • 9 months ago
      Anonymous

      It wasn't carmack that did that one, it was apparently american mcgee. And it's just newton-rhapson with a good initial guess.

  11. 9 months ago
    Anonymous

    People expect to have their game run at 60 or even 120 fps, having fully simulated world update every 8ms and complain about the good old time when I was running stalker at 17 fps and oblivion in 640x480.

  12. 9 months ago
    Anonymous

    No, CPUs are very good now. You can be almost as stupid as you want with math implementations and get away with it.
    Performance sucks because devs don't understand computers. What kills performance is hardware interrupts, like constantly making disk accesses, polling i/o devices way more than you need to, spamming draw calls to the gpu.

    • 9 months ago
      Anonymous

      >No, CPUs are very good now. You can be almost as stupid as you want with math implementations and get away with it.
      no you moron, you can easily wienerblock your game with cpu performance if you frick up threading
      in comparison gpu is much more difficult to frick up, it'll just be a few frames slower and the slaves who write drivers will fix your shit for free if your game does well anyway
      >like constantly making disk accesses, polling i/o devices way more than you need to
      you seem to have confused vidya with databases or are using a 5400 rpm hdd in an age where a 2tb ssd costs $100

  13. 9 months ago
    Anonymous

    >Writing 3d software renderer running on a gen 2 I7
    >Everyone on stack overflow keeps telling everyone that unrolling loops will make no difference for performance because muh compiler will optimize it
    >Unroll everything I can in my math library
    >20 fps gain (at the time a 40% performance boost) for free
    Why are so many devs confidently wrong?

    • 9 months ago
      Anonymous

      >Why are so many devs confidently wrong?
      People who know nothing have nothing to doubt.

    • 9 months ago
      Anonymous

      How do you test these kinds of performance boosts? Devs might not do proper testing because they bruteforce performance with the best hardware.

  14. 9 months ago
    Anonymous

    >Ganker automatons.
    Most of Ganker these days are brainless consumers and linux ricers.
    But to answer your question, Carmack took this algorithm from some book or research paper.

    • 9 months ago
      Anonymous

      carmack wasn't even behind this, it was some other dev

  15. 9 months ago
    Anonymous

    that optimization is slower on modern hardware than doing it the regular way

    • 9 months ago
      Anonymous

      It's not, just not as accurate

      • 9 months ago
        Anonymous

        It is
        Modern processors have an inverse square root instruction

      • 9 months ago
        Anonymous

        It is slower, it's part of the x86_64 instruction set now.
        Tons of optimization tricks used 20 years ago are counterproductive nowadays and should not be used; either because they're hardware implemented, or compilers are just able to optimize way beyond you ever could in the code itself.

    • 9 months ago
      Anonymous

      I'm glad hardware has improved marginally over that last 25 years.

      • 9 months ago
        Anonymous

        >marginally
        it's improved a ton

  16. 9 months ago
    Anonymous

    You understand that in this case, optimization means either faking something to fool the user's eyes or approximating a solution so that it's good enough for the looks, but if you dig deeper it becomes obvious that you took considerable shortcuts, right?

    People complain about upscaling, "fake frames" and now "fake rays", but you fail to understand that in 3D programming, optimization isn't the same as finding a better sorting algorithm or graph traversal method like you did in university; usually it's impossible to simplify the maths (especially in the case of ray tracing), so optimization is about faking part of the work.

    You're showing that famous quake fast inverse square root algorithm which was all about approximating a value for the sake of performance, rather than calculating a more accurate figure.

    • 9 months ago
      Anonymous

      Also, Karmack didn't come up with the algorithm himself, he took it from a maths book.

  17. 9 months ago
    Anonymous

    I don't like that everything has to be scalable to absurdly large numbers these days.
    i miss the days when all you needed for web programming was LAMP.

  18. 9 months ago
    Anonymous

    90% of game devs are morons who simply use ready libraries and just assemble someone else's code. Just look at how many morons on Ganker there are who seethe at the fact that some companies have leetcode like questions during interview process. It's only going to get worse, because large corporations are putting whamen into IT positions by grabbing them out of high school without any skills, and assigning them mentors. There are women exclusive workshops for example, where big companies grab talentless women from there. They take any whaman they can get because that's what Blackrock overlords want. then you get shitty unoptimized code because most of those women all care about is money. They lack passion and drive to self improve and strive to make something great. Anyone who doesn't code in their free time shouldn't be allowed near workplace.

    • 9 months ago
      Anonymous

      >Anyone who doesn't code in their free time shouldn't be allowed near workplace.
      Coding in your free time doesn't make you a competent dev, that's a common fallacy found on Ganker where NEETs genuinely believe they're worth anything because they coded a CLI sorting algorithm.

      Understanding the fundamentals of computers is far more important than maths for a dev.
      A dev not understanding what is a stack trace or how types are coded is far more problematic than a dev not understanding advanced calculus, because the latter will be very rarely, if ever, used.

  19. 9 months ago
    Anonymous

    Why do i get the feeling OP has never coded anything in his life.

  20. 9 months ago
    Anonymous

    nah, it's because even competent programmers just finish their tickets and go home and there's no reason for them to touch the profiler unless they're being paid to and the product guys literally dont care.

  21. 9 months ago
    Anonymous

    Knowing programming and math is one thing(two things intertwined) but Carmack admitted he didnt make that function and that it was made by some C systems engineer that was like grandmaster at assembly and knew intricacies of the pentium and older x86 cpus and pretty much everything of the lowest hardware level.
    homosexual wank at that but do not really understand the gravity of the situation. To rewrite (remake) standard C library function and make it that much much faster you gotta be like Uciha Madara of programming.

Your email address will not be published. Required fields are marked *