)]}'
{
  "commit": "4d955d20d27bcf3ae71df091ad17d95229a7eb56",
  "tree": "a79641f1ef7f49531f8b4efb84f04c0633a01881",
  "parents": [
    "31ece98da1b52769e24871066962990d28245f64"
  ],
  "author": {
    "name": "David Benjamin",
    "email": "davidben@google.com",
    "time": "Mon Feb 21 10:30:35 2022 -0500"
  },
  "committer": {
    "name": "Adam Langley",
    "email": "agl@google.com",
    "time": "Wed Feb 23 19:17:28 2022 +0000"
  },
  "message": "Check static CPU capabilities on x86.\n\nOn Arm, our CRYPTO_is_*_capable functions check the corresponding\npreprocessor symbol. This allows us to automatically drop dynamic checks\nand fallback code when some capability is always avilable.\n\nThis CL does the same on x86, as well as consolidates our\nOPENSSL_ia32cap_P checks in one place. Since this abstraction is\nincompatible with some optimizations we do around OPENSSL_ia32cap_get()\nin the FIPS module, I\u0027ve marked the symbol __attribute__((const)), which\nis enough to make GCC and Clang do the optimizations for us. (We already\ndo the same to DEFINE_BSS_GET.)\n\nMost x86 platforms support a much wider range of capabilities, so this\nis usually a no-op. But, notably, all x86_64 Mac hardware has SSSE3\navailable, so this allows us to statically drop an AES implementation.\n(On macOS with -Wl,-dead_strip, this seems to trim 35080 bytes from the\nbssl binary.) Configs like -march\u003dnative can also drop a bunch of code.\n\nUpdate-Note: This CL may break build environments that incorrectly mark\nsome instruction as statically available. This is unlikely to happen\nwith vector instructions like AVX, where the compiler could freely emit\nthem anyway. However, instructions like AES-NI might be set incorrectly.\n\nChange-Id: I44fd715c9887d3fda7cb4519c03bee4d4f2c7ea6\nReviewed-on: https://boringssl-review.googlesource.com/c/boringssl/+/51548\nReviewed-by: Adam Langley \u003cagl@google.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "9e773756333d817eef022f65d5e4014595807764",
      "old_mode": 33188,
      "old_path": "crypto/cipher_extra/e_aesgcmsiv.c",
      "new_id": "387eafff029f173c856132fd671fa92df24906a9",
      "new_mode": 33188,
      "new_path": "crypto/cipher_extra/e_aesgcmsiv.c"
    },
    {
      "type": "modify",
      "old_id": "0f5f566b5ef9df783440b6c7ef5431f8e196306c",
      "old_mode": 33188,
      "old_path": "crypto/cipher_extra/internal.h",
      "new_id": "4e8fa4697026adec278df4d6b72d6d738e730434",
      "new_mode": 33188,
      "new_path": "crypto/cipher_extra/internal.h"
    },
    {
      "type": "modify",
      "old_id": "9f7dd4729cb1e900a6f8ef7516631b0fe3bf724b",
      "old_mode": 33188,
      "old_path": "crypto/fipsmodule/aes/internal.h",
      "new_id": "0685bc41deec911cf1c852218ddad3721a402369",
      "new_mode": 33188,
      "new_path": "crypto/fipsmodule/aes/internal.h"
    },
    {
      "type": "modify",
      "old_id": "b8150f163ea9140044a080ef0b943b509842091c",
      "old_mode": 33188,
      "old_path": "crypto/fipsmodule/bn/rsaz_exp.h",
      "new_id": "104bb7a41c5f5569651ef031a4ce338b2f4060d8",
      "new_mode": 33188,
      "new_path": "crypto/fipsmodule/bn/rsaz_exp.h"
    },
    {
      "type": "modify",
      "old_id": "99deb369e8cabdb0ec1454f27eba11ea9ed75624",
      "old_mode": 33188,
      "old_path": "crypto/fipsmodule/ec/p256-x86_64.c",
      "new_id": "506b7d2cef06b0fd1af844b5ef1b57272d87bcb6",
      "new_mode": 33188,
      "new_path": "crypto/fipsmodule/ec/p256-x86_64.c"
    },
    {
      "type": "modify",
      "old_id": "a083f3d5cf03cd754b2abafd5e9bff8f0e19604b",
      "old_mode": 33188,
      "old_path": "crypto/fipsmodule/ec/p256-x86_64_test.cc",
      "new_id": "f6f070a3020356bed705b252829bd6d368064c06",
      "new_mode": 33188,
      "new_path": "crypto/fipsmodule/ec/p256-x86_64_test.cc"
    },
    {
      "type": "modify",
      "old_id": "28218b4e019fee1a62e441464dd4068988d398d3",
      "old_mode": 33188,
      "old_path": "crypto/fipsmodule/modes/gcm.c",
      "new_id": "5b909aa65389a1cae796d780bfdb248f8839ef9c",
      "new_mode": 33188,
      "new_path": "crypto/fipsmodule/modes/gcm.c"
    },
    {
      "type": "modify",
      "old_id": "539b764acc30fa6652b4f63af82bc9e10b83278f",
      "old_mode": 33188,
      "old_path": "crypto/fipsmodule/modes/gcm_test.cc",
      "new_id": "d66d8ae46015b2a0c2be702dbdfa26eb4b7534af",
      "new_mode": 33188,
      "new_path": "crypto/fipsmodule/modes/gcm_test.cc"
    },
    {
      "type": "modify",
      "old_id": "f022f9b8cf433cc1a078358c3c14286dbe50868f",
      "old_mode": 33188,
      "old_path": "crypto/fipsmodule/modes/internal.h",
      "new_id": "0164aace0f4617b0a9c62a2db1c745bfba1fef18",
      "new_mode": 33188,
      "new_path": "crypto/fipsmodule/modes/internal.h"
    },
    {
      "type": "modify",
      "old_id": "bbeef76cc7277698a0699f4f75fc77aa3a255f75",
      "old_mode": 33188,
      "old_path": "crypto/fipsmodule/rand/internal.h",
      "new_id": "eccf047f6124d4b5b37fb41273d68922e8d8b100",
      "new_mode": 33188,
      "new_path": "crypto/fipsmodule/rand/internal.h"
    },
    {
      "type": "modify",
      "old_id": "8e21068ec408fdada417257c7eab7873f248f996",
      "old_mode": 33188,
      "old_path": "crypto/hrss/hrss.c",
      "new_id": "388c9a9ad171c164ff4ae89ee3db9e6be79e389f",
      "new_mode": 33188,
      "new_path": "crypto/hrss/hrss.c"
    },
    {
      "type": "modify",
      "old_id": "0693c82ceb4b131829ef55f55c92d113b4de6f64",
      "old_mode": 33188,
      "old_path": "crypto/hrss/hrss_test.cc",
      "new_id": "bab968cf31e59d4e5eb27257b6a09aac5be8ea5a",
      "new_mode": 33188,
      "new_path": "crypto/hrss/hrss_test.cc"
    },
    {
      "type": "modify",
      "old_id": "dae9e9639927dba10cab8d072dcef4123d6e6d7d",
      "old_mode": 33188,
      "old_path": "crypto/impl_dispatch_test.cc",
      "new_id": "631e78f0dca03f2559bee552f43bdccdad0d81a4",
      "new_mode": 33188,
      "new_path": "crypto/impl_dispatch_test.cc"
    },
    {
      "type": "modify",
      "old_id": "a85a60da471d7e63f1f6b39d3d1644bc8a0e8533",
      "old_mode": 33188,
      "old_path": "crypto/internal.h",
      "new_id": "032660a43051adb4bce6b6201642fe1a6b761980",
      "new_mode": 33188,
      "new_path": "crypto/internal.h"
    }
  ]
}
