)]}'
{
  "commit": "266614a36dbd5328a9079ea6bbef9026c7bbe3d7",
  "tree": "6baeee402d87b7d34854c92351af305691c4bf0c",
  "parents": [
    "a8da847d13385bb1c4322ae3c456e4896976c93b"
  ],
  "author": {
    "name": "Antonio Maiorano",
    "email": "amaiorano@google.com",
    "time": "Fri Feb 05 10:58:21 2021 -0500"
  },
  "committer": {
    "name": "swiftshader-scoped@luci-project-accounts.iam.gserviceaccount.com",
    "email": "swiftshader-scoped@luci-project-accounts.iam.gserviceaccount.com",
    "time": "Fri Feb 05 19:05:03 2021 +0000"
  },
  "message": "Fix crash during llvm_shutdown due to init order fiasco\n\nUse the constexpr constructor for _MSC_VER \u003e\u003d 1925, otherwise\nManagedStatic will have a dynamic initializer, which depending on init\norder, results in the Ptr field being overwritten with 0. This\neventually leads to multiple instances of the same ManagedStatic\ninstance in the StaticList, and asserts when double destroying during\nllvm_shutdown.\n\nI reported this bug [here](https://bugs.llvm.org/show_bug.cgi?id\u003d49027),\nand learned that this bug had already been fixed in upstream LLVM.\n\nNote that llvm_subzero already has a similar change, though for _MSC_VER\n\u003e\u003d 1920. According to the LLVM comment, the VC++ compiler up until 1925\nmay still emit a dynamic initializer for a constexpr constructor, but I\nsuppose we never ran into that for Subzero, so I\u0027ll leave this as is.\n\nBug: b/175782868\nChange-Id: Ice3944f67e496aa94f1a7ed7502b49e763d702b4\nReviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/52508\nKokoro-Result: kokoro \u003cnoreply+kokoro@google.com\u003e\nReviewed-by: Alexis Hétu \u003csugoi@google.com\u003e\nTested-by: Antonio Maiorano \u003camaiorano@google.com\u003e\nCommit-Queue: Antonio Maiorano \u003camaiorano@google.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "bbd0d04ed0404562625d48db835a17412a29f60c",
      "old_mode": 33188,
      "old_path": "third_party/llvm-10.0/llvm/include/llvm/Support/ManagedStatic.h",
      "new_id": "f2b41422f131559a0292dcda0ce2fe37f4685997",
      "new_mode": 33188,
      "new_path": "third_party/llvm-10.0/llvm/include/llvm/Support/ManagedStatic.h"
    }
  ]
}
