)]}'
{
  "commit": "40d12c142d967f162713c096e0584e56a675f360",
  "tree": "f44a742d55f90ebb7efa1f90721ac90753c2181c",
  "parents": [
    "0c1835052ac6a800fbb6e892f78921863d7b64fc"
  ],
  "author": {
    "name": "Andy Ross",
    "email": "andrew.j.ross@intel.com",
    "time": "Mon Sep 27 08:22:43 2021 -0700"
  },
  "committer": {
    "name": "Anas Nashif",
    "email": "anas.nashif@intel.com",
    "time": "Mon Nov 08 21:32:20 2021 -0500"
  },
  "message": "kernel/sched: Add \"thread_usage\" API for thread runtime cycle monitoring\n\nThis is an alternate backend that does what THREAD_RUNTIME_STATS is\ndoing currently, but with a few advantages:\n\n* Correctly synchronized: you can\u0027t race against a running thread\n  (potentially on another CPU!) while querying its usage.\n\n* Realtime results: you get the right answer always, up to timer\n  precision, even if a thread has been running for a while\n  uninterrupted and hasn\u0027t updated its total.\n\n* Portable, no need for per-architecture code at all for the simple\n  case. (It leverages the USE_SWITCH layer to do this, so won\u0027t work\n  on older architectures)\n\n* Faster/smaller: minimizes use of 64 bit math; lower overhead in\n  thread struct (keeps the scratch \"started\" time in the CPU struct\n  instead).  One 64 bit counter per thread and a 32 bit scratch\n  register in the CPU struct.\n\n* Standalone.  It\u0027s a core (but optional) scheduler feature, no\n  dependence on para-kernel configuration like the tracing\n  infrastructure.\n\n* More precise: allows architectures to optionally call a trivial\n  zero-argument/no-result cdecl function out of interrupt entry to\n  avoid accounting for ISR runtime in thread totals.  No configuration\n  needed here, if it\u0027s called then you get proper ISR accounting, and\n  if not you don\u0027t.\n\nFor right now, pending unification, it\u0027s added side-by-side with the\nolder API and left as a z_*() internal symbol.\n\nSigned-off-by: Andy Ross \u003candrew.j.ross@intel.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "ee6dc8f50ecd76c9a6cc7c4cab042eb9b69aeee1",
      "old_mode": 33188,
      "old_path": "include/kernel/thread.h",
      "new_id": "ae0930b70e0fdd6ba3180898bf15cf9f50a267a0",
      "new_mode": 33188,
      "new_path": "include/kernel/thread.h"
    },
    {
      "type": "modify",
      "old_id": "5199f82b92bb8e3a22ee44e5dafc3582315646c1",
      "old_mode": 33188,
      "old_path": "include/kernel_structs.h",
      "new_id": "05d2ec309d5469d0fb7ccec3c7f57830a6bfd043",
      "new_mode": 33188,
      "new_path": "include/kernel_structs.h"
    },
    {
      "type": "modify",
      "old_id": "26a078e873e7e3154f5e3cc095f1f83045fb308a",
      "old_mode": 33188,
      "old_path": "kernel/Kconfig",
      "new_id": "7c09d4392f3a5453ea6e237e56a9cd02416dd75b",
      "new_mode": 33188,
      "new_path": "kernel/Kconfig"
    },
    {
      "type": "modify",
      "old_id": "7d39825c52ab9e4421ff3dae1ddd98f17f26cf13",
      "old_mode": 33188,
      "old_path": "kernel/include/ksched.h",
      "new_id": "f29e6c416694076df68b16535c3d5b2ebc82f57a",
      "new_mode": 33188,
      "new_path": "kernel/include/ksched.h"
    },
    {
      "type": "modify",
      "old_id": "917315d5899fd70947d3d5229aa41f340a262a9c",
      "old_mode": 33188,
      "old_path": "kernel/include/kswap.h",
      "new_id": "f43f1941177b31cf064eead80ff165103a655b43",
      "new_mode": 33188,
      "new_path": "kernel/include/kswap.h"
    },
    {
      "type": "modify",
      "old_id": "5eeb192268d50f792dd9d30ae5bb37075d4368f3",
      "old_mode": 33188,
      "old_path": "kernel/sched.c",
      "new_id": "32fb2341ac7488687581d6a0df0b67bb4d4ee90b",
      "new_mode": 33188,
      "new_path": "kernel/sched.c"
    }
  ]
}
