)]}'
{
  "commit": "5b32e81407cd044e76c995eb99343dca954a17b8",
  "tree": "09a529f8b7308b48e3f5998cdc3ce5517108e5a2",
  "parents": [
    "5e988c40553f6afe38971d4a32f5c4b7b48ac972"
  ],
  "author": {
    "name": "David Benjamin",
    "email": "davidben@google.com",
    "time": "Tue May 02 19:17:24 2023 -0400"
  },
  "committer": {
    "name": "Boringssl LUCI CQ",
    "email": "boringssl-scoped@luci-project-accounts.iam.gserviceaccount.com",
    "time": "Fri May 05 04:00:51 2023 +0000"
  },
  "message": "Remove unions in GCM implementation\n\nThis was a bit of a mess. There are three assembly functions to juggle\nhere. Their current type signatures are:\n\n void gcm_init_v8(u128 Htable[16], const uint64_t H[2]);\n void gcm_gmult_v8(uint64_t Xi[2], const u128 Htable[16]);\n void gcm_ghash_v8(uint64_t Xi[2], const u128 Htable[16], const uint8_t *inp,\n                   size_t len);\n\nExcept for gcm_nohw.c, this is all assembly, so they don\u0027t follow the C\nabstract machine\u0027s theory of typed memory. That means types are mostly\narbitrary and we have room to rearrange them. They do carry an implicit\nalignment requirement, but none of these assembly files care about\nthis[*].\n\nValues passed to gcm_gmult and gcm_ghash get XORed byte-by-byte in\nplaces, which is inconvenient to do as uint64_t. They also get passed to\nAES functions, which want bytes. Thus I think uint8_t[16] is the most\nnatural and convenient type to use.\n\nH in gcm_init is interesting. gcm_init already doesn\u0027t take a GHASH key\nin the natural byte representation. The two 8-byte halves are\nbyte-swapped, but the halves are not swapped, so it\u0027s not quite a byte\nreversal. I opted to leave that as uint64_t[2], mostly to capture that\nsomething odd is happening here.\n\n[*] We only have GHASH assembly for x86, x86_64, armv7, and aarch64. We\nused to have armv4 GHASH assembly, but that\u0027s been removed from\ngcm_nohw.c. Thus we can assume none of these files care about alignment\nfor plain scalar loads. Alignment does matter for vmovdqa vs vmovdqu,\nbut that requires 16-byte alignment and uint64_t only implies 4- or\n8-byte alignment on these architectures.\n\nBug: 574\nChange-Id: If7dba9b41ff62204f4cf8fcd54eb4a4c54214c6e\nReviewed-on: https://boringssl-review.googlesource.com/c/boringssl/+/59528\nCommit-Queue: David Benjamin \u003cdavidben@google.com\u003e\nReviewed-by: Adam Langley \u003cagl@google.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "df8f9ce83dfa71cba29bfee4cf51c578dda13753",
      "old_mode": 33188,
      "old_path": "crypto/fipsmodule/modes/cbc.c",
      "new_id": "511a5de414e74e0399ca36b4758476af169525f1",
      "new_mode": 33188,
      "new_path": "crypto/fipsmodule/modes/cbc.c"
    },
    {
      "type": "modify",
      "old_id": "1688f823e0de780c2e6426d1609f6a780f29422b",
      "old_mode": 33188,
      "old_path": "crypto/fipsmodule/modes/ctr.c",
      "new_id": "8c333bb1796c4543101b4d56363a5b84b44852c2",
      "new_mode": 33188,
      "new_path": "crypto/fipsmodule/modes/ctr.c"
    },
    {
      "type": "modify",
      "old_id": "40ec0c8204ef9dd29dea0c3f32a306ee83bcf81f",
      "old_mode": 33188,
      "old_path": "crypto/fipsmodule/modes/gcm.c",
      "new_id": "8413951ec11a560ce1b0fd3079cf22fae4169816",
      "new_mode": 33188,
      "new_path": "crypto/fipsmodule/modes/gcm.c"
    },
    {
      "type": "modify",
      "old_id": "92d54413fd86d625d156ee635ee49db6a076629f",
      "old_mode": 33188,
      "old_path": "crypto/fipsmodule/modes/gcm_nohw.c",
      "new_id": "4a6302824df95956d23e83402df34d44385052da",
      "new_mode": 33188,
      "new_path": "crypto/fipsmodule/modes/gcm_nohw.c"
    },
    {
      "type": "modify",
      "old_id": "cfdccb27edd261df1ccb6e0e2dc6d8138ad6bd0f",
      "old_mode": 33188,
      "old_path": "crypto/fipsmodule/modes/gcm_test.cc",
      "new_id": "b4f9b90d6bbb2c7d51439744105fda86b53e01a2",
      "new_mode": 33188,
      "new_path": "crypto/fipsmodule/modes/gcm_test.cc"
    },
    {
      "type": "modify",
      "old_id": "560b268339fa3b20b5a0e98543b6d622e5ab2b20",
      "old_mode": 33188,
      "old_path": "crypto/fipsmodule/modes/internal.h",
      "new_id": "3b84015dd80d73d379c0b38e2d4a580d960aeac4",
      "new_mode": 33188,
      "new_path": "crypto/fipsmodule/modes/internal.h"
    },
    {
      "type": "modify",
      "old_id": "5effba667e8d076d6667f3a565ab6ddcb98b6a61",
      "old_mode": 33188,
      "old_path": "crypto/fipsmodule/modes/ofb.c",
      "new_id": "9260f2d491b5d49cb52d2e8ad75f23956f3811fb",
      "new_mode": 33188,
      "new_path": "crypto/fipsmodule/modes/ofb.c"
    }
  ]
}
