Announcement

Collapse
No announcement yet.

interesting bug-finding method

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • interesting bug-finding method

    I'm not sure how many of you use Linux, so I don't know how many have ever heard of WINE, but I thought this was interesting.

    Apparently the windows API filter was able to run Planetside 2 until the 32-bit client was shelved. The reason for the 64-bit not working is actually PS2's fault, not the emulator.

    https://bugs.winehq.org/show_bug.cgi?id=27680

    It appears somewhere in their toolchain,the stack pointers are getting misaligned. Windows apparently (most of the time) does not have MMX/SSE instructions in the system calls, however I would guess that's purely coincidental, and probably not universal. Misaligned stack pointers are a violation of the Windows 64-bit ABI, so I'd guess they have no intention of safeguarding such sloppy programs.

    That makes me wonder whether or not this one is the cause of some systems having stability issue with the game that seem unrelated to memory leaks (For instance I had a BSOD with memory dump last night), and how many other gems are hiding in that code.

    Dear DayBreak /people who take my monies: 16-byte aligned pointers are not that hard. Please fix.

    #BlameGhostshooter101
    MacKahan -- Mac-Kay-an In case you were curious. ;-)

    sigpic

  • #2
    Re: interesting bug-finding method

    What, really? Their STACK POINTERS are off? What kind of twisted abuse are they applying to their codebase that this could possibly be a problem!? The last time I had to THINK about stack pointers was when I was writing 68K assembly for a university course (which was, coincidentally, a really fun course).

    If they're using an industry standard compiler like Visual Studio, it's almost certainly not the cause of an issue like this unless they're hand coding assembly (which in this day and age is ludicrously counter productive, compiler almost always does it better). I wonder if they've got extra steps in their toolchain that apply to their executable... maybe anti-cheat/obfuscation/packing tools of some kind?



    Comment


    • #3
      Re: interesting bug-finding method

      Yeah, so the pointers point to the right place, but aren't stored in memory on the appropriate boundaries. When I was writing an OS in ASM (don't ask), I ran into that issue with a lot of structures for 32-bit mode. I'll say this, the CPU is not very forgiving. So Windows must be incredibly resilient to not simply faceplant when it hits those. I'm a low-level coder, I write firmware and C runtimes for platforms (For instance, I had VC.net compiling for a flat memory mode OS of my own design).

      I'd guess obfuscation. In any case, ugly business, ugly code.
      MacKahan -- Mac-Kay-an In case you were curious. ;-)

      sigpic

      Comment


      • #4
        Re: interesting bug-finding method

        > 2013 + 2
        > age of NSA / Windows
        > NOT coding your own OS
        "The power of accurate observation is commonly called cynicism by those who have not got it." - George Bernard Shaw



        Comment


        • #5
          Re: interesting bug-finding method

          Been a long time since I've had to think about data alignment. Still kind of mystified as to how the stack pointers would be misaligned; data I could understand, but the stack pointer is usually so far away from what your typical programmer will ever touch that it's strange to think of it being tampered with or improperly set up.



          Comment


          • #6
            Re: interesting bug-finding method

            i had linux a could of years ago. Wine was a pain in the butt lol

            Comment


            • #7
              Re: interesting bug-finding method

              [MENTION=16189]starstriker1[/MENTION]: yeah, it could be argued that separation is the reason for silly mistakes like that. Code doesn't run on those cute little flow charts and thought bubbles modern programmers see. At some point it has to hit the hardware, and when it does, some old crusty guy has to come out of the shadows, yell at the kids for doing something dumb, and straighten it out by hand. I am not joking when I blame the ridiculous and epic failure of desktop Linux on the silly idea that computer programming is a "Science". Like anything else, Science without engineering is impotent.
              [MENTION=56436]ghostshooter101[/MENTION]: Running Linux takes skillz. And I was using Wine back when the project first went public, it's almost point and click.

              #BlameGhostshooter101
              MacKahan -- Mac-Kay-an In case you were curious. ;-)

              sigpic

              Comment

              Connect

              Collapse

              TeamSpeak 3 Server

              Collapse

              Advertisement

              Collapse

              Twitter Feed

              Collapse

              Working...
              X