)]}'
{
  "commit": "2f97d82192974e1129d6b2352dea17ad7bf27712",
  "tree": "29a8b0be5c50433907bb2d0eea8b94aa4929dfe5",
  "parents": [
    "c1a5f16129afbfa057988d3ded31456aa68feb6d"
  ],
  "author": {
    "name": "RJ Ascani",
    "email": "rjascani@google.com",
    "time": "Thu Nov 30 14:21:00 2023 -0800"
  },
  "committer": {
    "name": "GitHub",
    "email": "noreply@github.com",
    "time": "Thu Nov 30 22:21:00 2023 +0000"
  },
  "message": "Initialize ArithmeticParams \u0026 OpDataReduce (#2337)\n\nThere are several structs that are allocated as either part of the arena or on the stack that do not get entirely initialized. It is typical that individual operations will just fill in the fields of a struct that they need. This can lead to difficult to find bugs where a field is used despite never being initialized. This PR resolves two such instances found in issue #2336.\n\nThe first is in the reference ADD kernel, where we use ArithmeticParams without initializing it. This is resolved by zero initializing the struct when it is declared.\n\nThe second is the OpDataReduce object that is created in the Persistent Arena for Reduce kernels. This is resolved by performing placement new on the buffer that is returned from AllocatePersistentBuffer. This is a pattern we use elsewhere with allocations, and likely one we should re-use in all Init functions.\n\nBUG\u003d#2336",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "b27206c67743c1bfafd3975805d8811d49387dfa",
      "old_mode": 33188,
      "old_path": "tensorflow/lite/micro/kernels/add.cc",
      "new_id": "fde047a4bdd4ac3be2eafb7440a073a58e4b0eb9",
      "new_mode": 33188,
      "new_path": "tensorflow/lite/micro/kernels/add.cc"
    },
    {
      "type": "modify",
      "old_id": "ab24a82ddb568f7fea9ce5a3c34eec7bd324b404",
      "old_mode": 33188,
      "old_path": "tensorflow/lite/micro/kernels/reduce.cc",
      "new_id": "a689d3b934b1f3d2c5ee1c1f799d846acb28ab46",
      "new_mode": 33188,
      "new_path": "tensorflow/lite/micro/kernels/reduce.cc"
    },
    {
      "type": "modify",
      "old_id": "0dab49c2de291874a6511d620eee9a745db626a5",
      "old_mode": 33188,
      "old_path": "tensorflow/lite/micro/kernels/reduce_common.cc",
      "new_id": "2c1a92a5062bc679739686af7b17c8ce106def05",
      "new_mode": 33188,
      "new_path": "tensorflow/lite/micro/kernels/reduce_common.cc"
    }
  ]
}
