)]}'
{
  "commit": "b70e945e81bd3f2ef6af9448bffc15b90199ba8c",
  "tree": "9aa8e1e6d25d0a96aa3444bbef2830b715854690",
  "parents": [
    "f9e54fc9919e83c7105a4f2c133bfc80eaa136d6"
  ],
  "author": {
    "name": "Thomas Haller",
    "email": "thaller@redhat.com",
    "time": "Thu Jan 04 19:44:53 2024 +0100"
  },
  "committer": {
    "name": "Thomas Haller",
    "email": "thaller@redhat.com",
    "time": "Thu Jan 04 19:56:03 2024 +0100"
  },
  "message": "gbitlock: bump CONTENTION_CLASSES from 11 to 97\n\nCONTENTION_CLASSES seems low. Bump it.\n\nUnlock essentially does:\n\n  g_atomic_int_and (address_nonvolatile, ~mask);\n  guint class \u003d ((gsize) address_nonvolatile) % G_N_ELEMENTS (g_bit_lock_contended);\n  if (g_atomic_int_get (\u0026g_bit_lock_contended[class]))\n    g_futex_wake (address_nonvolatile);\n\nthat means, if \"g_bit_lock_contended\" indicates a lock, we wakes up a\nfutex. Which can be expensive, if the wake up was unnecessary. By\nadding more classes, the idea is to hit false positives with lower\nprobability.\n\nThe cost is that we now allocate extra 86 gint (344 bytes). Which seems\nvery acceptable.\n\nThis is the simplest change which might make an impact in reducing\nunnecessary g_futex_wake() calls. GObject\u0027s \"qdata\" and\nobject_bit_lock() use bit locks at prominent places.\n\nThis is not backed by bench marks. Just by reasoning, that 11 seems a\nvery low number. 11 was used since the beginning ([1]), but I don\u0027t see\nany comment/justification why it would be a good number. It probably is\nnot a good number (anymore).\n\n[1] https://bugzilla.gnome.org/show_bug.cgi?id\u003d548967#c1\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "eeeaabc8ffdde626838b83a340cdad2544996f04",
      "old_mode": 33188,
      "old_path": "glib/gbitlock.c",
      "new_id": "3465971b215868680d50eb39c6ae74256d749e5e",
      "new_mode": 33188,
      "new_path": "glib/gbitlock.c"
    }
  ]
}
