1. 80
  1.  

  2. 28

    Sometimes I like to think that I know how computers work, and then I read something written by someone who actually does and I’m humbled most completely.

    1. 12

      A lot of this complexity seems down to the way Windows works, though. As a Linux user, the amount of somewhat confusing/crufty stuff going on in a typical Windows install boggles the mind; it’s almost as bad as Emacs.

      1. 11

        I guess to me it doesn’t feel like there’s much Windows specific complexity here, just a generally complex issue; a bug in v8’s sandboxed runtime and how it interacts with low-level OS-provided virtual memory protection and specific lock contention behavior, which only expressed itself by happenstance for the OP.

        Some of this stuff just feels like irreducible complexity, though my lack of familiarity with Windowsisms (function naming style, non-fair locks, etc.) probably doesn’t help there.

        1. 5

          How does CFG work with chrome on linux?

          1. 2

            Do you mean CFI?

            CFG is MS’s Control Flow Guard, it’s a combination of compile-time instrumentation from MSVC and runtime integration with the OS. CFI on Linux (via clang/LLVM), in contrast, is entirely compile time AFAIK, with basically no runtime support.

            See:

            for more details on the differences.

            1. 2

              Yes and no. :) The linux CFI implementation doesn’t include the jit protection feature in CFG that’s implicated in the bug, so I’m not sure it’s fair to characterize this as “cruft”.

              1. 2

                The CFI implementation in llvm isn’t a “linux CFI implementation.” :)

                As OpenBSD moves towards llvm on all architectures, it can take advantage of CFI, just as HardenedBSD already does. :)

              2. 1

                llvm’s implementation of CFI does have the beginnings of a runtime support library (libclang_rt.cfi). HardenedBSD is working on integrating Cross-DSO CFI from llvm, which is what uses the support library.

            2. 4

              Linux just hasit’s own weirdnesses in other places.

              That said, memory management seems to be a source of strange behaviour regardless of OS.

          2. 4

            I found it a great read as well and his blog has more. Thank you for submitting this.

            1. 2

              Here’s a funny thought in terms of performance: don’t get attached to apps. I recently compared mail apps on mac. I’ve ran Thunderbird, Apple Mail and Outlook, and surprisingly the first two were really inadequate with large inboxes (gigabytes, 50K+ messages). Outlook crunches them without a problem. Oh and Thunderbird just hangs up when you try to use unified inbox with large accounts - you can’t even start it after the crash, you need to remove the data files in the Finder. (The same happens on Linux…) PS. Having a gmail tab opened for 8 days is thrilling. Also, it may be a good idea to remove yourself from Google services ;)

              1. 5

                The author works at Google.

                1. 2

                  Then he would be a pioneer.

              2. 2

                PSA: The gmail HTML interface still exists and works fine. Even in your favorite text browser like links+ (links2 in some package managers).

                1. 1

                  Layer after layer of hacks.