Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move security credentials, connectors, and auth context to C++ #17291

Merged
merged 1 commit into from
Dec 13, 2018

Conversation

soheilhy
Copy link
Contributor

@soheilhy soheilhy commented Nov 26, 2018

This is to use grpc_core::RefCount to improve performnace.
This commit also replaces explicit C vtables, with C++ vtable
with its own compile time assertions and performance benefits.

Note that these classes cannot be made RefCountedPtr because
the type and its related functions are all leaked as naked pointers to
the C API.


This change is Reviewable

@soheilhy soheilhy added the release notes: no Indicates if PR should not be in release notes label Nov 26, 2018
@grpc-testing
Copy link

****************************************************************

libgrpc.so

     VM SIZE                                                                                            FILE SIZE
 ++++++++++++++ GROWING                                                                              ++++++++++++++
  +2.4% +17.6Ki [None]                                                                                +340Ki  +3.3%
      +2.4% +16.6Ki [Unmapped]                                                                            +339Ki  +3.3%
      [NEW]    +552 [Other]                                                                                 +552  [NEW]
      [NEW]     +72 vtable for grpc_channel_security_connector                                               +72  [NEW]
      [NEW]     +72 vtable for grpc_httpcli_ssl_channel_security_connector                                   +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_ssl_channel_security_connector                    +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_alts_channel_security_connector                   +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_fake_channel_security_connector                   +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_local_channel_security_connector                  +72  [NEW]
      [NEW]     +56 vtable for grpc_server_security_connector                                                +56  [NEW]
      [NEW]     +56 vtable for grpc_google_refresh_token_credentials                                         +56  [NEW]
      [NEW]     +56 vtable for grpc_oauth2_token_fetcher_credentials                                         +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_ssl_server_security_connector                     +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_alts_server_security_connector                    +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_fake_server_security_connector                    +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_local_server_security_connector                   +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials          +56  [NEW]
      [NEW]     +48 vtable for grpc_ssl_credentials                                                          +48  [NEW]
      [NEW]     +48 vtable for grpc_alts_credentials                                                         +48  [NEW]
      [NEW]     +48 vtable for grpc_local_credentials                                                        +48  [NEW]
      [NEW]     +48 vtable for grpc_plugin_credentials                                                       +48  [NEW]
      [NEW]     +48 vtable for grpc_google_iam_credentials                                                   +48  [NEW]
   +15%    +513 src/core/lib/security/security_connector/ssl/ssl_security_connector.cc                  +513   +15%
      [NEW]    +668 (anonymous namespace)::grpc_ssl_server_security_connector::add_handshakers              +668  [NEW]
      [NEW]    +615 (anonymous namespace)::grpc_ssl_channel_security_connector::check_peer                  +615  [NEW]
      +104%    +497 grpc_ssl_server_security_connector_create                                               +497  +104%
      [NEW]    +213 (anonymous namespace)::grpc_ssl_channel_security_connector::check_call_host             +213  [NEW]
      [NEW]    +171 (anonymous namespace)::grpc_ssl_channel_security_connector::add_handshakers             +171  [NEW]
       +23%    +141 grpc_ssl_channel_security_connector_create                                              +141   +23%
      [NEW]    +111 (anonymous namespace)::grpc_ssl_channel_security_connector::cmp(grpc_security_connec    +111  [NEW]
      [NEW]     +75 (anonymous namespace)::grpc_ssl_server_security_connector::check_peer                    +75  [NEW]
      [NEW]     +68 (anonymous namespace)::grpc_ssl_channel_security_connector::~grpc_ssl_channel_securi     +68  [NEW]
      [NEW]     +60 (anonymous namespace)::grpc_ssl_channel_security_connector::~grpc_ssl_channel_securi     +60  [NEW]
      [NEW]     +40 (anonymous namespace)::grpc_ssl_server_security_connector::~grpc_ssl_server_security     +40  [NEW]
      [NEW]     +32 (anonymous namespace)::grpc_ssl_server_security_connector::~grpc_ssl_server_security     +32  [NEW]
      [NEW]     +24 (anonymous namespace)::grpc_ssl_channel_security_connector::cancel_check_call_host       +24  [NEW]
      [NEW]      +5 (anonymous namespace)::grpc_ssl_server_security_connector::cmp(grpc_security_connect      +5  [NEW]
   +10%    +338 src/core/lib/security/context/security_context.cc                                       +338   +10%
      [NEW]    +114 grpc_auth_context::~grpc_auth_context                                                   +114  [NEW]
      [NEW]    +112 grpc_auth_context::add_property                                                         +112  [NEW]
      [NEW]     +82 grpc_auth_context::add_cstring_property                                                  +82  [NEW]
      +146%     +73 grpc_client_security_context::~grpc_client_security_context                              +73  +146%
       +96%     +67 grpc_auth_context_create                                                                 +67   +96%
      [NEW]     +62 grpc_auth_context::ensure_capacity                                                       +62  [NEW]
      [NEW]     +59 grpc_client_security_context_create                                                      +59  [NEW]
       +95%     +40 grpc_server_security_context::~grpc_server_security_context                              +40   +95%
      +7.3%     +36 grpc_call_set_credentials                                                                +36  +7.3%
      +580%     +29 auth_context_pointer_arg_destroy                                                         +29  +580%
       +48%     +29 grpc_auth_context_release                                                                +29   +48%
      +220%     +11 auth_context_pointer_arg_copy                                                            +11  +220%
      +8.5%     +11 grpc_call_auth_context                                                                   +11  +8.5%
   +12%    +320 src/core/lib/security/credentials/google_default/google_default_credentials.cc          +320   +12%
      [NEW]    +216 grpc_google_default_channel_credentials::create_security_connector                      +216  [NEW]
       +12%    +119 grpc_google_default_credentials_create                                                  +119   +12%
      [NEW]    +115 grpc_google_default_channel_credentials::~grpc_google_default_channel_credentials       +115  [NEW]
      [NEW]     +64 grpc_google_default_channel_credentials::grpc_google_default_channel_credentials         +64  [NEW]
       +56%     +27 [Unmapped]                                                                               +27   +56%
      [NEW]     +18 grpc_google_default_channel_credentials::~grpc_google_default_channel_credentials        +18  [NEW]
   +76%    +314 src/core/lib/security/credentials/alts/alts_credentials.cc                              +314   +76%
      [NEW]    +135 grpc_alts_server_credentials::grpc_alts_server_credentials                              +135  [NEW]
      [NEW]    +111 grpc_alts_credentials::grpc_alts_credentials                                            +111  [NEW]
      [NEW]     +82 grpc_alts_server_credentials::~grpc_alts_server_credentials                              +82  [NEW]
       +71%     +45 [Unmapped]                                                                               +45   +71%
      [NEW]     +37 grpc_alts_credentials::~grpc_alts_credentials                                            +37  [NEW]
      [NEW]     +18 grpc_alts_credentials::~grpc_alts_credentials                                            +18  [NEW]
      [NEW]     +18 grpc_alts_server_credentials::~grpc_alts_server_credentials                              +18  [NEW]
      [NEW]     +10 grpc_channel_credentials::duplicate_without_call_credentials                             +10  [NEW]
      [NEW]      +8 grpc_alts_credentials::create_security_connector                                          +8  [NEW]
      [NEW]      +5 grpc_alts_server_credentials::create_security_connector                                   +5  [NEW]
  +6.3%    +311 src/core/lib/security/credentials/oauth2/oauth2_credentials.cc                          +311  +6.3%
      [NEW]    +528 grpc_oauth2_token_fetcher_credentials::on_http_response                                 +528  [NEW]
      [NEW]    +418 grpc_google_refresh_token_credentials::fetch_oauth2                                     +418  [NEW]
      [NEW]    +387 grpc_oauth2_token_fetcher_credentials::get_request_metadata                             +387  [NEW]
      [NEW]    +367 grpc_access_token_credentials::grpc_access_token_credentials                            +367  [NEW]
      [NEW]    +309 (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials::fetch_oauth2      +309  [NEW]
      [NEW]    +225 grpc_oauth2_token_fetcher_credentials::cancel_get_request_metadata                      +225  [NEW]
      [NEW]    +112 grpc_oauth2_token_fetcher_credentials::grpc_oauth2_token_fetcher_credentials            +112  [NEW]
       +40%     +69 [Unmapped]                                                                               +69   +40%
      [NEW]     +63 grpc_oauth2_token_fetcher_credentials::~grpc_oauth2_token_fetcher_credentials            +63  [NEW]
      [NEW]     +51 grpc_google_refresh_token_credentials::grpc_google_refresh_token_credentials             +51  [NEW]
      [NEW]     +40 grpc_google_refresh_token_credentials::~grpc_google_refresh_token_credentials            +40  [NEW]
      [NEW]     +28 (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials::~grpc_compute_     +28  [NEW]
      [NEW]     +26 grpc_access_token_credentials::get_request_metadata                                      +26  [NEW]
      [NEW]     +24 grpc_access_token_credentials::cancel_get_request_metadata                               +24  [NEW]
      [NEW]     +23 grpc_access_token_credentials::~grpc_access_token_credentials                            +23  [NEW]
      [NEW]     +18 grpc_access_token_credentials::~grpc_access_token_credentials                            +18  [NEW]
      [NEW]     +18 grpc_google_refresh_token_credentials::~grpc_google_refresh_token_credentials            +18  [NEW]
      [NEW]     +18 grpc_oauth2_token_fetcher_credentials::~grpc_oauth2_token_fetcher_credentials            +18  [NEW]
      +9.9%     +16 grpc_google_compute_engine_credentials_create                                            +16  +9.9%
      [NEW]     +15 (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials::~grpc_compute_     +15  [NEW]
      +6.6%      +8 [Other]                                                                                   +8  +6.6%
   +11%    +288 src/core/lib/security/credentials/ssl/ssl_credentials.cc                                +288   +11%
      [NEW]    +341 grpc_ssl_credentials::create_security_connector                                         +341  [NEW]
      [NEW]    +299 grpc_ssl_credentials::build_config                                                      +299  [NEW]
      [NEW]    +116 grpc_ssl_server_credentials::grpc_ssl_server_credentials                                +116  [NEW]
      [NEW]     +82 grpc_ssl_server_credentials::~grpc_ssl_server_credentials                                +82  [NEW]
      [NEW]     +66 grpc_ssl_credentials::~grpc_ssl_credentials                                              +66  [NEW]
      [NEW]     +60 grpc_ssl_server_credentials::build_config                                                +60  [NEW]
       +36%     +54 [Unmapped]                                                                               +54   +36%
      [NEW]     +38 grpc_ssl_credentials::grpc_ssl_credentials                                               +38  [NEW]
      [NEW]     +18 grpc_ssl_credentials::~grpc_ssl_credentials                                              +18  [NEW]
      [NEW]     +18 grpc_ssl_server_credentials::~grpc_ssl_server_credentials                                +18  [NEW]
      +2.3%      +8 grpc_ssl_server_certificate_config_create                                                 +8  +2.3%
      [NEW]      +5 grpc_ssl_server_credentials::create_security_connector                                    +5  [NEW]
  +8.3%    +282 src/core/lib/security/transport/client_auth_filter.cc                                   +282  +8.3%
      +250%     +70 destroy_channel_elem                                                                     +70  +250%
       +83%     +54 grpc_auth_metadata_context_reset                                                         +54   +83%
      +6.7%     +42 auth_start_transport_stream_op_batch                                                     +42  +6.7%
       +47%     +37 destroy_call_elem                                                                        +37   +47%
       +65%     +31 [Unmapped]                                                                               +31   +65%
      +2.0%     +16 on_host_checked                                                                          +16  +2.0%
       +22%     +16 cancel_get_request_metadata                                                              +16   +22%
      +1.7%      +8 grpc_auth_metadata_context_build                                                          +8  +1.7%
       +11%      +8 cancel_check_call_host                                                                    +8   +11%
   +13%    +272 src/core/lib/security/credentials/composite/composite_credentials.cc                    +272   +13%
      [NEW]    +285 grpc_composite_call_credentials::get_request_metadata                                   +285  [NEW]
      [NEW]    +234 grpc_composite_call_credentials::grpc_composite_call_credentials                        +234  [NEW]
      [NEW]    +226 grpc_composite_channel_credentials::create_security_connector                           +226  [NEW]
      [NEW]    +150 grpc_composite_call_credentials::cancel_get_request_metadata                            +150  [NEW]
      [NEW]    +110 grpc_composite_channel_credentials::~grpc_composite_channel_credentials                 +110  [NEW]
      [NEW]    +101 grpc_composite_call_credentials::~grpc_composite_call_credentials                       +101  [NEW]
       +43%     +37 [Unmapped]                                                                               +37   +43%
      [NEW]     +18 grpc_composite_call_credentials::~grpc_composite_call_credentials                        +18  [NEW]
      [NEW]     +18 grpc_composite_channel_credentials::~grpc_composite_channel_credentials                  +18  [NEW]
      [NEW]     +11 grpc_composite_channel_credentials::duplicate_without_call_credentials                   +11  [NEW]
      +0.5%      +1 composite_call_metadata_cb                                                                +1  +0.5%
   +22%    +271 src/core/lib/http/httpcli_security_connector.cc                                         +271   +22%
      [NEW]    +279 grpc_httpcli_ssl_channel_security_connector::check_peer                                 +279  [NEW]
       +33%    +192 ssl_handshake                                                                           +192   +33%
      [NEW]    +160 grpc_httpcli_ssl_channel_security_connector::add_handshakers                            +160  [NEW]
      [NEW]     +63 grpc_httpcli_ssl_channel_security_connector::~grpc_httpcli_ssl_channel_security_conn     +63  [NEW]
      [NEW]     +55 grpc_httpcli_ssl_channel_security_connector::~grpc_httpcli_ssl_channel_security_conn     +55  [NEW]
      [NEW]     +24 grpc_httpcli_ssl_channel_security_connector::cancel_check_call_host                      +24  [NEW]
      [NEW]     +13 grpc_httpcli_ssl_channel_security_connector::check_call_host                             +13  [NEW]
      [NEW]     +13 grpc_httpcli_ssl_channel_security_connector::cmp(grpc_security_connector const*) con     +13  [NEW]
   +11%    +176 src/core/lib/security/credentials/jwt/jwt_credentials.cc                                +176   +11%
      [NEW]    +599 grpc_service_account_jwt_access_credentials::get_request_metadata                       +599  [NEW]
      [NEW]    +215 grpc_service_account_jwt_access_credentials::grpc_service_account_jwt_access_credent    +215  [NEW]
      [NEW]     +63 grpc_service_account_jwt_access_credentials::reset_cache                                 +63  [NEW]
      [NEW]     +46 grpc_service_account_jwt_access_credentials::~grpc_service_account_jwt_access_creden     +46  [NEW]
       +71%     +24 [Unmapped]                                                                               +24   +71%
      [NEW]     +24 grpc_service_account_jwt_access_credentials::cancel_get_request_metadata                 +24  [NEW]
      [NEW]     +18 grpc_service_account_jwt_access_credentials::~grpc_service_account_jwt_access_creden     +18  [NEW]
   +30%    +174 src/core/lib/security/credentials/fake/fake_credentials.cc                              +174   +30%
      [NEW]     +68 grpc_md_only_test_credentials::get_request_metadata                                      +68  [NEW]
      [NEW]     +47 (anonymous namespace)::grpc_fake_server_credentials::~grpc_fake_server_credentials       +47  [NEW]
      [NEW]     +42 (anonymous namespace)::grpc_fake_server_credentials::~grpc_fake_server_credentials       +42  [NEW]
      [NEW]     +36 grpc_md_only_test_credentials::~grpc_md_only_test_credentials                            +36  [NEW]
      [NEW]     +24 grpc_md_only_test_credentials::cancel_get_request_metadata                               +24  [NEW]
      [NEW]     +23 grpc_md_only_test_credentials::~grpc_md_only_test_credentials                            +23  [NEW]
       +29%     +18 [Unmapped]                                                                               +18   +29%
      [NEW]     +16 (anonymous namespace)::grpc_fake_server_credentials::create_security_connector           +16  [NEW]
      [NEW]     +16 (anonymous namespace)::grpc_fake_channel_credentials::create_security_connector          +16  [NEW]
       +12%      +8 grpc_fake_transport_security_server_credentials_create                                    +8   +12%
      [NEW]      +5 (anonymous namespace)::grpc_fake_channel_credentials::~grpc_fake_channel_credentials      +5  [NEW]
      +1.8%      +3 grpc_md_only_test_credentials_create                                                      +3  +1.8%
      [NEW]      +2 (anonymous namespace)::grpc_fake_channel_credentials::~grpc_fake_channel_credentials      +2  [NEW]
  +6.4%    +161 src/core/lib/security/security_connector/fake/fake_security_connector.cc                +161  +6.4%
      [NEW]    +934 (anonymous namespace)::grpc_fake_channel_security_connector::check_peer                 +934  [NEW]
      [NEW]    +572 (anonymous namespace)::fake_check_peer(grpc_security_connector*, tsi_peer, grpc_auth    +572  [NEW]
      [NEW]    +386 (anonymous namespace)::grpc_fake_channel_security_connector::check_call_host            +386  [NEW]
      [NEW]    +108 (anonymous namespace)::grpc_fake_channel_security_connector::cmp(grpc_security_conne    +108  [NEW]
      [NEW]     +63 (anonymous namespace)::grpc_fake_channel_security_connector::~grpc_fake_channel_secu     +63  [NEW]
      [NEW]     +55 (anonymous namespace)::grpc_fake_channel_security_connector::~grpc_fake_channel_secu     +55  [NEW]
      [NEW]     +50 (anonymous namespace)::grpc_fake_channel_security_connector::add_handshakers             +50  [NEW]
      [NEW]     +47 (anonymous namespace)::grpc_fake_server_security_connector::add_handshakers              +47  [NEW]
      [NEW]     +28 (anonymous namespace)::grpc_fake_server_security_connector::~grpc_fake_server_securi     +28  [NEW]
      [NEW]     +24 (anonymous namespace)::grpc_fake_channel_security_connector::cancel_check_call_host      +24  [NEW]
      [NEW]     +20 (anonymous namespace)::grpc_fake_server_security_connector::check_peer                   +20  [NEW]
      [NEW]     +15 (anonymous namespace)::grpc_fake_server_security_connector::~grpc_fake_server_securi     +15  [NEW]
      [NEW]      +5 (anonymous namespace)::grpc_fake_server_security_connector::cmp(grpc_security_connec      +5  [NEW]
   +16%    +128 src/core/lib/security/credentials/iam/iam_credentials.cc                                +128   +16%
      [NEW]    +241 grpc_google_iam_credentials::grpc_google_iam_credentials                                +241  [NEW]
      +143%     +30 [Unmapped]                                                                               +30  +143%
      [NEW]     +26 grpc_google_iam_credentials::get_request_metadata                                        +26  [NEW]
      [NEW]     +24 grpc_google_iam_credentials::cancel_get_request_metadata                                 +24  [NEW]
      [NEW]     +24 grpc_google_iam_credentials::~grpc_google_iam_credentials                                +24  [NEW]
      [NEW]     +18 grpc_google_iam_credentials::~grpc_google_iam_credentials                                +18  [NEW]
   +58%    +123 src/core/lib/security/credentials/local/local_credentials.cc                            +123   +58%
      [NEW]     +61 grpc_local_server_credentials::grpc_local_server_credentials                             +61  [NEW]
      [NEW]     +47 grpc_local_server_credentials::~grpc_local_server_credentials                            +47  [NEW]
      [NEW]     +42 grpc_local_server_credentials::~grpc_local_server_credentials                            +42  [NEW]
      [NEW]     +37 grpc_local_credentials::grpc_local_credentials                                           +37  [NEW]
      [NEW]     +14 grpc_local_credentials::create_security_connector                                        +14  [NEW]
      [NEW]      +5 grpc_local_credentials::~grpc_local_credentials                                           +5  [NEW]
      [NEW]      +5 grpc_local_server_credentials::create_security_connector                                  +5  [NEW]
      [NEW]      +2 grpc_local_credentials::~grpc_local_credentials                                           +2  [NEW]
  +4.5%    +112 src/core/lib/security/credentials/plugin/plugin_credentials.cc                          +112  +4.5%
      [NEW]    +700 grpc_plugin_credentials::get_request_metadata                                           +700  [NEW]
      [NEW]    +546 process_plugin_result(grpc_plugin_credentials_pending_request*, grpc_metadata const*    +546  [NEW]
      [NEW]    +266 grpc_plugin_credentials::cancel_get_request_metadata                                    +266  [NEW]
      [NEW]     +84 grpc_plugin_credentials::pending_request_complete                                        +84  [NEW]
      [NEW]     +69 grpc_plugin_credentials::grpc_plugin_credentials                                         +69  [NEW]
      [NEW]     +58 grpc_plugin_credentials::~grpc_plugin_credentials                                        +58  [NEW]
      [NEW]     +46 grpc_plugin_credentials::pending_request_remove_locked                                   +46  [NEW]
       +74%     +31 [Unmapped]                                                                               +31   +74%
      [NEW]     +18 grpc_plugin_credentials::~grpc_plugin_credentials                                        +18  [NEW]
      +3.1%     +16 plugin_md_request_metadata_ready                                                         +16  +3.1%
  +2.7%    +112 src/core/lib/security/transport/security_handshaker.cc                                  +112  +2.7%
       +54%     +76 security_handshaker_unref                                                                +76   +54%
       +57%     +23 client_handshaker_factory_add_handshakers                                                +23   +57%
       +57%     +23 server_handshaker_factory_add_handshakers                                                +23   +57%
      +0.5%      +1 check_peer_locked                                                                         +1  +0.5%
  +3.2%     +95 [Other]                                                                                  +95  +3.2%
  +3.3%     +89 src/core/lib/security/transport/server_auth_filter.cc                                    +89  +3.3%
      +326%     +75 destroy_channel_elem                                                                     +75  +326%
      +3.9%      +8 init_call_elem                                                                            +8  +3.9%
      +6.5%      +6 [Unmapped]                                                                                +6  +6.5%
  +4.8%     +68 src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb_channel_secure.cc            +68  +4.8%
      +5.5%     +68 grpc_lb_policy_grpclb_modify_lb_channel_args                                             +68  +5.5%
  +5.4%     +68 src/core/ext/filters/client_channel/lb_policy/xds/xds_channel_secure.cc                  +68  +5.4%
      +5.5%     +68 grpc_lb_policy_xds_modify_lb_channel_args                                                +68  +5.5%

 -------------- SHRINKING                                                                            --------------
 -31.3%    -432 src/core/lib/security/security_connector/security_connector.cc                          -432 -31.3%
      [DEL]    -215 grpc_channel_security_connector_cmp                                                     -215  [DEL]
      [DEL]    -186 grpc_security_connector_check_peer                                                      -186  [DEL]
      [DEL]    -167 grpc_server_security_connector_cmp                                                      -167  [DEL]
      [DEL]    -166 grpc_channel_security_connector_check_call_host                                         -166  [DEL]
      [DEL]     -70 grpc_security_connector_cmp                                                              -70  [DEL]
      [DEL]     -50 grpc_security_connector_unref                                                            -50  [DEL]
      [DEL]     -40 grpc_channel_security_connector_cancel_check_call_host                                   -40  [DEL]
      [DEL]     -23 grpc_security_connector_ref                                                              -23  [DEL]
      [DEL]     -18 grpc_server_security_connector_add_handshakers                                           -18  [DEL]
      [DEL]     -18 grpc_channel_security_connector_add_handshakers                                          -18  [DEL]
      -9.3%     -13 [Unmapped]                                                                               -13  -9.3%
 -12.7%    -304 src/core/lib/security/credentials/credentials.cc                                        -304 -12.7%
      [DEL]    -109 grpc_channel_credentials_create_security_connector                                      -109  [DEL]
     -83.5%     -96 grpc_server_credentials_set_auth_metadata_processor                                      -96 -83.5%
     -41.3%     -95 [Unmapped]                                                                               -95 -41.3%
      [DEL]     -82 grpc_server_credentials_unref                                                            -82  [DEL]
      [DEL]     -69 grpc_server_credentials_create_security_connector                                        -69  [DEL]
      [DEL]     -58 grpc_call_credentials_unref                                                              -58  [DEL]
      [DEL]     -58 grpc_channel_credentials_unref                                                           -58  [DEL]
      [DEL]     -37 grpc_channel_credentials_duplicate_without_call_credentials                              -37  [DEL]
      [DEL]     -30 grpc_call_credentials_get_request_metadata                                               -30  [DEL]
      [DEL]     -26 grpc_call_credentials_cancel_get_request_metadata                                        -26  [DEL]
      [DEL]     -23 grpc_call_credentials_ref                                                                -23  [DEL]
      [DEL]     -23 grpc_server_credentials_ref                                                              -23  [DEL]
      [DEL]     -23 grpc_channel_credentials_ref                                                             -23  [DEL]
     -30.2%     -13 grpc_credentials_metadata_request_create                                                 -13 -30.2%
     -60.0%      -3 server_credentials_pointer_arg_copy                                                       -3 -60.0%
  -5.7%     -96 src/core/lib/security/security_connector/local/local_security_connector.cc               -96  -5.7%
      [DEL]    -352 local_check_peer                                                                        -352  [DEL]
      [DEL]    -152 local_channel_add_handshakers                                                           -152  [DEL]
      [DEL]    -144 local_check_call_host                                                                   -144  [DEL]
      [DEL]    -144 local_server_add_handshakers                                                            -144  [DEL]
     -14.8%     -64 grpc_local_channel_security_connector_create                                             -64 -14.8%
      [DEL]     -55 local_channel_cmp                                                                        -55  [DEL]
      [DEL]     -50 local_channel_destroy                                                                    -50  [DEL]
     -21.3%     -48 grpc_local_server_security_connector_create                                              -48 -21.3%
      [DEL]     -34 local_server_destroy                                                                     -34  [DEL]
      [DEL]     -24 local_cancel_check_call_host                                                             -24  [DEL]
     -15.4%     -10 [Unmapped]                                                                               -10 -15.4%
      [DEL]      -5 local_server_cmp                                                                          -5  [DEL]
  -1.8%     -40 src/core/lib/security/security_connector/alts/alts_security_connector.cc                 -40  -1.8%
      [DEL]    -199 alts_check_peer                                                                         -199  [DEL]
      [DEL]    -176 alts_channel_add_handshakers                                                            -176  [DEL]
      [DEL]    -168 alts_server_add_handshakers                                                             -168  [DEL]
      [DEL]    -144 alts_check_call_host                                                                    -144  [DEL]
     -27.0%     -64 grpc_alts_channel_security_connector_create                                              -64 -27.0%
      [DEL]     -55 alts_channel_cmp                                                                         -55  [DEL]
      [DEL]     -50 alts_channel_destroy                                                                     -50  [DEL]
      [DEL]     -38 alts_set_rpc_protocol_versions                                                           -38  [DEL]
      [DEL]     -34 alts_server_destroy                                                                      -34  [DEL]
     -15.7%     -24 grpc_alts_server_security_connector_create                                               -24 -15.7%
      [DEL]     -24 alts_cancel_check_call_host                                                              -24  [DEL]
      [DEL]      -5 alts_server_cmp                                                                           -5  [DEL]
      -4.7%      -4 [Unmapped]                                                                                -4  -4.7%

  +1.4% +20.9Ki TOTAL                                                                                 +344Ki  +3.1%


****************************************************************

libgrpc++.so

     VM SIZE                                                                                            FILE SIZE
 ++++++++++++++ GROWING                                                                              ++++++++++++++
  +3.7%    +276 src/cpp/client/secure_credentials.cc                                                    +276  +3.7%
      [NEW]    +200 void std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >    +200  [NEW]
      +161%     +58 grpc::SecureCallCredentials::~SecureCallCredentials                                      +58  +161%
      +161%     +58 grpc::SecureChannelCredentials::~SecureChannelCredentials                                +58  +161%
       +71%     +41 std::_Sp_counted_ptr<grpc::SecureCallCredentials*, (__gnu_cxx::_Lock_policy)2>::_M_d     +41   +71%
       +71%     +41 std::_Sp_counted_ptr<grpc::SecureChannelCredentials*, (__gnu_cxx::_Lock_policy)2>::_     +41   +71%
       +89%     +39 grpc::SecureCallCredentials::~SecureCallCredentials                                      +39   +89%
       +89%     +39 grpc::SecureChannelCredentials::~SecureChannelCredentials                                +39   +89%
      +4.1%      +8 grpc::(anonymous namespace)::WrapCallCredentials                                          +8  +4.1%
      +4.1%      +8 grpc::(anonymous namespace)::WrapChannelCredentials                                       +8  +4.1%

 -+-+-+-+-+-+-+ MIXED                                                                                +-+-+-+-+-+-+-
  -0.0%     -52 [None]                                                                               +13.7Ki  +0.2%

  +0.0%    +224 TOTAL                                                                                +14.0Ki  +0.2%



@grpc-testing
Copy link

[trickle] No significant performance differences

@grpc-testing
Copy link

****************************************************************

libgrpc.so

     VM SIZE                                                                                            FILE SIZE
 ++++++++++++++ GROWING                                                                              ++++++++++++++
  +2.3% +17.4Ki [None]                                                                                +343Ki  +3.4%
      +2.4% +16.4Ki [Unmapped]                                                                            +342Ki  +3.4%
      [NEW]    +552 [Other]                                                                                 +552  [NEW]
      [NEW]     +72 vtable for grpc_channel_security_connector                                               +72  [NEW]
      [NEW]     +72 vtable for grpc_httpcli_ssl_channel_security_connector                                   +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_ssl_channel_security_connector                    +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_alts_channel_security_connector                   +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_fake_channel_security_connector                   +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_local_channel_security_connector                  +72  [NEW]
      [NEW]     +56 vtable for grpc_server_security_connector                                                +56  [NEW]
      [NEW]     +56 vtable for grpc_google_refresh_token_credentials                                         +56  [NEW]
      [NEW]     +56 vtable for grpc_oauth2_token_fetcher_credentials                                         +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_ssl_server_security_connector                     +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_alts_server_security_connector                    +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_fake_server_security_connector                    +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_local_server_security_connector                   +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials          +56  [NEW]
      [NEW]     +48 vtable for grpc_ssl_credentials                                                          +48  [NEW]
      [NEW]     +48 vtable for grpc_alts_credentials                                                         +48  [NEW]
      [NEW]     +48 vtable for grpc_local_credentials                                                        +48  [NEW]
      [NEW]     +48 vtable for grpc_plugin_credentials                                                       +48  [NEW]
      [NEW]     +48 vtable for grpc_google_iam_credentials                                                   +48  [NEW]
   +13%    +449 src/core/lib/security/security_connector/ssl/ssl_security_connector.cc                  +449   +13%
      [NEW]    +668 (anonymous namespace)::grpc_ssl_server_security_connector::add_handshakers              +668  [NEW]
      [NEW]    +615 (anonymous namespace)::grpc_ssl_channel_security_connector::check_peer                  +615  [NEW]
      +104%    +497 grpc_ssl_server_security_connector_create                                               +497  +104%
      [NEW]    +213 (anonymous namespace)::grpc_ssl_channel_security_connector::check_call_host             +213  [NEW]
      [NEW]    +171 (anonymous namespace)::grpc_ssl_channel_security_connector::add_handshakers             +171  [NEW]
       +23%    +141 grpc_ssl_channel_security_connector_create                                              +141   +23%
      [NEW]    +111 (anonymous namespace)::grpc_ssl_channel_security_connector::cmp(grpc_security_connec    +111  [NEW]
      [NEW]     +75 (anonymous namespace)::grpc_ssl_server_security_connector::check_peer                    +75  [NEW]
      [NEW]     +60 (anonymous namespace)::grpc_ssl_channel_security_connector::~grpc_ssl_channel_securi     +60  [NEW]
      [NEW]     +36 (anonymous namespace)::grpc_ssl_server_security_connector::~grpc_ssl_server_security     +36  [NEW]
      [NEW]     +32 (anonymous namespace)::grpc_ssl_server_security_connector::~grpc_ssl_server_security     +32  [NEW]
      [NEW]     +24 (anonymous namespace)::grpc_ssl_channel_security_connector::cancel_check_call_host       +24  [NEW]
      [NEW]     +14 (anonymous namespace)::grpc_ssl_channel_security_connector::~grpc_ssl_channel_securi     +14  [NEW]
      [NEW]      +5 (anonymous namespace)::grpc_ssl_server_security_connector::cmp(grpc_security_connect      +5  [NEW]
   +10%    +338 src/core/lib/security/context/security_context.cc                                       +338   +10%
      [NEW]    +114 grpc_auth_context::~grpc_auth_context                                                   +114  [NEW]
      [NEW]    +112 grpc_auth_context::add_property                                                         +112  [NEW]
      [NEW]     +82 grpc_auth_context::add_cstring_property                                                  +82  [NEW]
      +146%     +73 grpc_client_security_context::~grpc_client_security_context                              +73  +146%
       +96%     +67 grpc_auth_context_create                                                                 +67   +96%
      [NEW]     +62 grpc_auth_context::ensure_capacity                                                       +62  [NEW]
      [NEW]     +59 grpc_client_security_context_create                                                      +59  [NEW]
       +95%     +40 grpc_server_security_context::~grpc_server_security_context                              +40   +95%
      +7.3%     +36 grpc_call_set_credentials                                                                +36  +7.3%
      +580%     +29 auth_context_pointer_arg_destroy                                                         +29  +580%
       +48%     +29 grpc_auth_context_release                                                                +29   +48%
      +220%     +11 auth_context_pointer_arg_copy                                                            +11  +220%
      +8.5%     +11 grpc_call_auth_context                                                                   +11  +8.5%
   +11%    +304 src/core/lib/security/credentials/google_default/google_default_credentials.cc          +304   +11%
      [NEW]    +216 grpc_google_default_channel_credentials::create_security_connector                      +216  [NEW]
       +12%    +119 grpc_google_default_credentials_create                                                  +119   +12%
      [NEW]    +115 grpc_google_default_channel_credentials::~grpc_google_default_channel_credentials       +115  [NEW]
      [NEW]     +64 grpc_google_default_channel_credentials::grpc_google_default_channel_credentials         +64  [NEW]
       +31%     +15 [Unmapped]                                                                               +15   +31%
      [NEW]     +14 grpc_google_default_channel_credentials::~grpc_google_default_channel_credentials        +14  [NEW]
   +68%    +282 src/core/lib/security/credentials/alts/alts_credentials.cc                              +282   +68%
      [NEW]    +135 grpc_alts_server_credentials::grpc_alts_server_credentials                              +135  [NEW]
      [NEW]    +111 grpc_alts_credentials::grpc_alts_credentials                                            +111  [NEW]
      [NEW]     +82 grpc_alts_server_credentials::~grpc_alts_server_credentials                              +82  [NEW]
      [NEW]     +37 grpc_alts_credentials::~grpc_alts_credentials                                            +37  [NEW]
       +33%     +21 [Unmapped]                                                                               +21   +33%
      [NEW]     +14 grpc_alts_credentials::~grpc_alts_credentials                                            +14  [NEW]
      [NEW]     +14 grpc_alts_server_credentials::~grpc_alts_server_credentials                              +14  [NEW]
      [NEW]     +10 grpc_channel_credentials::duplicate_without_call_credentials                             +10  [NEW]
      [NEW]      +8 grpc_alts_credentials::create_security_connector                                          +8  [NEW]
      [NEW]      +5 grpc_alts_server_credentials::create_security_connector                                   +5  [NEW]
  +8.3%    +282 src/core/lib/security/transport/client_auth_filter.cc                                   +282  +8.3%
      +250%     +70 destroy_channel_elem                                                                     +70  +250%
       +83%     +54 grpc_auth_metadata_context_reset                                                         +54   +83%
      +6.7%     +42 auth_start_transport_stream_op_batch                                                     +42  +6.7%
       +47%     +37 destroy_call_elem                                                                        +37   +47%
       +65%     +31 [Unmapped]                                                                               +31   +65%
      +2.0%     +16 on_host_checked                                                                          +16  +2.0%
       +22%     +16 cancel_get_request_metadata                                                              +16   +22%
      +1.7%      +8 grpc_auth_metadata_context_build                                                          +8  +1.7%
       +11%      +8 cancel_check_call_host                                                                    +8   +11%
  +5.3%    +263 src/core/lib/security/credentials/oauth2/oauth2_credentials.cc                          +263  +5.3%
      [NEW]    +528 grpc_oauth2_token_fetcher_credentials::on_http_response                                 +528  [NEW]
      [NEW]    +418 grpc_google_refresh_token_credentials::fetch_oauth2                                     +418  [NEW]
      [NEW]    +387 grpc_oauth2_token_fetcher_credentials::get_request_metadata                             +387  [NEW]
      [NEW]    +367 grpc_access_token_credentials::grpc_access_token_credentials                            +367  [NEW]
      [NEW]    +309 (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials::fetch_oauth2      +309  [NEW]
      [NEW]    +225 grpc_oauth2_token_fetcher_credentials::cancel_get_request_metadata                      +225  [NEW]
      [NEW]    +112 grpc_oauth2_token_fetcher_credentials::grpc_oauth2_token_fetcher_credentials            +112  [NEW]
      [NEW]     +63 grpc_oauth2_token_fetcher_credentials::~grpc_oauth2_token_fetcher_credentials            +63  [NEW]
      [NEW]     +51 grpc_google_refresh_token_credentials::grpc_google_refresh_token_credentials             +51  [NEW]
      [NEW]     +40 grpc_google_refresh_token_credentials::~grpc_google_refresh_token_credentials            +40  [NEW]
       +22%     +37 [Unmapped]                                                                               +37   +22%
      [NEW]     +26 grpc_access_token_credentials::get_request_metadata                                      +26  [NEW]
      [NEW]     +24 (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials::~grpc_compute_     +24  [NEW]
      [NEW]     +24 grpc_access_token_credentials::cancel_get_request_metadata                               +24  [NEW]
      [NEW]     +23 grpc_access_token_credentials::~grpc_access_token_credentials                            +23  [NEW]
      +9.9%     +16 grpc_google_compute_engine_credentials_create                                            +16  +9.9%
      [NEW]     +15 (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials::~grpc_compute_     +15  [NEW]
      [NEW]     +14 grpc_access_token_credentials::~grpc_access_token_credentials                            +14  [NEW]
      [NEW]     +14 grpc_google_refresh_token_credentials::~grpc_google_refresh_token_credentials            +14  [NEW]
      [NEW]     +14 grpc_oauth2_token_fetcher_credentials::~grpc_oauth2_token_fetcher_credentials            +14  [NEW]
      +6.6%      +8 [Other]                                                                                   +8  +6.6%
  +9.8%    +256 src/core/lib/security/credentials/ssl/ssl_credentials.cc                                +256  +9.8%
      [NEW]    +341 grpc_ssl_credentials::create_security_connector                                         +341  [NEW]
      [NEW]    +299 grpc_ssl_credentials::build_config                                                      +299  [NEW]
      [NEW]    +116 grpc_ssl_server_credentials::grpc_ssl_server_credentials                                +116  [NEW]
      [NEW]     +82 grpc_ssl_server_credentials::~grpc_ssl_server_credentials                                +82  [NEW]
      [NEW]     +66 grpc_ssl_credentials::~grpc_ssl_credentials                                              +66  [NEW]
      [NEW]     +60 grpc_ssl_server_credentials::build_config                                                +60  [NEW]
      [NEW]     +38 grpc_ssl_credentials::grpc_ssl_credentials                                               +38  [NEW]
       +20%     +30 [Unmapped]                                                                               +30   +20%
      [NEW]     +14 grpc_ssl_credentials::~grpc_ssl_credentials                                              +14  [NEW]
      [NEW]     +14 grpc_ssl_server_credentials::~grpc_ssl_server_credentials                                +14  [NEW]
      +2.3%      +8 grpc_ssl_server_certificate_config_create                                                 +8  +2.3%
      [NEW]      +5 grpc_ssl_server_credentials::create_security_connector                                    +5  [NEW]
   +11%    +240 src/core/lib/security/credentials/composite/composite_credentials.cc                    +240   +11%
      [NEW]    +285 grpc_composite_call_credentials::get_request_metadata                                   +285  [NEW]
      [NEW]    +234 grpc_composite_call_credentials::grpc_composite_call_credentials                        +234  [NEW]
      [NEW]    +226 grpc_composite_channel_credentials::create_security_connector                           +226  [NEW]
      [NEW]    +150 grpc_composite_call_credentials::cancel_get_request_metadata                            +150  [NEW]
      [NEW]    +110 grpc_composite_channel_credentials::~grpc_composite_channel_credentials                 +110  [NEW]
      [NEW]    +101 grpc_composite_call_credentials::~grpc_composite_call_credentials                       +101  [NEW]
      [NEW]     +14 grpc_composite_call_credentials::~grpc_composite_call_credentials                        +14  [NEW]
      [NEW]     +14 grpc_composite_channel_credentials::~grpc_composite_channel_credentials                  +14  [NEW]
       +15%     +13 [Unmapped]                                                                               +13   +15%
      [NEW]     +11 grpc_composite_channel_credentials::duplicate_without_call_credentials                   +11  [NEW]
      +0.5%      +1 composite_call_metadata_cb                                                                +1  +0.5%
   +18%    +222 src/core/lib/http/httpcli_security_connector.cc                                         +222   +18%
      [NEW]    +279 grpc_httpcli_ssl_channel_security_connector::check_peer                                 +279  [NEW]
       +33%    +192 ssl_handshake                                                                           +192   +33%
      [NEW]    +160 grpc_httpcli_ssl_channel_security_connector::add_handshakers                            +160  [NEW]
      [NEW]     +55 grpc_httpcli_ssl_channel_security_connector::~grpc_httpcli_ssl_channel_security_conn     +55  [NEW]
      [NEW]     +24 grpc_httpcli_ssl_channel_security_connector::cancel_check_call_host                      +24  [NEW]
      [NEW]     +14 grpc_httpcli_ssl_channel_security_connector::~grpc_httpcli_ssl_channel_security_conn     +14  [NEW]
      [NEW]     +13 grpc_httpcli_ssl_channel_security_connector::check_call_host                             +13  [NEW]
      [NEW]     +13 grpc_httpcli_ssl_channel_security_connector::cmp(grpc_security_connector const*) con     +13  [NEW]
   +29%    +170 src/core/lib/security/credentials/fake/fake_credentials.cc                              +170   +29%
      [NEW]     +68 grpc_md_only_test_credentials::get_request_metadata                                      +68  [NEW]
      [NEW]     +43 (anonymous namespace)::grpc_fake_server_credentials::~grpc_fake_server_credentials       +43  [NEW]
      [NEW]     +42 (anonymous namespace)::grpc_fake_server_credentials::~grpc_fake_server_credentials       +42  [NEW]
      [NEW]     +32 grpc_md_only_test_credentials::~grpc_md_only_test_credentials                            +32  [NEW]
      [NEW]     +24 grpc_md_only_test_credentials::cancel_get_request_metadata                               +24  [NEW]
      [NEW]     +23 grpc_md_only_test_credentials::~grpc_md_only_test_credentials                            +23  [NEW]
       +29%     +18 [Unmapped]                                                                               +18   +29%
      [NEW]     +16 (anonymous namespace)::grpc_fake_server_credentials::create_security_connector           +16  [NEW]
      [NEW]     +16 (anonymous namespace)::grpc_fake_channel_credentials::create_security_connector          +16  [NEW]
      [NEW]      +9 (anonymous namespace)::grpc_fake_channel_credentials::~grpc_fake_channel_credentials      +9  [NEW]
       +12%      +8 grpc_fake_transport_security_server_credentials_create                                    +8   +12%
      +1.8%      +3 grpc_md_only_test_credentials_create                                                      +3  +1.8%
      [NEW]      +2 (anonymous namespace)::grpc_fake_channel_credentials::~grpc_fake_channel_credentials      +2  [NEW]
  +9.6%    +160 src/core/lib/security/credentials/jwt/jwt_credentials.cc                                +160  +9.6%
      [NEW]    +599 grpc_service_account_jwt_access_credentials::get_request_metadata                       +599  [NEW]
      [NEW]    +215 grpc_service_account_jwt_access_credentials::grpc_service_account_jwt_access_credent    +215  [NEW]
      [NEW]     +63 grpc_service_account_jwt_access_credentials::reset_cache                                 +63  [NEW]
      [NEW]     +46 grpc_service_account_jwt_access_credentials::~grpc_service_account_jwt_access_creden     +46  [NEW]
      [NEW]     +24 grpc_service_account_jwt_access_credentials::cancel_get_request_metadata                 +24  [NEW]
      [NEW]     +14 grpc_service_account_jwt_access_credentials::~grpc_service_account_jwt_access_creden     +14  [NEW]
       +35%     +12 [Unmapped]                                                                               +12   +35%
   +58%    +123 src/core/lib/security/credentials/local/local_credentials.cc                            +123   +58%
      [NEW]     +61 grpc_local_server_credentials::grpc_local_server_credentials                             +61  [NEW]
      [NEW]     +43 grpc_local_server_credentials::~grpc_local_server_credentials                            +43  [NEW]
      [NEW]     +42 grpc_local_server_credentials::~grpc_local_server_credentials                            +42  [NEW]
      [NEW]     +37 grpc_local_credentials::grpc_local_credentials                                           +37  [NEW]
      [NEW]     +14 grpc_local_credentials::create_security_connector                                        +14  [NEW]
      [NEW]      +9 grpc_local_credentials::~grpc_local_credentials                                           +9  [NEW]
      [NEW]      +5 grpc_local_server_credentials::create_security_connector                                  +5  [NEW]
      [NEW]      +2 grpc_local_credentials::~grpc_local_credentials                                           +2  [NEW]
  +4.5%    +113 src/core/lib/security/security_connector/fake/fake_security_connector.cc                +113  +4.5%
      [NEW]    +934 (anonymous namespace)::grpc_fake_channel_security_connector::check_peer                 +934  [NEW]
      [NEW]    +572 (anonymous namespace)::fake_check_peer(grpc_security_connector*, tsi_peer, grpc_auth    +572  [NEW]
      [NEW]    +386 (anonymous namespace)::grpc_fake_channel_security_connector::check_call_host            +386  [NEW]
      [NEW]    +108 (anonymous namespace)::grpc_fake_channel_security_connector::cmp(grpc_security_conne    +108  [NEW]
      [NEW]     +55 (anonymous namespace)::grpc_fake_channel_security_connector::~grpc_fake_channel_secu     +55  [NEW]
      [NEW]     +50 (anonymous namespace)::grpc_fake_channel_security_connector::add_handshakers             +50  [NEW]
      [NEW]     +47 (anonymous namespace)::grpc_fake_server_security_connector::add_handshakers              +47  [NEW]
      [NEW]     +24 (anonymous namespace)::grpc_fake_server_security_connector::~grpc_fake_server_securi     +24  [NEW]
      [NEW]     +24 (anonymous namespace)::grpc_fake_channel_security_connector::cancel_check_call_host      +24  [NEW]
      [NEW]     +20 (anonymous namespace)::grpc_fake_server_security_connector::check_peer                   +20  [NEW]
      [NEW]     +15 (anonymous namespace)::grpc_fake_server_security_connector::~grpc_fake_server_securi     +15  [NEW]
      [NEW]     +14 (anonymous namespace)::grpc_fake_channel_security_connector::~grpc_fake_channel_secu     +14  [NEW]
      [NEW]      +5 (anonymous namespace)::grpc_fake_server_security_connector::cmp(grpc_security_connec      +5  [NEW]
   +14%    +112 src/core/lib/security/credentials/iam/iam_credentials.cc                                +112   +14%
      [NEW]    +241 grpc_google_iam_credentials::grpc_google_iam_credentials                                +241  [NEW]
      [NEW]     +26 grpc_google_iam_credentials::get_request_metadata                                        +26  [NEW]
      [NEW]     +24 grpc_google_iam_credentials::cancel_get_request_metadata                                 +24  [NEW]
      [NEW]     +24 grpc_google_iam_credentials::~grpc_google_iam_credentials                                +24  [NEW]
       +86%     +18 [Unmapped]                                                                               +18   +86%
      [NEW]     +14 grpc_google_iam_credentials::~grpc_google_iam_credentials                                +14  [NEW]
  +2.7%    +112 src/core/lib/security/transport/security_handshaker.cc                                  +112  +2.7%
       +54%     +76 security_handshaker_unref                                                                +76   +54%
       +57%     +23 client_handshaker_factory_add_handshakers                                                +23   +57%
       +57%     +23 server_handshaker_factory_add_handshakers                                                +23   +57%
      +0.5%      +1 check_peer_locked                                                                         +1  +0.5%
  +3.8%     +96 src/core/lib/security/credentials/plugin/plugin_credentials.cc                           +96  +3.8%
      [NEW]    +700 grpc_plugin_credentials::get_request_metadata                                           +700  [NEW]
      [NEW]    +546 process_plugin_result(grpc_plugin_credentials_pending_request*, grpc_metadata const*    +546  [NEW]
      [NEW]    +266 grpc_plugin_credentials::cancel_get_request_metadata                                    +266  [NEW]
      [NEW]     +84 grpc_plugin_credentials::pending_request_complete                                        +84  [NEW]
      [NEW]     +69 grpc_plugin_credentials::grpc_plugin_credentials                                         +69  [NEW]
      [NEW]     +58 grpc_plugin_credentials::~grpc_plugin_credentials                                        +58  [NEW]
      [NEW]     +46 grpc_plugin_credentials::pending_request_remove_locked                                   +46  [NEW]
       +45%     +19 [Unmapped]                                                                               +19   +45%
      +3.1%     +16 plugin_md_request_metadata_ready                                                         +16  +3.1%
      [NEW]     +14 grpc_plugin_credentials::~grpc_plugin_credentials                                        +14  [NEW]
  +3.2%     +95 [Other]                                                                                  +95  +3.2%
  +3.3%     +89 src/core/lib/security/transport/server_auth_filter.cc                                    +89  +3.3%
      +326%     +75 destroy_channel_elem                                                                     +75  +326%
      +3.9%      +8 init_call_elem                                                                            +8  +3.9%
      +6.5%      +6 [Unmapped]                                                                                +6  +6.5%
  +4.8%     +68 src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb_channel_secure.cc            +68  +4.8%
      +5.5%     +68 grpc_lb_policy_grpclb_modify_lb_channel_args                                             +68  +5.5%
  +5.4%     +68 src/core/ext/filters/client_channel/lb_policy/xds/xds_channel_secure.cc                  +68  +5.4%
      +5.5%     +68 grpc_lb_policy_xds_modify_lb_channel_args                                                +68  +5.5%

 -------------- SHRINKING                                                                            --------------
 -33.6%    -464 src/core/lib/security/security_connector/security_connector.cc                          -464 -33.6%
      [DEL]    -215 grpc_channel_security_connector_cmp                                                     -215  [DEL]
      [DEL]    -186 grpc_security_connector_check_peer                                                      -186  [DEL]
      [DEL]    -167 grpc_server_security_connector_cmp                                                      -167  [DEL]
      [DEL]    -166 grpc_channel_security_connector_check_call_host                                         -166  [DEL]
      [DEL]     -70 grpc_security_connector_cmp                                                              -70  [DEL]
      [DEL]     -50 grpc_security_connector_unref                                                            -50  [DEL]
      [DEL]     -40 grpc_channel_security_connector_cancel_check_call_host                                   -40  [DEL]
     -26.4%     -37 [Unmapped]                                                                               -37 -26.4%
      [DEL]     -23 grpc_security_connector_ref                                                              -23  [DEL]
      [DEL]     -18 grpc_server_security_connector_add_handshakers                                           -18  [DEL]
      [DEL]     -18 grpc_channel_security_connector_add_handshakers                                          -18  [DEL]
 -12.7%    -304 src/core/lib/security/credentials/credentials.cc                                        -304 -12.7%
      [DEL]    -109 grpc_channel_credentials_create_security_connector                                      -109  [DEL]
     -83.5%     -96 grpc_server_credentials_set_auth_metadata_processor                                      -96 -83.5%
     -41.3%     -95 [Unmapped]                                                                               -95 -41.3%
      [DEL]     -82 grpc_server_credentials_unref                                                            -82  [DEL]
      [DEL]     -69 grpc_server_credentials_create_security_connector                                        -69  [DEL]
      [DEL]     -58 grpc_call_credentials_unref                                                              -58  [DEL]
      [DEL]     -58 grpc_channel_credentials_unref                                                           -58  [DEL]
      [DEL]     -37 grpc_channel_credentials_duplicate_without_call_credentials                              -37  [DEL]
      [DEL]     -30 grpc_call_credentials_get_request_metadata                                               -30  [DEL]
      [DEL]     -26 grpc_call_credentials_cancel_get_request_metadata                                        -26  [DEL]
      [DEL]     -23 grpc_call_credentials_ref                                                                -23  [DEL]
      [DEL]     -23 grpc_server_credentials_ref                                                              -23  [DEL]
      [DEL]     -23 grpc_channel_credentials_ref                                                             -23  [DEL]
     -30.2%     -13 grpc_credentials_metadata_request_create                                                 -13 -30.2%
     -60.0%      -3 server_credentials_pointer_arg_copy                                                       -3 -60.0%
  -5.7%     -96 src/core/lib/security/security_connector/local/local_security_connector.cc               -96  -5.7%
      [DEL]    -352 local_check_peer                                                                        -352  [DEL]
      [DEL]    -152 local_channel_add_handshakers                                                           -152  [DEL]
      [DEL]    -144 local_check_call_host                                                                   -144  [DEL]
      [DEL]    -144 local_server_add_handshakers                                                            -144  [DEL]
     -14.8%     -64 grpc_local_channel_security_connector_create                                             -64 -14.8%
      [DEL]     -55 local_channel_cmp                                                                        -55  [DEL]
      [DEL]     -50 local_channel_destroy                                                                    -50  [DEL]
     -21.3%     -48 grpc_local_server_security_connector_create                                              -48 -21.3%
      [DEL]     -34 local_server_destroy                                                                     -34  [DEL]
      [DEL]     -24 local_cancel_check_call_host                                                             -24  [DEL]
      [DEL]      -5 local_server_cmp                                                                          -5  [DEL]
      -3.1%      -2 [Unmapped]                                                                                -2  -3.1%
  -1.8%     -40 src/core/lib/security/security_connector/alts/alts_security_connector.cc                 -40  -1.8%
      [DEL]    -199 alts_check_peer                                                                         -199  [DEL]
      [DEL]    -176 alts_channel_add_handshakers                                                            -176  [DEL]
      [DEL]    -168 alts_server_add_handshakers                                                             -168  [DEL]
      [DEL]    -144 alts_check_call_host                                                                    -144  [DEL]
     -27.0%     -64 grpc_alts_channel_security_connector_create                                              -64 -27.0%
      [DEL]     -55 alts_channel_cmp                                                                         -55  [DEL]
      [DEL]     -50 alts_channel_destroy                                                                     -50  [DEL]
      [DEL]     -38 alts_set_rpc_protocol_versions                                                           -38  [DEL]
      [DEL]     -34 alts_server_destroy                                                                      -34  [DEL]
     -15.7%     -24 grpc_alts_server_security_connector_create                                               -24 -15.7%
      [DEL]     -24 alts_cancel_check_call_host                                                              -24  [DEL]
      [DEL]      -5 alts_server_cmp                                                                           -5  [DEL]

  +1.3% +20.3Ki TOTAL                                                                                 +346Ki  +3.1%


****************************************************************

libgrpc++.so

     VM SIZE                                                                                            FILE SIZE
 ++++++++++++++ GROWING                                                                              ++++++++++++++
  +3.7%    +276 src/cpp/client/secure_credentials.cc                                                    +276  +3.7%
      [NEW]    +200 void std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >    +200  [NEW]
      +161%     +58 grpc::SecureCallCredentials::~SecureCallCredentials                                      +58  +161%
      +161%     +58 grpc::SecureChannelCredentials::~SecureChannelCredentials                                +58  +161%
       +71%     +41 std::_Sp_counted_ptr<grpc::SecureCallCredentials*, (__gnu_cxx::_Lock_policy)2>::_M_d     +41   +71%
       +71%     +41 std::_Sp_counted_ptr<grpc::SecureChannelCredentials*, (__gnu_cxx::_Lock_policy)2>::_     +41   +71%
       +89%     +39 grpc::SecureCallCredentials::~SecureCallCredentials                                      +39   +89%
       +89%     +39 grpc::SecureChannelCredentials::~SecureChannelCredentials                                +39   +89%
      +4.1%      +8 grpc::(anonymous namespace)::WrapCallCredentials                                          +8  +4.1%
      +4.1%      +8 grpc::(anonymous namespace)::WrapChannelCredentials                                       +8  +4.1%

 -+-+-+-+-+-+-+ MIXED                                                                                +-+-+-+-+-+-+-
  -0.0%     -52 [None]                                                                               +13.8Ki  +0.2%

  +0.0%    +224 TOTAL                                                                                +14.1Ki  +0.2%



@grpc-testing
Copy link

[trickle] No significant performance differences

@grpc-testing
Copy link

****************************************************************

libgrpc.so

     VM SIZE                                                                                            FILE SIZE
 ++++++++++++++ GROWING                                                                              ++++++++++++++
  +2.6% +19.5Ki [None]                                                                                +364Ki  +3.6%
      +2.7% +18.5Ki [Unmapped]                                                                            +363Ki  +3.6%
      [NEW]    +552 [Other]                                                                                 +552  [NEW]
      [NEW]     +72 vtable for grpc_channel_security_connector                                               +72  [NEW]
      [NEW]     +72 vtable for grpc_httpcli_ssl_channel_security_connector                                   +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_ssl_channel_security_connector                    +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_alts_channel_security_connector                   +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_fake_channel_security_connector                   +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_local_channel_security_connector                  +72  [NEW]
      [NEW]     +56 vtable for grpc_server_security_connector                                                +56  [NEW]
      [NEW]     +56 vtable for grpc_google_refresh_token_credentials                                         +56  [NEW]
      [NEW]     +56 vtable for grpc_oauth2_token_fetcher_credentials                                         +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_ssl_server_security_connector                     +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_alts_server_security_connector                    +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_fake_server_security_connector                    +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_local_server_security_connector                   +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials          +56  [NEW]
      [NEW]     +48 vtable for grpc_ssl_credentials                                                          +48  [NEW]
      [NEW]     +48 vtable for grpc_alts_credentials                                                         +48  [NEW]
      [NEW]     +48 vtable for grpc_local_credentials                                                        +48  [NEW]
      [NEW]     +48 vtable for grpc_plugin_credentials                                                       +48  [NEW]
      [NEW]     +48 vtable for grpc_google_iam_credentials                                                   +48  [NEW]
   +13%    +449 src/core/lib/security/security_connector/ssl/ssl_security_connector.cc                  +449   +13%
      [NEW]    +668 (anonymous namespace)::grpc_ssl_server_security_connector::add_handshakers              +668  [NEW]
      [NEW]    +615 (anonymous namespace)::grpc_ssl_channel_security_connector::check_peer                  +615  [NEW]
      +104%    +497 grpc_ssl_server_security_connector_create                                               +497  +104%
      [NEW]    +213 (anonymous namespace)::grpc_ssl_channel_security_connector::check_call_host             +213  [NEW]
      [NEW]    +171 (anonymous namespace)::grpc_ssl_channel_security_connector::add_handshakers             +171  [NEW]
       +23%    +141 grpc_ssl_channel_security_connector_create                                              +141   +23%
      [NEW]    +111 (anonymous namespace)::grpc_ssl_channel_security_connector::cmp(grpc_security_connec    +111  [NEW]
      [NEW]     +75 (anonymous namespace)::grpc_ssl_server_security_connector::check_peer                    +75  [NEW]
      [NEW]     +60 (anonymous namespace)::grpc_ssl_channel_security_connector::~grpc_ssl_channel_securi     +60  [NEW]
      [NEW]     +36 (anonymous namespace)::grpc_ssl_server_security_connector::~grpc_ssl_server_security     +36  [NEW]
      [NEW]     +32 (anonymous namespace)::grpc_ssl_server_security_connector::~grpc_ssl_server_security     +32  [NEW]
      [NEW]     +24 (anonymous namespace)::grpc_ssl_channel_security_connector::cancel_check_call_host       +24  [NEW]
      [NEW]     +14 (anonymous namespace)::grpc_ssl_channel_security_connector::~grpc_ssl_channel_securi     +14  [NEW]
      [NEW]      +5 (anonymous namespace)::grpc_ssl_server_security_connector::cmp(grpc_security_connect      +5  [NEW]
  +107%    +445 src/core/lib/security/credentials/alts/alts_credentials.cc                              +445  +107%
      [NEW]    +135 grpc_alts_server_credentials::grpc_alts_server_credentials                              +135  [NEW]
      [NEW]    +111 grpc_alts_credentials::grpc_alts_credentials                                            +111  [NEW]
      [NEW]     +82 grpc_alts_server_credentials::~grpc_alts_server_credentials                              +82  [NEW]
      [NEW]     +78 grpc_server_credentials::create_security_connector                                       +78  [NEW]
      [NEW]     +43 grpc_server_credentials::~grpc_server_credentials                                        +43  [NEW]
      [NEW]     +42 grpc_server_credentials::~grpc_server_credentials                                        +42  [NEW]
      [NEW]     +37 grpc_alts_credentials::~grpc_alts_credentials                                            +37  [NEW]
       +33%     +21 [Unmapped]                                                                               +21   +33%
      [NEW]     +14 grpc_alts_credentials::~grpc_alts_credentials                                            +14  [NEW]
      [NEW]     +14 grpc_alts_server_credentials::~grpc_alts_server_credentials                              +14  [NEW]
      [NEW]     +10 grpc_channel_credentials::duplicate_without_call_credentials                             +10  [NEW]
      [NEW]      +8 grpc_alts_credentials::create_security_connector                                          +8  [NEW]
      [NEW]      +5 grpc_alts_server_credentials::create_security_connector                                   +5  [NEW]
   +11%    +381 src/core/lib/security/context/security_context.cc                                       +381   +11%
      [NEW]    +114 grpc_auth_context::~grpc_auth_context                                                   +114  [NEW]
      [NEW]    +112 grpc_auth_context::add_property                                                         +112  [NEW]
      +186%     +93 grpc_client_security_context::~grpc_client_security_context                              +93  +186%
      [NEW]     +82 grpc_auth_context::add_cstring_property                                                  +82  [NEW]
       +96%     +67 grpc_auth_context_create                                                                 +67   +96%
      [NEW]     +62 grpc_auth_context::ensure_capacity                                                       +62  [NEW]
      [NEW]     +59 grpc_client_security_context_create                                                      +59  [NEW]
       +11%     +55 grpc_call_set_credentials                                                                +55   +11%
       +95%     +40 grpc_server_security_context::~grpc_server_security_context                              +40   +95%
      +580%     +29 auth_context_pointer_arg_destroy                                                         +29  +580%
       +48%     +29 grpc_auth_context_release                                                                +29   +48%
      +220%     +11 auth_context_pointer_arg_copy                                                            +11  +220%
      +8.5%     +11 grpc_call_auth_context                                                                   +11  +8.5%
      [NEW]      +9 grpc_call_credentials::~grpc_call_credentials                                             +9  [NEW]
      [NEW]      +2 grpc_call_credentials::~grpc_call_credentials                                             +2  [NEW]
   +12%    +336 src/core/lib/security/credentials/google_default/google_default_credentials.cc          +336   +12%
      [NEW]    +216 grpc_google_default_channel_credentials::create_security_connector                      +216  [NEW]
       +15%    +152 grpc_google_default_credentials_create                                                  +152   +15%
      [NEW]    +115 grpc_google_default_channel_credentials::~grpc_google_default_channel_credentials       +115  [NEW]
      [NEW]     +64 grpc_google_default_channel_credentials::grpc_google_default_channel_credentials         +64  [NEW]
       +29%     +14 [Unmapped]                                                                               +14   +29%
      [NEW]     +14 grpc_google_default_channel_credentials::~grpc_google_default_channel_credentials        +14  [NEW]
  +8.8%    +298 src/core/lib/security/transport/client_auth_filter.cc                                   +298  +8.8%
      +250%     +70 destroy_channel_elem                                                                     +70  +250%
       +73%     +57 destroy_call_elem                                                                        +57   +73%
       +83%     +54 grpc_auth_metadata_context_reset                                                         +54   +83%
      +6.7%     +42 auth_start_transport_stream_op_batch                                                     +42  +6.7%
       +56%     +27 [Unmapped]                                                                               +27   +56%
      +2.0%     +16 on_host_checked                                                                          +16  +2.0%
       +22%     +16 cancel_get_request_metadata                                                              +16   +22%
      +1.7%      +8 grpc_auth_metadata_context_build                                                          +8  +1.7%
       +11%      +8 cancel_check_call_host                                                                    +8   +11%
  +5.3%    +263 src/core/lib/security/credentials/oauth2/oauth2_credentials.cc                          +263  +5.3%
      [NEW]    +528 grpc_oauth2_token_fetcher_credentials::on_http_response                                 +528  [NEW]
      [NEW]    +418 grpc_google_refresh_token_credentials::fetch_oauth2                                     +418  [NEW]
      [NEW]    +387 grpc_oauth2_token_fetcher_credentials::get_request_metadata                             +387  [NEW]
      [NEW]    +367 grpc_access_token_credentials::grpc_access_token_credentials                            +367  [NEW]
      [NEW]    +309 (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials::fetch_oauth2      +309  [NEW]
      [NEW]    +225 grpc_oauth2_token_fetcher_credentials::cancel_get_request_metadata                      +225  [NEW]
      [NEW]    +112 grpc_oauth2_token_fetcher_credentials::grpc_oauth2_token_fetcher_credentials            +112  [NEW]
      [NEW]     +63 grpc_oauth2_token_fetcher_credentials::~grpc_oauth2_token_fetcher_credentials            +63  [NEW]
      [NEW]     +51 grpc_google_refresh_token_credentials::grpc_google_refresh_token_credentials             +51  [NEW]
      [NEW]     +40 grpc_google_refresh_token_credentials::~grpc_google_refresh_token_credentials            +40  [NEW]
       +22%     +37 [Unmapped]                                                                               +37   +22%
      [NEW]     +26 grpc_access_token_credentials::get_request_metadata                                      +26  [NEW]
      [NEW]     +24 (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials::~grpc_compute_     +24  [NEW]
      [NEW]     +24 grpc_access_token_credentials::cancel_get_request_metadata                               +24  [NEW]
      [NEW]     +23 grpc_access_token_credentials::~grpc_access_token_credentials                            +23  [NEW]
      +9.9%     +16 grpc_google_compute_engine_credentials_create                                            +16  +9.9%
      [NEW]     +15 (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials::~grpc_compute_     +15  [NEW]
      [NEW]     +14 grpc_access_token_credentials::~grpc_access_token_credentials                            +14  [NEW]
      [NEW]     +14 grpc_google_refresh_token_credentials::~grpc_google_refresh_token_credentials            +14  [NEW]
      [NEW]     +14 grpc_oauth2_token_fetcher_credentials::~grpc_oauth2_token_fetcher_credentials            +14  [NEW]
      +6.6%      +8 [Other]                                                                                   +8  +6.6%
  +9.8%    +256 src/core/lib/security/credentials/ssl/ssl_credentials.cc                                +256  +9.8%
      [NEW]    +341 grpc_ssl_credentials::create_security_connector                                         +341  [NEW]
      [NEW]    +299 grpc_ssl_credentials::build_config                                                      +299  [NEW]
      [NEW]    +116 grpc_ssl_server_credentials::grpc_ssl_server_credentials                                +116  [NEW]
      [NEW]     +82 grpc_ssl_server_credentials::~grpc_ssl_server_credentials                                +82  [NEW]
      [NEW]     +66 grpc_ssl_credentials::~grpc_ssl_credentials                                              +66  [NEW]
      [NEW]     +60 grpc_ssl_server_credentials::build_config                                                +60  [NEW]
      [NEW]     +38 grpc_ssl_credentials::grpc_ssl_credentials                                               +38  [NEW]
       +20%     +30 [Unmapped]                                                                               +30   +20%
      [NEW]     +14 grpc_ssl_credentials::~grpc_ssl_credentials                                              +14  [NEW]
      [NEW]     +14 grpc_ssl_server_credentials::~grpc_ssl_server_credentials                                +14  [NEW]
      +2.3%      +8 grpc_ssl_server_certificate_config_create                                                 +8  +2.3%
      [NEW]      +5 grpc_ssl_server_credentials::create_security_connector                                    +5  [NEW]
   +11%    +240 src/core/lib/security/credentials/composite/composite_credentials.cc                    +240   +11%
      [NEW]    +285 grpc_composite_call_credentials::get_request_metadata                                   +285  [NEW]
      [NEW]    +234 grpc_composite_call_credentials::grpc_composite_call_credentials                        +234  [NEW]
      [NEW]    +226 grpc_composite_channel_credentials::create_security_connector                           +226  [NEW]
      [NEW]    +150 grpc_composite_call_credentials::cancel_get_request_metadata                            +150  [NEW]
      [NEW]    +110 grpc_composite_channel_credentials::~grpc_composite_channel_credentials                 +110  [NEW]
      [NEW]    +101 grpc_composite_call_credentials::~grpc_composite_call_credentials                       +101  [NEW]
      [NEW]     +14 grpc_composite_call_credentials::~grpc_composite_call_credentials                        +14  [NEW]
      [NEW]     +14 grpc_composite_channel_credentials::~grpc_composite_channel_credentials                  +14  [NEW]
       +15%     +13 [Unmapped]                                                                               +13   +15%
      [NEW]     +11 grpc_composite_channel_credentials::duplicate_without_call_credentials                   +11  [NEW]
      +0.5%      +1 composite_call_metadata_cb                                                                +1  +0.5%
  +4.1%    +179 [Other]                                                                                 +179  +4.1%
   +29%    +170 src/core/lib/security/credentials/fake/fake_credentials.cc                              +170   +29%
      [NEW]     +68 grpc_md_only_test_credentials::get_request_metadata                                      +68  [NEW]
      [NEW]     +43 (anonymous namespace)::grpc_fake_server_credentials::~grpc_fake_server_credentials       +43  [NEW]
      [NEW]     +42 (anonymous namespace)::grpc_fake_server_credentials::~grpc_fake_server_credentials       +42  [NEW]
      [NEW]     +32 grpc_md_only_test_credentials::~grpc_md_only_test_credentials                            +32  [NEW]
      [NEW]     +24 grpc_md_only_test_credentials::cancel_get_request_metadata                               +24  [NEW]
      [NEW]     +23 grpc_md_only_test_credentials::~grpc_md_only_test_credentials                            +23  [NEW]
       +29%     +18 [Unmapped]                                                                               +18   +29%
      [NEW]     +16 (anonymous namespace)::grpc_fake_server_credentials::create_security_connector           +16  [NEW]
      [NEW]     +16 (anonymous namespace)::grpc_fake_channel_credentials::create_security_connector          +16  [NEW]
      [NEW]      +9 (anonymous namespace)::grpc_fake_channel_credentials::~grpc_fake_channel_credentials      +9  [NEW]
       +12%      +8 grpc_fake_transport_security_server_credentials_create                                    +8   +12%
      +1.8%      +3 grpc_md_only_test_credentials_create                                                      +3  +1.8%
      [NEW]      +2 (anonymous namespace)::grpc_fake_channel_credentials::~grpc_fake_channel_credentials      +2  [NEW]
  +9.6%    +160 src/core/lib/security/credentials/jwt/jwt_credentials.cc                                +160  +9.6%
      [NEW]    +599 grpc_service_account_jwt_access_credentials::get_request_metadata                       +599  [NEW]
      [NEW]    +215 grpc_service_account_jwt_access_credentials::grpc_service_account_jwt_access_credent    +215  [NEW]
      [NEW]     +63 grpc_service_account_jwt_access_credentials::reset_cache                                 +63  [NEW]
      [NEW]     +46 grpc_service_account_jwt_access_credentials::~grpc_service_account_jwt_access_creden     +46  [NEW]
      [NEW]     +24 grpc_service_account_jwt_access_credentials::cancel_get_request_metadata                 +24  [NEW]
      [NEW]     +14 grpc_service_account_jwt_access_credentials::~grpc_service_account_jwt_access_creden     +14  [NEW]
       +35%     +12 [Unmapped]                                                                               +12   +35%
  +4.9%    +134 src/core/lib/security/transport/server_auth_filter.cc                                   +134  +4.9%
      +522%    +120 destroy_channel_elem                                                                    +120  +522%
      +3.9%      +8 init_call_elem                                                                            +8  +3.9%
      +6.5%      +6 [Unmapped]                                                                                +6  +6.5%
   +58%    +123 src/core/lib/security/credentials/local/local_credentials.cc                            +123   +58%
      [NEW]     +61 grpc_local_server_credentials::grpc_local_server_credentials                             +61  [NEW]
      [NEW]     +43 grpc_local_server_credentials::~grpc_local_server_credentials                            +43  [NEW]
      [NEW]     +42 grpc_local_server_credentials::~grpc_local_server_credentials                            +42  [NEW]
      [NEW]     +37 grpc_local_credentials::grpc_local_credentials                                           +37  [NEW]
      [NEW]     +14 grpc_local_credentials::create_security_connector                                        +14  [NEW]
      [NEW]      +9 grpc_local_credentials::~grpc_local_credentials                                           +9  [NEW]
      [NEW]      +5 grpc_local_server_credentials::create_security_connector                                  +5  [NEW]
      [NEW]      +2 grpc_local_credentials::~grpc_local_credentials                                           +2  [NEW]
  +4.5%    +113 src/core/lib/security/security_connector/fake/fake_security_connector.cc                +113  +4.5%
      [NEW]    +934 (anonymous namespace)::grpc_fake_channel_security_connector::check_peer                 +934  [NEW]
      [NEW]    +572 (anonymous namespace)::fake_check_peer(grpc_security_connector*, tsi_peer, grpc_auth    +572  [NEW]
      [NEW]    +386 (anonymous namespace)::grpc_fake_channel_security_connector::check_call_host            +386  [NEW]
      [NEW]    +108 (anonymous namespace)::grpc_fake_channel_security_connector::cmp(grpc_security_conne    +108  [NEW]
      [NEW]     +55 (anonymous namespace)::grpc_fake_channel_security_connector::~grpc_fake_channel_secu     +55  [NEW]
      [NEW]     +50 (anonymous namespace)::grpc_fake_channel_security_connector::add_handshakers             +50  [NEW]
      [NEW]     +47 (anonymous namespace)::grpc_fake_server_security_connector::add_handshakers              +47  [NEW]
      [NEW]     +24 (anonymous namespace)::grpc_fake_server_security_connector::~grpc_fake_server_securi     +24  [NEW]
      [NEW]     +24 (anonymous namespace)::grpc_fake_channel_security_connector::cancel_check_call_host      +24  [NEW]
      [NEW]     +20 (anonymous namespace)::grpc_fake_server_security_connector::check_peer                   +20  [NEW]
      [NEW]     +15 (anonymous namespace)::grpc_fake_server_security_connector::~grpc_fake_server_securi     +15  [NEW]
      [NEW]     +14 (anonymous namespace)::grpc_fake_channel_security_connector::~grpc_fake_channel_secu     +14  [NEW]
      [NEW]      +5 (anonymous namespace)::grpc_fake_server_security_connector::cmp(grpc_security_connec      +5  [NEW]
   +14%    +112 src/core/lib/security/credentials/iam/iam_credentials.cc                                +112   +14%
      [NEW]    +241 grpc_google_iam_credentials::grpc_google_iam_credentials                                +241  [NEW]
      [NEW]     +26 grpc_google_iam_credentials::get_request_metadata                                        +26  [NEW]
      [NEW]     +24 grpc_google_iam_credentials::cancel_get_request_metadata                                 +24  [NEW]
      [NEW]     +24 grpc_google_iam_credentials::~grpc_google_iam_credentials                                +24  [NEW]
       +86%     +18 [Unmapped]                                                                               +18   +86%
      [NEW]     +14 grpc_google_iam_credentials::~grpc_google_iam_credentials                                +14  [NEW]
  +2.7%    +112 src/core/lib/security/transport/security_handshaker.cc                                  +112  +2.7%
       +54%     +76 security_handshaker_unref                                                                +76   +54%
       +57%     +23 client_handshaker_factory_add_handshakers                                                +23   +57%
       +57%     +23 server_handshaker_factory_add_handshakers                                                +23   +57%
      +0.5%      +1 check_peer_locked                                                                         +1  +0.5%
  +3.8%     +96 src/core/lib/security/credentials/plugin/plugin_credentials.cc                           +96  +3.8%
      [NEW]    +700 grpc_plugin_credentials::get_request_metadata                                           +700  [NEW]
      [NEW]    +546 process_plugin_result(grpc_plugin_credentials_pending_request*, grpc_metadata const*    +546  [NEW]
      [NEW]    +266 grpc_plugin_credentials::cancel_get_request_metadata                                    +266  [NEW]
      [NEW]     +84 grpc_plugin_credentials::pending_request_complete                                        +84  [NEW]
      [NEW]     +69 grpc_plugin_credentials::grpc_plugin_credentials                                         +69  [NEW]
      [NEW]     +58 grpc_plugin_credentials::~grpc_plugin_credentials                                        +58  [NEW]
      [NEW]     +46 grpc_plugin_credentials::pending_request_remove_locked                                   +46  [NEW]
       +45%     +19 [Unmapped]                                                                               +19   +45%
      +3.1%     +16 plugin_md_request_metadata_ready                                                         +16  +3.1%
      [NEW]     +14 grpc_plugin_credentials::~grpc_plugin_credentials                                        +14  [NEW]
  +7.5%     +94 src/core/lib/http/httpcli_security_connector.cc                                          +94  +7.5%
      [NEW]    +279 grpc_httpcli_ssl_channel_security_connector::check_peer                                 +279  [NEW]
      [NEW]    +160 grpc_httpcli_ssl_channel_security_connector::add_handshakers                            +160  [NEW]
       +11%     +64 ssl_handshake                                                                            +64   +11%
      [NEW]     +55 grpc_httpcli_ssl_channel_security_connector::~grpc_httpcli_ssl_channel_security_conn     +55  [NEW]
      [NEW]     +24 grpc_httpcli_ssl_channel_security_connector::cancel_check_call_host                      +24  [NEW]
      [NEW]     +14 grpc_httpcli_ssl_channel_security_connector::~grpc_httpcli_ssl_channel_security_conn     +14  [NEW]
      [NEW]     +13 grpc_httpcli_ssl_channel_security_connector::check_call_host                             +13  [NEW]
      [NEW]     +13 grpc_httpcli_ssl_channel_security_connector::cmp(grpc_security_connector const*) con     +13  [NEW]
  +6.5%     +92 src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb_channel_secure.cc            +92  +6.5%
      +7.4%     +92 grpc_lb_policy_grpclb_modify_lb_channel_args                                             +92  +7.4%
  +7.3%     +92 src/core/ext/filters/client_channel/lb_policy/xds/xds_channel_secure.cc                  +92  +7.3%
      +7.4%     +92 grpc_lb_policy_xds_modify_lb_channel_args                                                +92  +7.4%

 -------------- SHRINKING                                                                            --------------
  -5.6%    -133 src/core/lib/security/credentials/credentials.cc                                        -133  -5.6%
     -47.4%    -109 [Unmapped]                                                                              -109 -47.4%
      [DEL]    -109 grpc_channel_credentials_create_security_connector                                      -109  [DEL]
     -83.5%     -96 grpc_server_credentials_set_auth_metadata_processor                                      -96 -83.5%
      [DEL]     -82 grpc_server_credentials_unref                                                            -82  [DEL]
      [DEL]     -69 grpc_server_credentials_create_security_connector                                        -69  [DEL]
      [DEL]     -58 grpc_call_credentials_unref                                                              -58  [DEL]
      [DEL]     -58 grpc_channel_credentials_unref                                                           -58  [DEL]
      [DEL]     -37 grpc_channel_credentials_duplicate_without_call_credentials                              -37  [DEL]
      [DEL]     -30 grpc_call_credentials_get_request_metadata                                               -30  [DEL]
      [DEL]     -26 grpc_call_credentials_cancel_get_request_metadata                                        -26  [DEL]
      [DEL]     -23 grpc_call_credentials_ref                                                                -23  [DEL]
      [DEL]     -23 grpc_server_credentials_ref                                                              -23  [DEL]
      [DEL]     -23 grpc_channel_credentials_ref                                                             -23  [DEL]
     -30.2%     -13 grpc_credentials_metadata_request_create                                                 -13 -30.2%
     -60.0%      -3 server_credentials_pointer_arg_copy                                                       -3 -60.0%
  -5.7%     -96 src/core/lib/security/security_connector/local/local_security_connector.cc               -96  -5.7%
      [DEL]    -352 local_check_peer                                                                        -352  [DEL]
      [DEL]    -152 local_channel_add_handshakers                                                           -152  [DEL]
      [DEL]    -144 local_check_call_host                                                                   -144  [DEL]
      [DEL]    -144 local_server_add_handshakers                                                            -144  [DEL]
     -14.8%     -64 grpc_local_channel_security_connector_create                                             -64 -14.8%
      [DEL]     -55 local_channel_cmp                                                                        -55  [DEL]
      [DEL]     -50 local_channel_destroy                                                                    -50  [DEL]
     -21.3%     -48 grpc_local_server_security_connector_create                                              -48 -21.3%
      [DEL]     -34 local_server_destroy                                                                     -34  [DEL]
      [DEL]     -24 local_cancel_check_call_host                                                             -24  [DEL]
      [DEL]      -5 local_server_cmp                                                                          -5  [DEL]
      -3.1%      -2 [Unmapped]                                                                                -2  -3.1%
  -1.8%     -40 src/core/lib/security/security_connector/alts/alts_security_connector.cc                 -40  -1.8%
      [DEL]    -199 alts_check_peer                                                                         -199  [DEL]
      [DEL]    -176 alts_channel_add_handshakers                                                            -176  [DEL]
      [DEL]    -168 alts_server_add_handshakers                                                             -168  [DEL]
      [DEL]    -144 alts_check_call_host                                                                    -144  [DEL]
     -27.0%     -64 grpc_alts_channel_security_connector_create                                              -64 -27.0%
      [DEL]     -55 alts_channel_cmp                                                                         -55  [DEL]
      [DEL]     -50 alts_channel_destroy                                                                     -50  [DEL]
      [DEL]     -38 alts_set_rpc_protocol_versions                                                           -38  [DEL]
      [DEL]     -34 alts_server_destroy                                                                      -34  [DEL]
     -15.7%     -24 grpc_alts_server_security_connector_create                                               -24 -15.7%
      [DEL]     -24 alts_cancel_check_call_host                                                              -24  [DEL]
      [DEL]      -5 alts_server_cmp                                                                           -5  [DEL]

  +1.5% +23.3Ki TOTAL                                                                                 +367Ki  +3.3%


****************************************************************

libgrpc++.so

     VM SIZE                                                                                            FILE SIZE
 ++++++++++++++ GROWING                                                                              ++++++++++++++
  +0.2%    +540 [None]                                                                               +15.8Ki  +0.2%
      +0.2%    +524 [Unmapped]                                                                           +15.8Ki  +0.2%
       +13%     +16 [None]                                                                                     0  [ = ]
  +5.6%    +412 src/cpp/client/secure_credentials.cc                                                    +412  +5.6%
      [NEW]    +200 void std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >    +200  [NEW]
      +208%     +75 grpc::SecureCallCredentials::~SecureCallCredentials                                      +75  +208%
      +208%     +75 grpc::SecureChannelCredentials::~SecureChannelCredentials                                +75  +208%
      +105%     +61 std::_Sp_counted_ptr<grpc::SecureCallCredentials*, (__gnu_cxx::_Lock_policy)2>::_M_d     +61  +105%
      +105%     +61 std::_Sp_counted_ptr<grpc::SecureChannelCredentials*, (__gnu_cxx::_Lock_policy)2>::_     +61  +105%
      +134%     +59 grpc::SecureCallCredentials::~SecureCallCredentials                                      +59  +134%
      +134%     +59 grpc::SecureChannelCredentials::~SecureChannelCredentials                                +59  +134%
      [NEW]      +9 grpc_call_credentials::~grpc_call_credentials                                             +9  [NEW]
      [NEW]      +9 grpc_channel_credentials::~grpc_channel_credentials                                       +9  [NEW]
      +4.1%      +8 grpc::(anonymous namespace)::WrapCallCredentials                                          +8  +4.1%
      +4.1%      +8 grpc::(anonymous namespace)::WrapChannelCredentials                                       +8  +4.1%
      [NEW]      +2 grpc_call_credentials::~grpc_call_credentials                                             +2  [NEW]
      [NEW]      +2 grpc_channel_credentials::~grpc_channel_credentials                                       +2  [NEW]

  +0.2%    +952 TOTAL                                                                                +16.2Ki  +0.2%



@grpc-testing
Copy link

[trickle] No significant performance differences

@grpc-testing
Copy link

Objective-C binary sizes
*****************STATIC******************
  New size                      Old size
 2,022,189      Total (>)      2,021,646

 No significant differences in binary sizes

***************FRAMEWORKS****************
  New size                      Old size
 4,041,722       Core (>)      3,971,198

11,248,455      Total (>)     11,177,936


@grpc-testing
Copy link

Corrupt JSON data (indicates timeout or crash): 
    bm_call_create.BM_IsolatedFilter_ClientChannelFilter_NoOp_.counters.new: 10
    bm_call_create.BM_IsolatedFilter_ClientChannelFilter_NoOp_.counters.old: 10


[microbenchmarks] No significant performance differences

@grpc-testing
Copy link

Objective-C binary sizes
*****************STATIC******************
  New size                      Old size
 2,022,297      Total (>)      2,021,646

 No significant differences in binary sizes

***************FRAMEWORKS****************
  New size                      Old size
 4,060,150       Core (>)      3,971,198

11,266,881      Total (>)     11,177,931


@grpc-testing
Copy link

Corrupt JSON data (indicates timeout or crash): 
    bm_call_create.BM_IsolatedFilter_ClientChannelFilter_NoOp_.counters.new: 10
    bm_call_create.BM_IsolatedFilter_ClientChannelFilter_NoOp_.counters.old: 10


[microbenchmarks] No significant performance differences

@grpc-testing
Copy link

Objective-C binary sizes
*****************STATIC******************
  New size                      Old size
   733,738       Core (>)        732,604

 2,022,892      Total (>)      2,021,646

***************FRAMEWORKS****************
  New size                      Old size
 4,062,554       Core (>)      3,971,198

11,269,293      Total (>)     11,177,940


@grpc-testing
Copy link

Corrupt JSON data (indicates timeout or crash): 
    bm_call_create.BM_IsolatedFilter_ClientChannelFilter_NoOp_.counters.new: 10
    bm_call_create.BM_IsolatedFilter_ClientChannelFilter_NoOp_.counters.old: 10


[microbenchmarks] No significant performance differences

Copy link
Member

@markdroth markdroth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for doing this!

My main structural comment is that I think we can actually use RefCountedPtr by having a thin C wrapper around the C++ implementation for the public API. The C++ implementation would use RefCountedPtr while the C wrapper would not expose that fact.

This definitely needs review from @jiangtaoli2016 and/or @yihuazhang, since their team owns the security code.

Please let me know if you have any questions or concerns. Thanks!

Reviewed 46 of 46 files at r1.
Reviewable status: all files reviewed, 22 unresolved discussions (waiting on @soheilhy, @jiangtaoli2016, @AspirinSJL, @yashykt, @ncteisen, @vjpai, and @apolcyn)


src/core/lib/security/context/security_context.h, line 64 at r1 (raw file):

// This type is forward declared as a C struct and we cannot define it as a
// class. Otherwise, compiler will complain about type mismatch due to

I think a better way to address this would be to have the real implementation be a full-fledged C++ class called GprcAuthContext, and then have a thin C wrapper called grpc_auth_context. This would allow us to use RefCountedPtr.

Same thing for most of the classes in this PR.


src/core/lib/security/context/security_context.h, line 69 at r1 (raw file):

 public:
  explicit grpc_auth_context(grpc_auth_context* chained = nullptr)
      : chained_(chained ? GRPC_AUTH_CONTEXT_REF(chained, "chained")

Nit: Prefer != nullptr to make it clear to the reader that it's a pointer and not a bool.


src/core/lib/security/context/security_context.h, line 127 at r1 (raw file):

inline grpc_auth_context* grpc_auth_context_ref(grpc_auth_context* policy) {
  return policy ? policy->Ref() : nullptr;

!= nullptr


src/core/lib/security/context/security_context.h, line 130 at r1 (raw file):

}
inline void grpc_auth_context_unref(grpc_auth_context* policy) {
  if (policy) policy->Unref();

!= nullptr


src/core/lib/security/context/security_context.h, line 148 at r1 (raw file):

struct grpc_client_security_context {
  grpc_client_security_context(grpc_call_credentials* creds)

explicit


src/core/lib/security/context/security_context.h, line 149 at r1 (raw file):

struct grpc_client_security_context {
  grpc_client_security_context(grpc_call_credentials* creds)
      : creds(creds ? creds->Ref() : nullptr) {}

creds != nullptr


src/core/lib/security/context/security_context.h, line 153 at r1 (raw file):

  void set_creds(grpc_call_credentials* creds) {
    if (this->creds) this->creds->Unref();

!= nullptr


src/core/lib/security/context/security_context.h, line 154 at r1 (raw file):

  void set_creds(grpc_call_credentials* creds) {
    if (this->creds) this->creds->Unref();
    this->creds = creds ? creds->Ref() : nullptr;

creds != nullptr


src/core/lib/security/context/security_context.cc, line 83 at r1 (raw file):

/* --- grpc_client_security_context --- */
grpc_client_security_context::~grpc_client_security_context() {
  if (creds) creds->Unref();

!= nullptr

I'll stop noting these in each individual place, but please fix throughout this PR.


src/core/lib/security/credentials/credentials.h, line 99 at r1 (raw file):

struct grpc_channel_credentials {
 public:
  grpc_channel_credentials(const char* type) : type_(type) {}

explicit


src/core/lib/security/credentials/credentials.h, line 174 at r1 (raw file):

struct grpc_call_credentials {
 public:
  grpc_call_credentials(const char* type) : type_(type) {}

explicit


src/core/lib/security/credentials/credentials.h, line 245 at r1 (raw file):

  const char* type() const { return type_; }

  const grpc_auth_metadata_processor& processor() const { return processor_; }

Please call these methods auth_metadata_processor() and set_auth_metadata_processor().


src/core/lib/security/credentials/credentials.h, line 273 at r1 (raw file):

struct grpc_credentials_metadata_request {
  grpc_credentials_metadata_request(grpc_call_credentials* creds)

explicit


src/core/lib/security/credentials/alts/alts_credentials.h, line 30 at r1 (raw file):

/* Main struct for grpc ALTS channel credential. */
class grpc_alts_credentials final : public grpc_channel_credentials {

Please use C++ style for C++ classes (e.g., class names and method names shoulld be MethodName instead of method_name). Also, please move them into the grpc_core namespace.

Same thing throughout.


src/core/lib/security/credentials/oauth2/oauth2_credentials.cc, line 345 at r1 (raw file):

//

// static grpc_call_credentials_vtable compute_engine_vtable = {

I assume this can be removed.


src/core/lib/security/credentials/oauth2/oauth2_credentials.cc, line 497 at r1 (raw file):

}

// static grpc_call_credentials_vtable access_token_vtable = {

Please remove.


src/core/lib/security/credentials/plugin/plugin_credentials.h, line 30 at r1 (raw file):

struct grpc_plugin_credentials;

struct grpc_plugin_credentials_pending_request {

Perhaps this should be nested inside of grpc_plugin_credentials?


src/core/lib/security/security_connector/security_connector.h, line 166 at r1 (raw file):

};

/// A helper function for use in grpc_security_connector_cmp() implementations.

I think this should be the cmp() method (overriding the one from the base class) instead of being a standalone function. Subclasses can override and call the method from the grpc_channel_security_connector class if needed.


src/core/lib/security/security_connector/security_connector.h, line 195 at r1 (raw file):

/// A helper function for use in grpc_security_connector_cmp() implementations.
int grpc_server_security_connector_cmp(

Same comment as above.


src/core/lib/security/security_connector/security_connector.cc, line 73 at r1 (raw file):

    const grpc_channel_security_connector* sc1,
    const grpc_channel_security_connector* sc2) {
  return sc1 == sc2;

I assume this was added for testing? I don't think we want to require identity in comparisons.


src/core/lib/security/security_connector/security_connector.cc, line 91 at r1 (raw file):

  c = GPR_ICMP(sc1->request_metadata_creds, sc2->request_metadata_creds);
  if (c != 0) return c;
  c = GPR_ICMP((void*)sc1->check_call_host, (void*)sc2->check_call_host);

We need some way to make sure that both connector objects are the same type.


src/core/lib/security/security_connector/security_connector.cc, line 105 at r1 (raw file):

  int c = GPR_ICMP(sc1->server_creds, sc2->server_creds);
  if (c != 0) return c;
  return GPR_ICMP((void*)sc1->add_handshakers, (void*)sc2->add_handshakers);

Same here.

@markdroth markdroth added this to Not yet started in Core conversion to idiomatic C++ via automation Nov 27, 2018
@markdroth markdroth moved this from Not yet started to In progress in Core conversion to idiomatic C++ Nov 27, 2018
@jiangtaoli2016
Copy link

per offline discussion with @soheilhy, we could have create_security_connector returns RefCountedPtr rather than grpc_security_status. A nullptr return value indicates creation failure.

Copy link
Contributor Author

@soheilhy soheilhy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the review!

Reviewable status: all files reviewed, 22 unresolved discussions (waiting on @markdroth, @jiangtaoli2016, @yihuazhang, @AspirinSJL, @yashykt, @ncteisen, @vjpai, and @apolcyn)


src/core/lib/security/context/security_context.h, line 64 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

I think a better way to address this would be to have the real implementation be a full-fledged C++ class called GprcAuthContext, and then have a thin C wrapper called grpc_auth_context. This would allow us to use RefCountedPtr.

Same thing for most of the classes in this PR.

Thank you for the review Mark. As discussed offline:

  1. We will keep the C naming style for easier review and smaller diff for this PR. I will rename the types in a follow up CL.
  2. For RefCountedPtr, we don't need a C wrapper. And I will use reset() where needed. Also, we wouldn't be able to changegrpc_auth_contextsince it's leaked in the API.

I'm not sure if the forward decl of the typedef (i.e., struct) is part of the API. If it's not, we can potentially do something like:

typedef struct grpc_t grpc_t
typedef struct GrpcT grpc_t

For the same reason we cannot move these structs into a namespace.


src/core/lib/security/context/security_context.h, line 69 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

Nit: Prefer != nullptr to make it clear to the reader that it's a pointer and not a bool.

sure. done.


src/core/lib/security/context/security_context.h, line 127 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

!= nullptr

this is removed now.


src/core/lib/security/context/security_context.h, line 130 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

!= nullptr

this is removed now.


src/core/lib/security/context/security_context.h, line 148 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

explicit

sure done.


src/core/lib/security/context/security_context.h, line 149 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

creds != nullptr

done.


src/core/lib/security/context/security_context.h, line 153 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

!= nullptr

this is removed now.


src/core/lib/security/context/security_context.h, line 154 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

creds != nullptr

this is removed now.


src/core/lib/security/context/security_context.cc, line 83 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

!= nullptr

I'll stop noting these in each individual place, but please fix throughout this PR.

They are mostly removed now with RefCountedPtr. I tried to change the rest to use == nullptr. apologies if I have missed anything.


src/core/lib/security/credentials/credentials.h, line 99 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

explicit

sure. done.


src/core/lib/security/credentials/credentials.h, line 174 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

explicit

sure done.


src/core/lib/security/credentials/credentials.h, line 245 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

Please call these methods auth_metadata_processor() and set_auth_metadata_processor().

sure changed them. but I feel they are too verbose.


src/core/lib/security/credentials/credentials.h, line 273 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

explicit

sure. done.


src/core/lib/security/credentials/alts/alts_credentials.h, line 30 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

Please use C++ style for C++ classes (e.g., class names and method names shoulld be MethodName instead of method_name). Also, please move them into the grpc_core namespace.

Same thing throughout.

As we discussed offline, this patch is already XXL and changing the names would have made the review significantly harder. Will do those changes and naming fixes once this is merge.


src/core/lib/security/credentials/oauth2/oauth2_credentials.cc, line 345 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

I assume this can be removed.

thank you for catching the commented. removed.


src/core/lib/security/credentials/oauth2/oauth2_credentials.cc, line 497 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

Please remove.

Thanks. removed.


src/core/lib/security/credentials/plugin/plugin_credentials.h, line 30 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

Perhaps this should be nested inside of grpc_plugin_credentials?

sure moved there and called it "pending_request"


src/core/lib/security/security_connector/security_connector.h, line 166 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

I think this should be the cmp() method (overriding the one from the base class) instead of being a standalone function. Subclasses can override and call the method from the grpc_channel_security_connector class if needed.

Sure I moved it there. I kept it hear to make sure every class is implementing a cmp function. now it's not needed.


src/core/lib/security/security_connector/security_connector.h, line 195 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

Same comment as above.

Sure I moved it there. I kept it hear to make sure every class is implementing a cmp function. now it's not needed.


src/core/lib/security/security_connector/security_connector.cc, line 73 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

I assume this was added for testing? I don't think we want to require identity in comparisons.

thank you for catching this. I thought I have removed this one.


src/core/lib/security/security_connector/security_connector.cc, line 91 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

We need some way to make sure that both connector objects are the same type.

I discussed this with Jiangtao and adjusted the implementation. thanks.


src/core/lib/security/security_connector/security_connector.cc, line 105 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

Same here.

thanks please see the comment above.

@soheilhy
Copy link
Contributor Author

Failures so far are #16692 and #17335.

@grpc-testing
Copy link

Objective-C binary sizes
*****************STATIC******************
  New size                      Old size
   737,388       Core (>)        731,780

 2,026,854      Total (>)      2,020,870

***************FRAMEWORKS****************
  New size                      Old size
 4,104,846       Core (>)      3,970,386

11,311,587      Total (>)     11,177,126


@grpc-testing
Copy link

Corrupt JSON data (indicates timeout or crash): 
    bm_call_create.BM_IsolatedFilter_ClientChannelFilter_NoOp_.counters.new: 10
    bm_call_create.BM_IsolatedFilter_ClientChannelFilter_NoOp_.counters.old: 10


[microbenchmarks] No significant performance differences

@soheilhy
Copy link
Contributor Author

Failures so far are #16692, #17335, and #17448.

@grpc-testing
Copy link

****************************************************************

libgrpc.so

     VM SIZE                                                                                            FILE SIZE
 ++++++++++++++ GROWING                                                                              ++++++++++++++
  +2.7% +20.2Ki [None]                                                                               +1.06Mi   +10%
      +2.8% +19.3Ki [Unmapped]                                                                           +1.06Mi   +10%
      [NEW]    +568 [Other]                                                                                 +568  [NEW]
      [NEW]     +72 vtable for grpc_channel_security_connector                                               +72  [NEW]
      [NEW]     +72 vtable for grpc_httpcli_ssl_channel_security_connector                                   +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_ssl_channel_security_connector                    +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_alts_channel_security_connector                   +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_fake_channel_security_connector                   +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_local_channel_security_connector                  +72  [NEW]
      [NEW]     +56 vtable for grpc_server_security_connector                                                +56  [NEW]
      [NEW]     +56 vtable for grpc_google_refresh_token_credentials                                         +56  [NEW]
      [NEW]     +56 vtable for grpc_oauth2_token_fetcher_credentials                                         +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_ssl_server_security_connector                     +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_alts_server_security_connector                    +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_fake_server_security_connector                    +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_local_server_security_connector                   +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials          +56  [NEW]
      [NEW]     +48 vtable for grpc_ssl_credentials                                                          +48  [NEW]
      [NEW]     +48 vtable for grpc_alts_credentials                                                         +48  [NEW]
      [NEW]     +48 vtable for grpc_local_credentials                                                        +48  [NEW]
      [NEW]     +48 vtable for grpc_plugin_credentials                                                       +48  [NEW]
      [NEW]     +48 vtable for grpc_google_iam_credentials                                                   +48  [NEW]
  +382% +15.6Ki src/core/lib/security/transport/security_handshaker.cc                               +15.6Ki  +382%
     +14e2% +3.41Ki on_handshake_data_sent_to_peer                                                       +3.41Ki +14e2%
     +15e2% +3.34Ki on_handshake_data_received_from_peer                                                 +3.34Ki +15e2%
     +17e2% +2.29Ki security_handshaker_do_handshake                                                     +2.29Ki +17e2%
     +18e2% +2.28Ki on_handshake_next_done_grpc_wrapper                                                  +2.28Ki +18e2%
     +45e3% +2.18Ki security_handshaker_destroy                                                          +2.18Ki +45e3%
      +329% +2.17Ki on_peer_checked                                                                      +2.17Ki  +329%
      [NEW]    +544 on_handshake_next_done_locked                                                           +544  [NEW]
      [NEW]    +394 move_read_buffer_into_handshake_buffer                                                  +394  [NEW]
      [NEW]    +323 security_handshake_failed_locked                                                        +323  [NEW]
      [NEW]    +186 check_peer_locked                                                                       +186  [NEW]
      [NEW]    +153 do_handshaker_next_locked                                                               +153  [NEW]
      [NEW]     +69 cleanup_args_for_failure_locked                                                          +69  [NEW]
       +22%     +64 grpc_security_handshaker_create                                                          +64   +22%
       +57%     +23 client_handshaker_factory_add_handshakers                                                +23   +57%
       +57%     +23 server_handshaker_factory_add_handshakers                                                +23   +57%
  +183% +5.99Ki src/core/lib/security/context/security_context.cc                                    +5.99Ki  +183%
     +44e2% +1.81Ki grpc_server_security_context::~grpc_server_security_context                          +1.81Ki +44e2%
     +23e2% +1.33Ki grpc_auth_context_release                                                            +1.33Ki +23e2%
     +27e3% +1.31Ki auth_context_pointer_arg_destroy                                                     +1.31Ki +27e3%
     +21e2% +1.02Ki grpc_client_security_context::~grpc_client_security_context                          +1.02Ki +21e2%
      [NEW]    +454 grpc_auth_context::~grpc_auth_context                                                   +454  [NEW]
      [NEW]    +193 grpc_client_security_context_create                                                     +193  [NEW]
      [NEW]    +112 grpc_auth_context::add_property                                                         +112  [NEW]
      [NEW]     +82 grpc_auth_context::add_cstring_property                                                  +82  [NEW]
      [NEW]     +62 grpc_auth_context::ensure_capacity                                                       +62  [NEW]
       +11%     +55 grpc_call_set_credentials                                                                +55   +11%
      +8.5%     +11 grpc_call_auth_context                                                                   +11  +8.5%
      +200%     +10 auth_context_pointer_arg_copy                                                            +10  +200%
  +173% +5.70Ki src/core/lib/security/transport/client_auth_filter.cc                                +5.70Ki  +173%
      +574% +3.53Ki auth_start_transport_stream_op_batch                                                 +3.53Ki  +574%
     +21e2% +1.34Ki grpc_auth_metadata_context_reset                                                     +1.34Ki +21e2%
     +21e2%    +581 destroy_channel_elem                                                                    +581 +21e2%
       +19%    +155 on_host_checked                                                                         +155   +19%
       +83%     +65 destroy_call_elem                                                                        +65   +83%
       +42%     +20 [Unmapped]                                                                               +20   +42%
       +22%     +16 cancel_get_request_metadata                                                              +16   +22%
      +1.7%      +8 grpc_auth_metadata_context_build                                                          +8  +1.7%
       +11%      +8 cancel_check_call_host                                                                    +8   +11%
  +115% +3.80Ki src/core/lib/security/security_connector/ssl/ssl_security_connector.cc               +3.80Ki  +115%
      [NEW] +2.76Ki (anonymous namespace)::grpc_ssl_channel_security_connector::check_peer               +2.76Ki  [NEW]
      [NEW] +1.12Ki grpc_ssl_server_security_connector_create                                            +1.12Ki  [NEW]
      [NEW] +1.10Ki grpc_ssl_channel_security_connector_create                                           +1.10Ki  [NEW]
      [NEW]    +676 (anonymous namespace)::grpc_ssl_server_security_connector::check_peer                   +676  [NEW]
      [NEW]    +668 (anonymous namespace)::grpc_ssl_server_security_connector::add_handshakers              +668  [NEW]
      [NEW]    +213 (anonymous namespace)::grpc_ssl_channel_security_connector::check_call_host             +213  [NEW]
      [NEW]    +171 (anonymous namespace)::grpc_ssl_channel_security_connector::add_handshakers             +171  [NEW]
      [NEW]    +135 (anonymous namespace)::grpc_ssl_server_security_connector::~grpc_ssl_server_security    +135  [NEW]
      [NEW]    +111 (anonymous namespace)::grpc_ssl_channel_security_connector::cmp(grpc_security_connec    +111  [NEW]
      [NEW]     +60 (anonymous namespace)::grpc_ssl_channel_security_connector::~grpc_ssl_channel_securi     +60  [NEW]
      [NEW]     +24 (anonymous namespace)::grpc_ssl_channel_security_connector::cancel_check_call_host       +24  [NEW]
      [NEW]     +14 (anonymous namespace)::grpc_ssl_server_security_connector::~grpc_ssl_server_security     +14  [NEW]
      [NEW]     +14 (anonymous namespace)::grpc_ssl_channel_security_connector::~grpc_ssl_channel_securi     +14  [NEW]
      [NEW]      +5 (anonymous namespace)::grpc_ssl_server_security_connector::cmp(grpc_security_connect      +5  [NEW]
   +92% +2.45Ki src/core/lib/security/transport/server_auth_filter.cc                                +2.45Ki   +92%
     +86e2% +1.94Ki destroy_channel_elem                                                                 +1.94Ki +86e2%
      +258%    +523 init_call_elem                                                                          +523  +258%
      +1.2%      +2 init_channel_elem                                                                         +2  +1.2%
      +1.1%      +1 [Unmapped]                                                                                +1  +1.1%
   +99% +2.41Ki src/core/lib/security/security_connector/fake/fake_security_connector.cc             +2.41Ki   +99%
      [NEW] +2.16Ki (anonymous namespace)::fake_check_peer(grpc_security_connector*, tsi_peer, grpc_core +2.16Ki  [NEW]
      [NEW]    +934 (anonymous namespace)::grpc_fake_channel_security_connector::check_peer                 +934  [NEW]
      [NEW]    +524 grpc_fake_channel_security_connector_create                                             +524  [NEW]
      [NEW]    +386 (anonymous namespace)::grpc_fake_channel_security_connector::check_call_host            +386  [NEW]
      [NEW]    +332 grpc_fake_server_security_connector_create                                              +332  [NEW]
      [NEW]    +111 (anonymous namespace)::grpc_fake_server_security_connector::~grpc_fake_server_securi    +111  [NEW]
      [NEW]    +108 (anonymous namespace)::grpc_fake_channel_security_connector::cmp(grpc_security_conne    +108  [NEW]
      [NEW]     +55 (anonymous namespace)::grpc_fake_channel_security_connector::~grpc_fake_channel_secu     +55  [NEW]
      [NEW]     +50 (anonymous namespace)::grpc_fake_channel_security_connector::add_handshakers             +50  [NEW]
      [NEW]     +47 (anonymous namespace)::grpc_fake_server_security_connector::add_handshakers              +47  [NEW]
      [NEW]     +37 (anonymous namespace)::grpc_fake_server_security_connector::~grpc_fake_server_securi     +37  [NEW]
      [NEW]     +24 (anonymous namespace)::grpc_fake_channel_security_connector::cancel_check_call_host      +24  [NEW]
      [NEW]     +20 (anonymous namespace)::grpc_fake_server_security_connector::check_peer                   +20  [NEW]
      [NEW]     +14 (anonymous namespace)::grpc_fake_channel_security_connector::~grpc_fake_channel_secu     +14  [NEW]
      [NEW]      +5 (anonymous namespace)::grpc_fake_server_security_connector::cmp(grpc_security_connec      +5  [NEW]
   +79% +1.72Ki src/core/lib/security/security_connector/alts/alts_security_connector.cc             +1.72Ki   +79%
      [NEW]    +886 grpc_core::internal::grpc_alts_auth_context_from_tsi_peer                               +886  [NEW]
      [NEW]    +788 (anonymous namespace)::grpc_alts_channel_security_connector::check_peer                 +788  [NEW]
      [NEW]    +497 grpc_alts_channel_security_connector_create                                             +497  [NEW]
      [NEW]    +412 grpc_alts_server_security_connector_create                                              +412  [NEW]
      [NEW]    +176 (anonymous namespace)::grpc_alts_channel_security_connector::add_handshakers            +176  [NEW]
      [NEW]    +168 (anonymous namespace)::grpc_alts_server_security_connector::add_handshakers             +168  [NEW]
      [NEW]    +139 (anonymous namespace)::grpc_alts_channel_security_connector::check_call_host            +139  [NEW]
      [NEW]    +111 (anonymous namespace)::grpc_alts_server_security_connector::~grpc_alts_server_securi    +111  [NEW]
      [NEW]    +111 grpc_server_security_connector::~grpc_server_security_connector                         +111  [NEW]
      [NEW]     +84 grpc_core::RefCounted<grpc_server_credentials, grpc_core::PolymorphicRefCount>::Unre     +84  [NEW]
      [NEW]     +78 grpc_security_connector::check_peer                                                      +78  [NEW]
      [NEW]     +78 grpc_server_security_connector::add_handshakers                                          +78  [NEW]
      [NEW]     +78 grpc_security_connector::cmp(grpc_security_connector const*) const                       +78  [NEW]
      [NEW]     +55 (anonymous namespace)::grpc_alts_channel_security_connector::cmp(grpc_security_conne     +55  [NEW]
      [NEW]     +38 (anonymous namespace)::alts_set_rpc_protocol_versions                                    +38  [NEW]
      [NEW]     +37 (anonymous namespace)::grpc_alts_server_security_connector::~grpc_alts_server_securi     +37  [NEW]
      [NEW]     +37 grpc_server_security_connector::~grpc_server_security_connector                          +37  [NEW]
      [NEW]     +36 (anonymous namespace)::grpc_alts_channel_security_connector::~grpc_alts_channel_secu     +36  [NEW]
      [NEW]     +32 (anonymous namespace)::grpc_alts_channel_security_connector::~grpc_alts_channel_secu     +32  [NEW]
       +28%     +24 [Other]                                                                                  +24   +28%
      [NEW]     +24 (anonymous namespace)::grpc_alts_channel_security_connector::cancel_check_call_host      +24  [NEW]
   +60% +1.23Ki src/core/lib/security/credentials/composite/composite_credentials.cc                 +1.23Ki   +60%
      [NEW]    +552 grpc_composite_channel_credentials::create_security_connector                           +552  [NEW]
      [NEW]    +384 grpc_composite_call_credentials::grpc_composite_call_credentials                        +384  [NEW]
      [NEW]    +285 grpc_composite_call_credentials::get_request_metadata                                   +285  [NEW]
      [NEW]    +240 grpc_composite_call_credentials::push_to_inner                                          +240  [NEW]
      [NEW]    +203 grpc_call_credentials_array::reserve                                                    +203  [NEW]
      [NEW]    +150 grpc_composite_call_credentials::cancel_get_request_metadata                            +150  [NEW]
      [NEW]    +120 grpc_call_credentials_array::grpc_call_credentials_array                                +120  [NEW]
       +50%    +117 grpc_composite_channel_credentials_create                                               +117   +50%
      [NEW]    +115 grpc_composite_channel_credentials::~grpc_composite_channel_credentials                 +115  [NEW]
      [NEW]    +109 grpc_call_credentials_array::~grpc_call_credentials_array                               +109  [NEW]
      [NEW]     +33 grpc_composite_call_credentials::~grpc_composite_call_credentials                        +33  [NEW]
      [NEW]     +33 grpc_composite_channel_credentials::duplicate_without_call_credentials                   +33  [NEW]
      [NEW]     +24 grpc_composite_call_credentials::~grpc_composite_call_credentials                        +24  [NEW]
      [NEW]     +14 grpc_composite_channel_credentials::~grpc_composite_channel_credentials                  +14  [NEW]
      +0.5%      +1 composite_call_metadata_cb                                                                +1  +0.5%
   +73% +1.19Ki src/core/lib/security/security_connector/local/local_security_connector.cc           +1.19Ki   +73%
      [NEW]    +932 (anonymous namespace)::grpc_local_channel_security_connector::check_peer                +932  [NEW]
      [NEW]    +689 grpc_local_channel_security_connector_create                                            +689  [NEW]
      [NEW]    +454 grpc_local_server_security_connector_create                                             +454  [NEW]
      [NEW]    +152 (anonymous namespace)::grpc_local_channel_security_connector::add_handshakers           +152  [NEW]
      [NEW]    +144 (anonymous namespace)::grpc_local_server_security_connector::add_handshakers            +144  [NEW]
      [NEW]    +139 (anonymous namespace)::grpc_local_channel_security_connector::check_call_host           +139  [NEW]
      [NEW]    +111 (anonymous namespace)::grpc_local_server_security_connector::~grpc_local_server_secu    +111  [NEW]
      [NEW]     +55 (anonymous namespace)::grpc_local_channel_security_connector::cmp(grpc_security_conn     +55  [NEW]
      [NEW]     +37 (anonymous namespace)::grpc_local_server_security_connector::~grpc_local_server_secu     +37  [NEW]
      [NEW]     +36 (anonymous namespace)::grpc_local_channel_security_connector::~grpc_local_channel_se     +36  [NEW]
      [NEW]     +32 (anonymous namespace)::grpc_local_channel_security_connector::~grpc_local_channel_se     +32  [NEW]
       +40%     +26 [Unmapped]                                                                               +26   +40%
      [NEW]     +24 (anonymous namespace)::grpc_local_channel_security_connector::cancel_check_call_host     +24  [NEW]
      [NEW]      +5 (anonymous namespace)::grpc_local_server_security_connector::cmp(grpc_security_conne      +5  [NEW]
   +24%    +913 src/core/lib/security/credentials/google_default/google_default_credentials.cc          +913   +24%
      [NEW] +1.21Ki create_default_creds_from_path                                                       +1.21Ki  [NEW]
      [NEW]    +499 grpc_google_default_channel_credentials::create_security_connector                      +499  [NEW]
       +23%    +416 grpc_google_default_credentials_create                                                  +416   +23%
      [NEW]    +115 grpc_google_default_channel_credentials::~grpc_google_default_channel_credentials       +115  [NEW]
      [NEW]     +14 grpc_google_default_channel_credentials::~grpc_google_default_channel_credentials        +14  [NEW]
       +17%     +11 [Unmapped]                                                                               +11   +17%
  +182%    +752 src/core/lib/security/credentials/alts/alts_credentials.cc                              +752  +182%
      [NEW]    +196 grpc_alts_credentials::create_security_connector                                        +196  [NEW]
      [NEW]    +135 grpc_alts_server_credentials::grpc_alts_server_credentials                              +135  [NEW]
      [NEW]    +119 grpc_alts_server_credentials::create_security_connector                                 +119  [NEW]
      [NEW]    +111 grpc_alts_credentials::grpc_alts_credentials                                            +111  [NEW]
      [NEW]     +82 grpc_alts_server_credentials::~grpc_alts_server_credentials                              +82  [NEW]
      [NEW]     +78 grpc_server_credentials::create_security_connector                                       +78  [NEW]
      [NEW]     +43 grpc_server_credentials::~grpc_server_credentials                                        +43  [NEW]
      [NEW]     +42 grpc_server_credentials::~grpc_server_credentials                                        +42  [NEW]
      [NEW]     +37 grpc_alts_credentials::~grpc_alts_credentials                                            +37  [NEW]
       +37%     +23 [Unmapped]                                                                               +23   +37%
      [NEW]     +14 grpc_alts_credentials::~grpc_alts_credentials                                            +14  [NEW]
      [NEW]     +14 grpc_alts_server_credentials::~grpc_alts_server_credentials                              +14  [NEW]
      [NEW]     +13 grpc_channel_credentials::duplicate_without_call_credentials                             +13  [NEW]
   +11%    +533 src/core/lib/security/credentials/oauth2/oauth2_credentials.cc                          +533   +11%
      [NEW]    +599 grpc_oauth2_token_fetcher_credentials::on_http_response                                 +599  [NEW]
      [NEW]    +496 grpc_oauth2_token_fetcher_credentials::get_request_metadata                             +496  [NEW]
      [NEW]    +418 grpc_google_refresh_token_credentials::fetch_oauth2                                     +418  [NEW]
      [NEW]    +367 grpc_access_token_credentials::grpc_access_token_credentials                            +367  [NEW]
      [NEW]    +309 (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials::fetch_oauth2      +309  [NEW]
      [NEW]    +225 grpc_oauth2_token_fetcher_credentials::cancel_get_request_metadata                      +225  [NEW]
      [NEW]    +112 grpc_oauth2_token_fetcher_credentials::grpc_oauth2_token_fetcher_credentials            +112  [NEW]
      [NEW]     +78 grpc_oauth2_token_fetcher_credentials::fetch_oauth2                                      +78  [NEW]
      [NEW]     +63 grpc_oauth2_token_fetcher_credentials::~grpc_oauth2_token_fetcher_credentials            +63  [NEW]
      [NEW]     +51 grpc_google_refresh_token_credentials::grpc_google_refresh_token_credentials             +51  [NEW]
      [NEW]     +40 grpc_google_refresh_token_credentials::~grpc_google_refresh_token_credentials            +40  [NEW]
       +11%     +36 [Other]                                                                                  +36   +11%
       +16%     +28 [Unmapped]                                                                               +28   +16%
      [NEW]     +26 grpc_access_token_credentials::get_request_metadata                                      +26  [NEW]
      [NEW]     +24 (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials::~grpc_compute_     +24  [NEW]
      [NEW]     +24 grpc_access_token_credentials::cancel_get_request_metadata                               +24  [NEW]
      [NEW]     +23 grpc_access_token_credentials::~grpc_access_token_credentials                            +23  [NEW]
       +17%     +21 grpc_refresh_token_credentials_create_from_auth_refresh_token                            +21   +17%
      +9.9%     +16 grpc_google_compute_engine_credentials_create                                            +16  +9.9%
      [NEW]     +15 (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials::~grpc_compute_     +15  [NEW]
      [NEW]     +14 grpc_access_token_credentials::~grpc_access_token_credentials                            +14  [NEW]
   +20%    +528 src/core/lib/security/credentials/ssl/ssl_credentials.cc                                +528   +20%
      [NEW]    +497 grpc_ssl_credentials::create_security_connector                                         +497  [NEW]
      [NEW]    +299 grpc_ssl_credentials::build_config                                                      +299  [NEW]
      [NEW]    +119 grpc_ssl_server_credentials::create_security_connector                                  +119  [NEW]
      [NEW]    +116 grpc_ssl_server_credentials::grpc_ssl_server_credentials                                +116  [NEW]
      [NEW]     +82 grpc_ssl_server_credentials::~grpc_ssl_server_credentials                                +82  [NEW]
      [NEW]     +66 grpc_ssl_credentials::~grpc_ssl_credentials                                              +66  [NEW]
      [NEW]     +60 grpc_ssl_server_credentials::build_config                                                +60  [NEW]
      [NEW]     +38 grpc_ssl_credentials::grpc_ssl_credentials                                               +38  [NEW]
       +21%     +32 [Unmapped]                                                                               +32   +21%
      [NEW]     +14 grpc_ssl_credentials::~grpc_ssl_credentials                                              +14  [NEW]
      [NEW]     +14 grpc_ssl_server_credentials::~grpc_ssl_server_credentials                                +14  [NEW]
      +2.3%      +8 grpc_ssl_server_certificate_config_create                                                 +8  +2.3%
  +208%    +443 src/core/lib/security/credentials/local/local_credentials.cc                            +443  +208%
      [NEW]    +212 grpc_local_credentials::create_security_connector                                       +212  [NEW]
      [NEW]    +119 grpc_local_server_credentials::create_security_connector                                +119  [NEW]
      [NEW]     +61 grpc_local_server_credentials::grpc_local_server_credentials                             +61  [NEW]
      [NEW]     +43 grpc_local_server_credentials::~grpc_local_server_credentials                            +43  [NEW]
      [NEW]     +42 grpc_local_server_credentials::~grpc_local_server_credentials                            +42  [NEW]
      [NEW]     +37 grpc_local_credentials::grpc_local_credentials                                           +37  [NEW]
      [NEW]      +9 grpc_local_credentials::~grpc_local_credentials                                           +9  [NEW]
      [NEW]      +2 grpc_local_credentials::~grpc_local_credentials                                           +2  [NEW]
   +75%    +442 src/core/lib/security/credentials/fake/fake_credentials.cc                              +442   +75%
      [NEW]    +175 (anonymous namespace)::grpc_fake_channel_credentials::create_security_connector         +175  [NEW]
      [NEW]    +119 (anonymous namespace)::grpc_fake_server_credentials::create_security_connector          +119  [NEW]
      [NEW]     +68 grpc_md_only_test_credentials::get_request_metadata                                      +68  [NEW]
      [NEW]     +43 (anonymous namespace)::grpc_fake_server_credentials::~grpc_fake_server_credentials       +43  [NEW]
      [NEW]     +42 (anonymous namespace)::grpc_fake_server_credentials::~grpc_fake_server_credentials       +42  [NEW]
      [NEW]     +32 grpc_md_only_test_credentials::~grpc_md_only_test_credentials                            +32  [NEW]
       +44%     +28 [Unmapped]                                                                               +28   +44%
      [NEW]     +24 grpc_md_only_test_credentials::cancel_get_request_metadata                               +24  [NEW]
      [NEW]     +23 grpc_md_only_test_credentials::~grpc_md_only_test_credentials                            +23  [NEW]
      [NEW]      +9 (anonymous namespace)::grpc_fake_channel_credentials::~grpc_fake_channel_credentials      +9  [NEW]
       +12%      +8 grpc_fake_transport_security_server_credentials_create                                    +8   +12%
      +1.8%      +3 grpc_md_only_test_credentials_create                                                      +3  +1.8%
      [NEW]      +2 (anonymous namespace)::grpc_fake_channel_credentials::~grpc_fake_channel_credentials      +2  [NEW]
   +32%    +396 src/core/lib/http/httpcli_security_connector.cc                                         +396   +32%
       +59%    +344 ssl_handshake                                                                           +344   +59%
      [NEW]    +279 grpc_httpcli_ssl_channel_security_connector::check_peer                                 +279  [NEW]
      [NEW]    +160 grpc_httpcli_ssl_channel_security_connector::add_handshakers                            +160  [NEW]
      [NEW]     +55 grpc_httpcli_ssl_channel_security_connector::~grpc_httpcli_ssl_channel_security_conn     +55  [NEW]
      [NEW]     +24 grpc_httpcli_ssl_channel_security_connector::cancel_check_call_host                      +24  [NEW]
      [NEW]     +14 grpc_httpcli_ssl_channel_security_connector::~grpc_httpcli_ssl_channel_security_conn     +14  [NEW]
      [NEW]     +13 grpc_httpcli_ssl_channel_security_connector::check_call_host                             +13  [NEW]
      [NEW]     +13 grpc_httpcli_ssl_channel_security_connector::cmp(grpc_security_connector const*) con     +13  [NEW]
      [NEW]      +9 grpc_call_credentials::~grpc_call_credentials                                             +9  [NEW]
      [NEW]      +9 grpc_channel_credentials::~grpc_channel_credentials                                       +9  [NEW]
      [NEW]      +2 grpc_call_credentials::~grpc_call_credentials                                             +2  [NEW]
      [NEW]      +2 grpc_channel_credentials::~grpc_channel_credentials                                       +2  [NEW]
  +3.9%    +328 [Other]                                                                                 +328  +3.9%
  +9.0%    +192 src/core/ext/transport/chttp2/client/secure/secure_channel_create.cc                    +192  +9.0%
       +15%    +193 client_channel_factory_create_subchannel                                                +193   +15%
   +12%    +192 src/core/lib/security/credentials/jwt/jwt_credentials.cc                                +192   +12%
      [NEW]    +599 grpc_service_account_jwt_access_credentials::get_request_metadata                       +599  [NEW]
      [NEW]    +215 grpc_service_account_jwt_access_credentials::grpc_service_account_jwt_access_credent    +215  [NEW]
      [NEW]     +63 grpc_service_account_jwt_access_credentials::reset_cache                                 +63  [NEW]
      [NEW]     +46 grpc_service_account_jwt_access_credentials::~grpc_service_account_jwt_access_creden     +46  [NEW]
      [NEW]     +24 grpc_service_account_jwt_access_credentials::cancel_get_request_metadata                 +24  [NEW]
      +2.5%     +16 grpc_service_account_jwt_access_credentials_create                                       +16  +2.5%
      [NEW]     +14 grpc_service_account_jwt_access_credentials::~grpc_service_account_jwt_access_creden     +14  [NEW]
       +32%     +11 [Unmapped]                                                                               +11   +32%
   +14%    +112 src/core/lib/security/credentials/iam/iam_credentials.cc                                +112   +14%
      [NEW]    +241 grpc_google_iam_credentials::grpc_google_iam_credentials                                +241  [NEW]
      [NEW]     +26 grpc_google_iam_credentials::get_request_metadata                                        +26  [NEW]
      [NEW]     +24 grpc_google_iam_credentials::cancel_get_request_metadata                                 +24  [NEW]
      [NEW]     +24 grpc_google_iam_credentials::~grpc_google_iam_credentials                                +24  [NEW]
       +86%     +18 [Unmapped]                                                                               +18   +86%
      [NEW]     +14 grpc_google_iam_credentials::~grpc_google_iam_credentials                                +14  [NEW]

 -------------- SHRINKING                                                                            --------------
 -11.4%    -272 src/core/lib/security/credentials/credentials.cc                                        -272 -11.4%
     -52.2%    -120 [Unmapped]                                                                              -120 -52.2%
      [DEL]    -109 grpc_channel_credentials_create_security_connector                                      -109  [DEL]
     -83.5%     -96 grpc_server_credentials_set_auth_metadata_processor                                      -96 -83.5%
      [DEL]     -82 grpc_server_credentials_unref                                                            -82  [DEL]
      [DEL]     -69 grpc_server_credentials_create_security_connector                                        -69  [DEL]
      [DEL]     -58 grpc_call_credentials_unref                                                              -58  [DEL]
      [DEL]     -58 grpc_channel_credentials_unref                                                           -58  [DEL]
      [DEL]     -43 grpc_credentials_metadata_request_create                                                 -43  [DEL]
      [DEL]     -37 grpc_channel_credentials_duplicate_without_call_credentials                              -37  [DEL]
      [DEL]     -30 grpc_credentials_metadata_request_destroy                                                -30  [DEL]
      [DEL]     -30 grpc_call_credentials_get_request_metadata                                               -30  [DEL]
      [DEL]     -26 grpc_call_credentials_cancel_get_request_metadata                                        -26  [DEL]
      [DEL]     -23 grpc_call_credentials_ref                                                                -23  [DEL]
      [DEL]     -23 grpc_server_credentials_ref                                                              -23  [DEL]
      [DEL]     -23 grpc_channel_credentials_ref                                                             -23  [DEL]
  -1.1%     -15 src/core/lib/security/security_connector/security_connector.cc                           -15  -1.1%
      [DEL]    -215 grpc_channel_security_connector_cmp                                                     -215  [DEL]
      [DEL]    -186 grpc_security_connector_check_peer                                                      -186  [DEL]
      [DEL]    -167 grpc_server_security_connector_cmp                                                      -167  [DEL]
      [DEL]    -166 grpc_channel_security_connector_check_call_host                                         -166  [DEL]
      [DEL]     -70 grpc_security_connector_cmp                                                              -70  [DEL]
     -36.4%     -51 [Unmapped]                                                                               -51 -36.4%
      [DEL]     -50 grpc_security_connector_unref                                                            -50  [DEL]
      [DEL]     -40 grpc_channel_security_connector_cancel_check_call_host                                   -40  [DEL]
      [DEL]     -23 grpc_security_connector_ref                                                              -23  [DEL]
      [DEL]     -18 grpc_server_security_connector_add_handshakers                                           -18  [DEL]
      [DEL]     -18 grpc_channel_security_connector_add_handshakers                                          -18  [DEL]

  +4.2% +64.7Ki TOTAL                                                                                +1.11Mi   +10%


****************************************************************

libgrpc++.so

     VM SIZE                                                                                            FILE SIZE
 ++++++++++++++ GROWING                                                                              ++++++++++++++
  +0.4% +1.21Ki [None]                                                                                +254Ki  +3.2%
      +0.4% +1.18Ki [Unmapped]                                                                            +254Ki  +3.2%
      [NEW]     +92 typeinfo name for std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocat     +92  [NEW]
      [NEW]     +56 vtable for std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<grpc     +56  [NEW]
       +21%     +24 [None]                                                                                     0  [ = ]
      [NEW]     +24 typeinfo for std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<gr     +24  [NEW]
   +55% +3.97Ki src/cpp/client/secure_credentials.cc                                                 +3.97Ki   +55%
      [NEW] +2.05Ki grpc_core::RefCounted<grpc_auth_context, grpc_core::NonPolymorphicRefCount>::Unref   +2.05Ki  [NEW]
       +70% +1.08Ki grpc::MetadataCredentialsPluginWrapper::InvokePlugin                                 +1.08Ki   +70%
      [NEW]    +454 grpc_auth_context::~grpc_auth_context                                                   +454  [NEW]
      [NEW]    +200 void std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >    +200  [NEW]
      +208%     +75 grpc::SecureCallCredentials::~SecureCallCredentials                                      +75  +208%
      +208%     +75 grpc::SecureChannelCredentials::~SecureChannelCredentials                                +75  +208%
      +105%     +61 std::_Sp_counted_ptr<grpc::SecureCallCredentials*, (__gnu_cxx::_Lock_policy)2>::_M_d     +61  +105%
      +105%     +61 std::_Sp_counted_ptr<grpc::SecureChannelCredentials*, (__gnu_cxx::_Lock_policy)2>::_     +61  +105%
      +134%     +59 grpc::SecureCallCredentials::~SecureCallCredentials                                      +59  +134%
      +134%     +59 grpc::SecureChannelCredentials::~SecureChannelCredentials                                +59  +134%
      [NEW]      +9 grpc_call_credentials::~grpc_call_credentials                                             +9  [NEW]
      [NEW]      +9 grpc_channel_credentials::~grpc_channel_credentials                                       +9  [NEW]
      +4.1%      +8 grpc::(anonymous namespace)::WrapCallCredentials                                          +8  +4.1%
      +4.1%      +8 grpc::(anonymous namespace)::WrapChannelCredentials                                       +8  +4.1%
      [NEW]      +2 grpc_call_credentials::~grpc_call_credentials                                             +2  [NEW]
      [NEW]      +2 grpc_channel_credentials::~grpc_channel_credentials                                       +2  [NEW]
  +158% +2.61Ki src/cpp/common/secure_auth_context.cc                                                +2.61Ki  +158%
     +77e2% +1.36Ki grpc::SecureAuthContext::~SecureAuthContext                                          +1.36Ki +77e2%
     +33e2% +1.31Ki grpc::SecureAuthContext::~SecureAuthContext                                          +1.31Ki +33e2%
      [NEW]    +200 void std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >    +200  [NEW]
  +685% +1.86Ki src/cpp/common/secure_create_auth_context.cc                                         +1.86Ki  +685%
      [NEW] +1.35Ki std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<grpc::SecureAut +1.35Ki  [NEW]
      +249%    +495 grpc::CreateAuthContext                                                                 +495  +249%
      [NEW]     +52 std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<grpc::SecureAut     +52  [NEW]
      [NEW]      +5 std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<grpc::SecureAut      +5  [NEW]
      [NEW]      +5 std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<grpc::SecureAut      +5  [NEW]
      [NEW]      +2 std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<grpc::SecureAut      +2  [NEW]
   +22% +1.14Ki src/cpp/server/secure_server_credentials.cc                                          +1.14Ki   +22%
       +55% +1.16Ki grpc::AuthMetadataProcessorAyncWrapper::InvokeProcessor                              +1.16Ki   +55%

  +1.9% +10.8Ki TOTAL                                                                                 +264Ki  +3.2%



@grpc-testing
Copy link

[trickle] No significant performance differences

@grpc-testing
Copy link

Corrupt JSON data (indicates timeout or crash): 
    bm_call_create.BM_IsolatedFilter_ClientChannelFilter_NoOp_.counters.new: 10
    bm_call_create.BM_IsolatedFilter_ClientChannelFilter_NoOp_.counters.old: 10


[microbenchmarks] No significant performance differences

@grpc-testing
Copy link

Objective-C binary sizes
*****************STATIC******************
  New size                      Old size
   737,388       Core (>)        731,780

 2,026,854      Total (>)      2,020,870

***************FRAMEWORKS****************
  New size                      Old size
 4,105,050       Core (>)      3,970,386

11,311,788      Total (>)     11,177,122


@soheilhy
Copy link
Contributor Author

All the issues are gone now, yay! The failure is known flake #17399

@grpc-testing
Copy link

****************************************************************

libgrpc.so

     VM SIZE                                                                                            FILE SIZE
 ++++++++++++++ GROWING                                                                              ++++++++++++++
  +2.7% +20.2Ki [None]                                                                               +1.06Mi   +10%
      +2.8% +19.3Ki [Unmapped]                                                                           +1.06Mi   +10%
      [NEW]    +568 [Other]                                                                                 +568  [NEW]
      [NEW]     +72 vtable for grpc_channel_security_connector                                               +72  [NEW]
      [NEW]     +72 vtable for grpc_httpcli_ssl_channel_security_connector                                   +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_ssl_channel_security_connector                    +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_alts_channel_security_connector                   +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_fake_channel_security_connector                   +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_local_channel_security_connector                  +72  [NEW]
      [NEW]     +56 vtable for grpc_server_security_connector                                                +56  [NEW]
      [NEW]     +56 vtable for grpc_google_refresh_token_credentials                                         +56  [NEW]
      [NEW]     +56 vtable for grpc_oauth2_token_fetcher_credentials                                         +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_ssl_server_security_connector                     +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_alts_server_security_connector                    +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_fake_server_security_connector                    +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_local_server_security_connector                   +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials          +56  [NEW]
      [NEW]     +48 vtable for grpc_ssl_credentials                                                          +48  [NEW]
      [NEW]     +48 vtable for grpc_alts_credentials                                                         +48  [NEW]
      [NEW]     +48 vtable for grpc_local_credentials                                                        +48  [NEW]
      [NEW]     +48 vtable for grpc_plugin_credentials                                                       +48  [NEW]
      [NEW]     +48 vtable for grpc_google_iam_credentials                                                   +48  [NEW]
  +382% +15.6Ki src/core/lib/security/transport/security_handshaker.cc                               +15.6Ki  +382%
     +14e2% +3.41Ki on_handshake_data_sent_to_peer                                                       +3.41Ki +14e2%
     +15e2% +3.34Ki on_handshake_data_received_from_peer                                                 +3.34Ki +15e2%
     +17e2% +2.29Ki security_handshaker_do_handshake                                                     +2.29Ki +17e2%
     +18e2% +2.28Ki on_handshake_next_done_grpc_wrapper                                                  +2.28Ki +18e2%
     +45e3% +2.18Ki security_handshaker_destroy                                                          +2.18Ki +45e3%
      +329% +2.17Ki on_peer_checked                                                                      +2.17Ki  +329%
      [NEW]    +544 on_handshake_next_done_locked                                                           +544  [NEW]
      [NEW]    +394 move_read_buffer_into_handshake_buffer                                                  +394  [NEW]
      [NEW]    +323 security_handshake_failed_locked                                                        +323  [NEW]
      [NEW]    +186 check_peer_locked                                                                       +186  [NEW]
      [NEW]    +153 do_handshaker_next_locked                                                               +153  [NEW]
      [NEW]     +69 cleanup_args_for_failure_locked                                                          +69  [NEW]
       +22%     +64 grpc_security_handshaker_create                                                          +64   +22%
       +57%     +23 client_handshaker_factory_add_handshakers                                                +23   +57%
       +57%     +23 server_handshaker_factory_add_handshakers                                                +23   +57%
  +183% +5.99Ki src/core/lib/security/context/security_context.cc                                    +5.99Ki  +183%
     +44e2% +1.81Ki grpc_server_security_context::~grpc_server_security_context                          +1.81Ki +44e2%
     +23e2% +1.33Ki grpc_auth_context_release                                                            +1.33Ki +23e2%
     +27e3% +1.31Ki auth_context_pointer_arg_destroy                                                     +1.31Ki +27e3%
     +21e2% +1.02Ki grpc_client_security_context::~grpc_client_security_context                          +1.02Ki +21e2%
      [NEW]    +454 grpc_auth_context::~grpc_auth_context                                                   +454  [NEW]
      [NEW]    +193 grpc_client_security_context_create                                                     +193  [NEW]
      [NEW]    +112 grpc_auth_context::add_property                                                         +112  [NEW]
      [NEW]     +82 grpc_auth_context::add_cstring_property                                                  +82  [NEW]
      [NEW]     +62 grpc_auth_context::ensure_capacity                                                       +62  [NEW]
       +11%     +55 grpc_call_set_credentials                                                                +55   +11%
      +8.5%     +11 grpc_call_auth_context                                                                   +11  +8.5%
      +200%     +10 auth_context_pointer_arg_copy                                                            +10  +200%
  +173% +5.70Ki src/core/lib/security/transport/client_auth_filter.cc                                +5.70Ki  +173%
      +574% +3.53Ki auth_start_transport_stream_op_batch                                                 +3.53Ki  +574%
     +21e2% +1.34Ki grpc_auth_metadata_context_reset                                                     +1.34Ki +21e2%
     +21e2%    +581 destroy_channel_elem                                                                    +581 +21e2%
       +19%    +155 on_host_checked                                                                         +155   +19%
       +83%     +65 destroy_call_elem                                                                        +65   +83%
       +42%     +20 [Unmapped]                                                                               +20   +42%
       +22%     +16 cancel_get_request_metadata                                                              +16   +22%
      +1.7%      +8 grpc_auth_metadata_context_build                                                          +8  +1.7%
       +11%      +8 cancel_check_call_host                                                                    +8   +11%
  +115% +3.80Ki src/core/lib/security/security_connector/ssl/ssl_security_connector.cc               +3.80Ki  +115%
      [NEW] +2.76Ki (anonymous namespace)::grpc_ssl_channel_security_connector::check_peer               +2.76Ki  [NEW]
      [NEW] +1.12Ki grpc_ssl_server_security_connector_create                                            +1.12Ki  [NEW]
      [NEW] +1.10Ki grpc_ssl_channel_security_connector_create                                           +1.10Ki  [NEW]
      [NEW]    +676 (anonymous namespace)::grpc_ssl_server_security_connector::check_peer                   +676  [NEW]
      [NEW]    +668 (anonymous namespace)::grpc_ssl_server_security_connector::add_handshakers              +668  [NEW]
      [NEW]    +213 (anonymous namespace)::grpc_ssl_channel_security_connector::check_call_host             +213  [NEW]
      [NEW]    +171 (anonymous namespace)::grpc_ssl_channel_security_connector::add_handshakers             +171  [NEW]
      [NEW]    +135 (anonymous namespace)::grpc_ssl_server_security_connector::~grpc_ssl_server_security    +135  [NEW]
      [NEW]    +111 (anonymous namespace)::grpc_ssl_channel_security_connector::cmp(grpc_security_connec    +111  [NEW]
      [NEW]     +60 (anonymous namespace)::grpc_ssl_channel_security_connector::~grpc_ssl_channel_securi     +60  [NEW]
      [NEW]     +24 (anonymous namespace)::grpc_ssl_channel_security_connector::cancel_check_call_host       +24  [NEW]
      [NEW]     +14 (anonymous namespace)::grpc_ssl_server_security_connector::~grpc_ssl_server_security     +14  [NEW]
      [NEW]     +14 (anonymous namespace)::grpc_ssl_channel_security_connector::~grpc_ssl_channel_securi     +14  [NEW]
      [NEW]      +5 (anonymous namespace)::grpc_ssl_server_security_connector::cmp(grpc_security_connect      +5  [NEW]
   +92% +2.45Ki src/core/lib/security/transport/server_auth_filter.cc                                +2.45Ki   +92%
     +86e2% +1.94Ki destroy_channel_elem                                                                 +1.94Ki +86e2%
      +258%    +523 init_call_elem                                                                          +523  +258%
      +1.2%      +2 init_channel_elem                                                                         +2  +1.2%
      +1.1%      +1 [Unmapped]                                                                                +1  +1.1%
   +99% +2.41Ki src/core/lib/security/security_connector/fake/fake_security_connector.cc             +2.41Ki   +99%
      [NEW] +2.16Ki (anonymous namespace)::fake_check_peer(grpc_security_connector*, tsi_peer, grpc_core +2.16Ki  [NEW]
      [NEW]    +934 (anonymous namespace)::grpc_fake_channel_security_connector::check_peer                 +934  [NEW]
      [NEW]    +524 grpc_fake_channel_security_connector_create                                             +524  [NEW]
      [NEW]    +386 (anonymous namespace)::grpc_fake_channel_security_connector::check_call_host            +386  [NEW]
      [NEW]    +332 grpc_fake_server_security_connector_create                                              +332  [NEW]
      [NEW]    +111 (anonymous namespace)::grpc_fake_server_security_connector::~grpc_fake_server_securi    +111  [NEW]
      [NEW]    +108 (anonymous namespace)::grpc_fake_channel_security_connector::cmp(grpc_security_conne    +108  [NEW]
      [NEW]     +55 (anonymous namespace)::grpc_fake_channel_security_connector::~grpc_fake_channel_secu     +55  [NEW]
      [NEW]     +50 (anonymous namespace)::grpc_fake_channel_security_connector::add_handshakers             +50  [NEW]
      [NEW]     +47 (anonymous namespace)::grpc_fake_server_security_connector::add_handshakers              +47  [NEW]
      [NEW]     +37 (anonymous namespace)::grpc_fake_server_security_connector::~grpc_fake_server_securi     +37  [NEW]
      [NEW]     +24 (anonymous namespace)::grpc_fake_channel_security_connector::cancel_check_call_host      +24  [NEW]
      [NEW]     +20 (anonymous namespace)::grpc_fake_server_security_connector::check_peer                   +20  [NEW]
      [NEW]     +14 (anonymous namespace)::grpc_fake_channel_security_connector::~grpc_fake_channel_secu     +14  [NEW]
      [NEW]      +5 (anonymous namespace)::grpc_fake_server_security_connector::cmp(grpc_security_connec      +5  [NEW]
   +79% +1.72Ki src/core/lib/security/security_connector/alts/alts_security_connector.cc             +1.72Ki   +79%
      [NEW]    +886 grpc_core::internal::grpc_alts_auth_context_from_tsi_peer                               +886  [NEW]
      [NEW]    +788 (anonymous namespace)::grpc_alts_channel_security_connector::check_peer                 +788  [NEW]
      [NEW]    +497 grpc_alts_channel_security_connector_create                                             +497  [NEW]
      [NEW]    +412 grpc_alts_server_security_connector_create                                              +412  [NEW]
      [NEW]    +176 (anonymous namespace)::grpc_alts_channel_security_connector::add_handshakers            +176  [NEW]
      [NEW]    +168 (anonymous namespace)::grpc_alts_server_security_connector::add_handshakers             +168  [NEW]
      [NEW]    +139 (anonymous namespace)::grpc_alts_channel_security_connector::check_call_host            +139  [NEW]
      [NEW]    +111 (anonymous namespace)::grpc_alts_server_security_connector::~grpc_alts_server_securi    +111  [NEW]
      [NEW]    +111 grpc_server_security_connector::~grpc_server_security_connector                         +111  [NEW]
      [NEW]     +84 grpc_core::RefCounted<grpc_server_credentials, grpc_core::PolymorphicRefCount>::Unre     +84  [NEW]
      [NEW]     +78 grpc_security_connector::check_peer                                                      +78  [NEW]
      [NEW]     +78 grpc_server_security_connector::add_handshakers                                          +78  [NEW]
      [NEW]     +78 grpc_security_connector::cmp(grpc_security_connector const*) const                       +78  [NEW]
      [NEW]     +55 (anonymous namespace)::grpc_alts_channel_security_connector::cmp(grpc_security_conne     +55  [NEW]
      [NEW]     +38 (anonymous namespace)::alts_set_rpc_protocol_versions                                    +38  [NEW]
      [NEW]     +37 (anonymous namespace)::grpc_alts_server_security_connector::~grpc_alts_server_securi     +37  [NEW]
      [NEW]     +37 grpc_server_security_connector::~grpc_server_security_connector                          +37  [NEW]
      [NEW]     +36 (anonymous namespace)::grpc_alts_channel_security_connector::~grpc_alts_channel_secu     +36  [NEW]
      [NEW]     +32 (anonymous namespace)::grpc_alts_channel_security_connector::~grpc_alts_channel_secu     +32  [NEW]
       +28%     +24 [Other]                                                                                  +24   +28%
      [NEW]     +24 (anonymous namespace)::grpc_alts_channel_security_connector::cancel_check_call_host      +24  [NEW]
   +60% +1.23Ki src/core/lib/security/credentials/composite/composite_credentials.cc                 +1.23Ki   +60%
      [NEW]    +552 grpc_composite_channel_credentials::create_security_connector                           +552  [NEW]
      [NEW]    +384 grpc_composite_call_credentials::grpc_composite_call_credentials                        +384  [NEW]
      [NEW]    +285 grpc_composite_call_credentials::get_request_metadata                                   +285  [NEW]
      [NEW]    +240 grpc_composite_call_credentials::push_to_inner                                          +240  [NEW]
      [NEW]    +203 grpc_call_credentials_array::reserve                                                    +203  [NEW]
      [NEW]    +150 grpc_composite_call_credentials::cancel_get_request_metadata                            +150  [NEW]
      [NEW]    +120 grpc_call_credentials_array::grpc_call_credentials_array                                +120  [NEW]
       +50%    +117 grpc_composite_channel_credentials_create                                               +117   +50%
      [NEW]    +115 grpc_composite_channel_credentials::~grpc_composite_channel_credentials                 +115  [NEW]
      [NEW]    +109 grpc_call_credentials_array::~grpc_call_credentials_array                               +109  [NEW]
      [NEW]     +33 grpc_composite_call_credentials::~grpc_composite_call_credentials                        +33  [NEW]
      [NEW]     +33 grpc_composite_channel_credentials::duplicate_without_call_credentials                   +33  [NEW]
      [NEW]     +24 grpc_composite_call_credentials::~grpc_composite_call_credentials                        +24  [NEW]
      [NEW]     +14 grpc_composite_channel_credentials::~grpc_composite_channel_credentials                  +14  [NEW]
      +0.5%      +1 composite_call_metadata_cb                                                                +1  +0.5%
   +73% +1.19Ki src/core/lib/security/security_connector/local/local_security_connector.cc           +1.19Ki   +73%
      [NEW]    +932 (anonymous namespace)::grpc_local_channel_security_connector::check_peer                +932  [NEW]
      [NEW]    +689 grpc_local_channel_security_connector_create                                            +689  [NEW]
      [NEW]    +454 grpc_local_server_security_connector_create                                             +454  [NEW]
      [NEW]    +152 (anonymous namespace)::grpc_local_channel_security_connector::add_handshakers           +152  [NEW]
      [NEW]    +144 (anonymous namespace)::grpc_local_server_security_connector::add_handshakers            +144  [NEW]
      [NEW]    +139 (anonymous namespace)::grpc_local_channel_security_connector::check_call_host           +139  [NEW]
      [NEW]    +111 (anonymous namespace)::grpc_local_server_security_connector::~grpc_local_server_secu    +111  [NEW]
      [NEW]     +55 (anonymous namespace)::grpc_local_channel_security_connector::cmp(grpc_security_conn     +55  [NEW]
      [NEW]     +37 (anonymous namespace)::grpc_local_server_security_connector::~grpc_local_server_secu     +37  [NEW]
      [NEW]     +36 (anonymous namespace)::grpc_local_channel_security_connector::~grpc_local_channel_se     +36  [NEW]
      [NEW]     +32 (anonymous namespace)::grpc_local_channel_security_connector::~grpc_local_channel_se     +32  [NEW]
       +40%     +26 [Unmapped]                                                                               +26   +40%
      [NEW]     +24 (anonymous namespace)::grpc_local_channel_security_connector::cancel_check_call_host     +24  [NEW]
      [NEW]      +5 (anonymous namespace)::grpc_local_server_security_connector::cmp(grpc_security_conne      +5  [NEW]
   +24%    +913 src/core/lib/security/credentials/google_default/google_default_credentials.cc          +913   +24%
      [NEW] +1.21Ki create_default_creds_from_path                                                       +1.21Ki  [NEW]
      [NEW]    +499 grpc_google_default_channel_credentials::create_security_connector                      +499  [NEW]
       +23%    +416 grpc_google_default_credentials_create                                                  +416   +23%
      [NEW]    +115 grpc_google_default_channel_credentials::~grpc_google_default_channel_credentials       +115  [NEW]
      [NEW]     +14 grpc_google_default_channel_credentials::~grpc_google_default_channel_credentials        +14  [NEW]
       +17%     +11 [Unmapped]                                                                               +11   +17%
  +182%    +752 src/core/lib/security/credentials/alts/alts_credentials.cc                              +752  +182%
      [NEW]    +196 grpc_alts_credentials::create_security_connector                                        +196  [NEW]
      [NEW]    +135 grpc_alts_server_credentials::grpc_alts_server_credentials                              +135  [NEW]
      [NEW]    +119 grpc_alts_server_credentials::create_security_connector                                 +119  [NEW]
      [NEW]    +111 grpc_alts_credentials::grpc_alts_credentials                                            +111  [NEW]
      [NEW]     +82 grpc_alts_server_credentials::~grpc_alts_server_credentials                              +82  [NEW]
      [NEW]     +78 grpc_server_credentials::create_security_connector                                       +78  [NEW]
      [NEW]     +43 grpc_server_credentials::~grpc_server_credentials                                        +43  [NEW]
      [NEW]     +42 grpc_server_credentials::~grpc_server_credentials                                        +42  [NEW]
      [NEW]     +37 grpc_alts_credentials::~grpc_alts_credentials                                            +37  [NEW]
       +37%     +23 [Unmapped]                                                                               +23   +37%
      [NEW]     +14 grpc_alts_credentials::~grpc_alts_credentials                                            +14  [NEW]
      [NEW]     +14 grpc_alts_server_credentials::~grpc_alts_server_credentials                              +14  [NEW]
      [NEW]     +13 grpc_channel_credentials::duplicate_without_call_credentials                             +13  [NEW]
   +23%    +592 src/core/lib/security/credentials/ssl/ssl_credentials.cc                                +592   +23%
      [NEW]    +497 grpc_ssl_credentials::create_security_connector                                         +497  [NEW]
      [NEW]    +299 grpc_ssl_credentials::build_config                                                      +299  [NEW]
      [NEW]    +148 grpc_ssl_server_credentials::grpc_ssl_server_credentials                                +148  [NEW]
      [NEW]    +119 grpc_ssl_server_credentials::create_security_connector                                  +119  [NEW]
      [NEW]     +82 grpc_ssl_server_credentials::~grpc_ssl_server_credentials                                +82  [NEW]
      [NEW]     +66 grpc_ssl_credentials::~grpc_ssl_credentials                                              +66  [NEW]
      [NEW]     +60 grpc_ssl_server_credentials::build_config                                                +60  [NEW]
       +27%     +40 [Unmapped]                                                                               +40   +27%
      [NEW]     +38 grpc_ssl_credentials::grpc_ssl_credentials                                               +38  [NEW]
       +16%     +16 grpc_ssl_server_certificate_config_destroy                                               +16   +16%
      [NEW]     +14 grpc_ssl_credentials::~grpc_ssl_credentials                                              +14  [NEW]
      [NEW]     +14 grpc_ssl_server_credentials::~grpc_ssl_server_credentials                                +14  [NEW]
      +2.3%      +8 grpc_ssl_server_certificate_config_create                                                 +8  +2.3%
       +19%      +8 grpc_ssl_server_credentials_options_destroy                                               +8   +19%
   +11%    +533 src/core/lib/security/credentials/oauth2/oauth2_credentials.cc                          +533   +11%
      [NEW]    +599 grpc_oauth2_token_fetcher_credentials::on_http_response                                 +599  [NEW]
      [NEW]    +496 grpc_oauth2_token_fetcher_credentials::get_request_metadata                             +496  [NEW]
      [NEW]    +418 grpc_google_refresh_token_credentials::fetch_oauth2                                     +418  [NEW]
      [NEW]    +367 grpc_access_token_credentials::grpc_access_token_credentials                            +367  [NEW]
      [NEW]    +309 (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials::fetch_oauth2      +309  [NEW]
      [NEW]    +225 grpc_oauth2_token_fetcher_credentials::cancel_get_request_metadata                      +225  [NEW]
      [NEW]    +112 grpc_oauth2_token_fetcher_credentials::grpc_oauth2_token_fetcher_credentials            +112  [NEW]
      [NEW]     +78 grpc_oauth2_token_fetcher_credentials::fetch_oauth2                                      +78  [NEW]
      [NEW]     +63 grpc_oauth2_token_fetcher_credentials::~grpc_oauth2_token_fetcher_credentials            +63  [NEW]
      [NEW]     +51 grpc_google_refresh_token_credentials::grpc_google_refresh_token_credentials             +51  [NEW]
      [NEW]     +40 grpc_google_refresh_token_credentials::~grpc_google_refresh_token_credentials            +40  [NEW]
       +11%     +36 [Other]                                                                                  +36   +11%
       +16%     +28 [Unmapped]                                                                               +28   +16%
      [NEW]     +26 grpc_access_token_credentials::get_request_metadata                                      +26  [NEW]
      [NEW]     +24 (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials::~grpc_compute_     +24  [NEW]
      [NEW]     +24 grpc_access_token_credentials::cancel_get_request_metadata                               +24  [NEW]
      [NEW]     +23 grpc_access_token_credentials::~grpc_access_token_credentials                            +23  [NEW]
       +17%     +21 grpc_refresh_token_credentials_create_from_auth_refresh_token                            +21   +17%
      +9.9%     +16 grpc_google_compute_engine_credentials_create                                            +16  +9.9%
      [NEW]     +15 (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials::~grpc_compute_     +15  [NEW]
      [NEW]     +14 grpc_access_token_credentials::~grpc_access_token_credentials                            +14  [NEW]
  +208%    +443 src/core/lib/security/credentials/local/local_credentials.cc                            +443  +208%
      [NEW]    +212 grpc_local_credentials::create_security_connector                                       +212  [NEW]
      [NEW]    +119 grpc_local_server_credentials::create_security_connector                                +119  [NEW]
      [NEW]     +61 grpc_local_server_credentials::grpc_local_server_credentials                             +61  [NEW]
      [NEW]     +43 grpc_local_server_credentials::~grpc_local_server_credentials                            +43  [NEW]
      [NEW]     +42 grpc_local_server_credentials::~grpc_local_server_credentials                            +42  [NEW]
      [NEW]     +37 grpc_local_credentials::grpc_local_credentials                                           +37  [NEW]
      [NEW]      +9 grpc_local_credentials::~grpc_local_credentials                                           +9  [NEW]
      [NEW]      +2 grpc_local_credentials::~grpc_local_credentials                                           +2  [NEW]
   +75%    +442 src/core/lib/security/credentials/fake/fake_credentials.cc                              +442   +75%
      [NEW]    +175 (anonymous namespace)::grpc_fake_channel_credentials::create_security_connector         +175  [NEW]
      [NEW]    +119 (anonymous namespace)::grpc_fake_server_credentials::create_security_connector          +119  [NEW]
      [NEW]     +68 grpc_md_only_test_credentials::get_request_metadata                                      +68  [NEW]
      [NEW]     +43 (anonymous namespace)::grpc_fake_server_credentials::~grpc_fake_server_credentials       +43  [NEW]
      [NEW]     +42 (anonymous namespace)::grpc_fake_server_credentials::~grpc_fake_server_credentials       +42  [NEW]
      [NEW]     +32 grpc_md_only_test_credentials::~grpc_md_only_test_credentials                            +32  [NEW]
       +44%     +28 [Unmapped]                                                                               +28   +44%
      [NEW]     +24 grpc_md_only_test_credentials::cancel_get_request_metadata                               +24  [NEW]
      [NEW]     +23 grpc_md_only_test_credentials::~grpc_md_only_test_credentials                            +23  [NEW]
      [NEW]      +9 (anonymous namespace)::grpc_fake_channel_credentials::~grpc_fake_channel_credentials      +9  [NEW]
       +12%      +8 grpc_fake_transport_security_server_credentials_create                                    +8   +12%
      +1.8%      +3 grpc_md_only_test_credentials_create                                                      +3  +1.8%
      [NEW]      +2 (anonymous namespace)::grpc_fake_channel_credentials::~grpc_fake_channel_credentials      +2  [NEW]
   +32%    +396 src/core/lib/http/httpcli_security_connector.cc                                         +396   +32%
       +59%    +344 ssl_handshake                                                                           +344   +59%
      [NEW]    +279 grpc_httpcli_ssl_channel_security_connector::check_peer                                 +279  [NEW]
      [NEW]    +160 grpc_httpcli_ssl_channel_security_connector::add_handshakers                            +160  [NEW]
      [NEW]     +55 grpc_httpcli_ssl_channel_security_connector::~grpc_httpcli_ssl_channel_security_conn     +55  [NEW]
      [NEW]     +24 grpc_httpcli_ssl_channel_security_connector::cancel_check_call_host                      +24  [NEW]
      [NEW]     +14 grpc_httpcli_ssl_channel_security_connector::~grpc_httpcli_ssl_channel_security_conn     +14  [NEW]
      [NEW]     +13 grpc_httpcli_ssl_channel_security_connector::check_call_host                             +13  [NEW]
      [NEW]     +13 grpc_httpcli_ssl_channel_security_connector::cmp(grpc_security_connector const*) con     +13  [NEW]
      [NEW]      +9 grpc_call_credentials::~grpc_call_credentials                                             +9  [NEW]
      [NEW]      +9 grpc_channel_credentials::~grpc_channel_credentials                                       +9  [NEW]
      [NEW]      +2 grpc_call_credentials::~grpc_call_credentials                                             +2  [NEW]
      [NEW]      +2 grpc_channel_credentials::~grpc_channel_credentials                                       +2  [NEW]
  +3.9%    +328 [Other]                                                                                 +328  +3.9%
  +9.0%    +192 src/core/ext/transport/chttp2/client/secure/secure_channel_create.cc                    +192  +9.0%
       +15%    +193 client_channel_factory_create_subchannel                                                +193   +15%
   +12%    +192 src/core/lib/security/credentials/jwt/jwt_credentials.cc                                +192   +12%
      [NEW]    +599 grpc_service_account_jwt_access_credentials::get_request_metadata                       +599  [NEW]
      [NEW]    +215 grpc_service_account_jwt_access_credentials::grpc_service_account_jwt_access_credent    +215  [NEW]
      [NEW]     +63 grpc_service_account_jwt_access_credentials::reset_cache                                 +63  [NEW]
      [NEW]     +46 grpc_service_account_jwt_access_credentials::~grpc_service_account_jwt_access_creden     +46  [NEW]
      [NEW]     +24 grpc_service_account_jwt_access_credentials::cancel_get_request_metadata                 +24  [NEW]
      +2.5%     +16 grpc_service_account_jwt_access_credentials_create                                       +16  +2.5%
      [NEW]     +14 grpc_service_account_jwt_access_credentials::~grpc_service_account_jwt_access_creden     +14  [NEW]
       +32%     +11 [Unmapped]                                                                               +11   +32%
   +14%    +112 src/core/lib/security/credentials/iam/iam_credentials.cc                                +112   +14%
      [NEW]    +241 grpc_google_iam_credentials::grpc_google_iam_credentials                                +241  [NEW]
      [NEW]     +26 grpc_google_iam_credentials::get_request_metadata                                        +26  [NEW]
      [NEW]     +24 grpc_google_iam_credentials::cancel_get_request_metadata                                 +24  [NEW]
      [NEW]     +24 grpc_google_iam_credentials::~grpc_google_iam_credentials                                +24  [NEW]
       +86%     +18 [Unmapped]                                                                               +18   +86%
      [NEW]     +14 grpc_google_iam_credentials::~grpc_google_iam_credentials                                +14  [NEW]

 -------------- SHRINKING                                                                            --------------
 -11.4%    -272 src/core/lib/security/credentials/credentials.cc                                        -272 -11.4%
     -52.2%    -120 [Unmapped]                                                                              -120 -52.2%
      [DEL]    -109 grpc_channel_credentials_create_security_connector                                      -109  [DEL]
     -83.5%     -96 grpc_server_credentials_set_auth_metadata_processor                                      -96 -83.5%
      [DEL]     -82 grpc_server_credentials_unref                                                            -82  [DEL]
      [DEL]     -69 grpc_server_credentials_create_security_connector                                        -69  [DEL]
      [DEL]     -58 grpc_call_credentials_unref                                                              -58  [DEL]
      [DEL]     -58 grpc_channel_credentials_unref                                                           -58  [DEL]
      [DEL]     -43 grpc_credentials_metadata_request_create                                                 -43  [DEL]
      [DEL]     -37 grpc_channel_credentials_duplicate_without_call_credentials                              -37  [DEL]
      [DEL]     -30 grpc_credentials_metadata_request_destroy                                                -30  [DEL]
      [DEL]     -30 grpc_call_credentials_get_request_metadata                                               -30  [DEL]
      [DEL]     -26 grpc_call_credentials_cancel_get_request_metadata                                        -26  [DEL]
      [DEL]     -23 grpc_call_credentials_ref                                                                -23  [DEL]
      [DEL]     -23 grpc_server_credentials_ref                                                              -23  [DEL]
      [DEL]     -23 grpc_channel_credentials_ref                                                             -23  [DEL]
  -1.1%     -15 src/core/lib/security/security_connector/security_connector.cc                           -15  -1.1%
      [DEL]    -215 grpc_channel_security_connector_cmp                                                     -215  [DEL]
      [DEL]    -186 grpc_security_connector_check_peer                                                      -186  [DEL]
      [DEL]    -167 grpc_server_security_connector_cmp                                                      -167  [DEL]
      [DEL]    -166 grpc_channel_security_connector_check_call_host                                         -166  [DEL]
      [DEL]     -70 grpc_security_connector_cmp                                                              -70  [DEL]
     -36.4%     -51 [Unmapped]                                                                               -51 -36.4%
      [DEL]     -50 grpc_security_connector_unref                                                            -50  [DEL]
      [DEL]     -40 grpc_channel_security_connector_cancel_check_call_host                                   -40  [DEL]
      [DEL]     -23 grpc_security_connector_ref                                                              -23  [DEL]
      [DEL]     -18 grpc_server_security_connector_add_handshakers                                           -18  [DEL]
      [DEL]     -18 grpc_channel_security_connector_add_handshakers                                          -18  [DEL]

  +4.2% +64.8Ki TOTAL                                                                                +1.11Mi   +10%


****************************************************************

libgrpc++.so

     VM SIZE                                                                                            FILE SIZE
 ++++++++++++++ GROWING                                                                              ++++++++++++++
  +0.4% +1.21Ki [None]                                                                                +254Ki  +3.2%
      +0.4% +1.18Ki [Unmapped]                                                                            +254Ki  +3.2%
      [NEW]     +92 typeinfo name for std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocat     +92  [NEW]
      [NEW]     +56 vtable for std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<grpc     +56  [NEW]
       +21%     +24 [None]                                                                                     0  [ = ]
      [NEW]     +24 typeinfo for std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<gr     +24  [NEW]
   +55% +3.97Ki src/cpp/client/secure_credentials.cc                                                 +3.97Ki   +55%
      [NEW] +2.05Ki grpc_core::RefCounted<grpc_auth_context, grpc_core::NonPolymorphicRefCount>::Unref   +2.05Ki  [NEW]
       +70% +1.08Ki grpc::MetadataCredentialsPluginWrapper::InvokePlugin                                 +1.08Ki   +70%
      [NEW]    +454 grpc_auth_context::~grpc_auth_context                                                   +454  [NEW]
      [NEW]    +200 void std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >    +200  [NEW]
      +208%     +75 grpc::SecureCallCredentials::~SecureCallCredentials                                      +75  +208%
      +208%     +75 grpc::SecureChannelCredentials::~SecureChannelCredentials                                +75  +208%
      +105%     +61 std::_Sp_counted_ptr<grpc::SecureCallCredentials*, (__gnu_cxx::_Lock_policy)2>::_M_d     +61  +105%
      +105%     +61 std::_Sp_counted_ptr<grpc::SecureChannelCredentials*, (__gnu_cxx::_Lock_policy)2>::_     +61  +105%
      +134%     +59 grpc::SecureCallCredentials::~SecureCallCredentials                                      +59  +134%
      +134%     +59 grpc::SecureChannelCredentials::~SecureChannelCredentials                                +59  +134%
      [NEW]      +9 grpc_call_credentials::~grpc_call_credentials                                             +9  [NEW]
      [NEW]      +9 grpc_channel_credentials::~grpc_channel_credentials                                       +9  [NEW]
      +4.1%      +8 grpc::(anonymous namespace)::WrapCallCredentials                                          +8  +4.1%
      +4.1%      +8 grpc::(anonymous namespace)::WrapChannelCredentials                                       +8  +4.1%
      [NEW]      +2 grpc_call_credentials::~grpc_call_credentials                                             +2  [NEW]
      [NEW]      +2 grpc_channel_credentials::~grpc_channel_credentials                                       +2  [NEW]
  +158% +2.61Ki src/cpp/common/secure_auth_context.cc                                                +2.61Ki  +158%
     +77e2% +1.36Ki grpc::SecureAuthContext::~SecureAuthContext                                          +1.36Ki +77e2%
     +33e2% +1.31Ki grpc::SecureAuthContext::~SecureAuthContext                                          +1.31Ki +33e2%
      [NEW]    +200 void std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >    +200  [NEW]
  +685% +1.86Ki src/cpp/common/secure_create_auth_context.cc                                         +1.86Ki  +685%
      [NEW] +1.35Ki std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<grpc::SecureAut +1.35Ki  [NEW]
      +249%    +495 grpc::CreateAuthContext                                                                 +495  +249%
      [NEW]     +52 std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<grpc::SecureAut     +52  [NEW]
      [NEW]      +5 std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<grpc::SecureAut      +5  [NEW]
      [NEW]      +5 std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<grpc::SecureAut      +5  [NEW]
      [NEW]      +2 std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<grpc::SecureAut      +2  [NEW]
   +22% +1.14Ki src/cpp/server/secure_server_credentials.cc                                          +1.14Ki   +22%
       +55% +1.16Ki grpc::AuthMetadataProcessorAyncWrapper::InvokeProcessor                              +1.16Ki   +55%

  +1.9% +10.8Ki TOTAL                                                                                 +264Ki  +3.2%



@grpc-testing
Copy link

[trickle] No significant performance differences

@grpc-testing
Copy link

Objective-C binary sizes
*****************STATIC******************
  New size                      Old size
   737,392       Core (>)        731,780

 2,026,858      Total (>)      2,020,870

***************FRAMEWORKS****************
  New size                      Old size
 4,105,230       Core (>)      3,970,386

11,311,965      Total (>)     11,177,116


@grpc-testing
Copy link

[microbenchmarks] No significant performance differences

This is to use `grpc_core::RefCount` to improve performnace.
This commit also replaces explicit C vtables, with C++ vtable
with its own compile time assertions and performance benefits.
It also makes use of `RefCountedPtr` wherever possible.
@grpc-testing
Copy link

****************************************************************

libgrpc.so

     VM SIZE                                                                                            FILE SIZE
 ++++++++++++++ GROWING                                                                              ++++++++++++++
  +2.7% +20.2Ki [None]                                                                               +1.06Mi   +10%
      +2.8% +19.3Ki [Unmapped]                                                                           +1.06Mi   +10%
      [NEW]    +568 [Other]                                                                                 +568  [NEW]
      [NEW]     +72 vtable for grpc_channel_security_connector                                               +72  [NEW]
      [NEW]     +72 vtable for grpc_httpcli_ssl_channel_security_connector                                   +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_ssl_channel_security_connector                    +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_alts_channel_security_connector                   +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_fake_channel_security_connector                   +72  [NEW]
      [NEW]     +72 vtable for (anonymous namespace)::grpc_local_channel_security_connector                  +72  [NEW]
      [NEW]     +56 vtable for grpc_server_security_connector                                                +56  [NEW]
      [NEW]     +56 vtable for grpc_google_refresh_token_credentials                                         +56  [NEW]
      [NEW]     +56 vtable for grpc_oauth2_token_fetcher_credentials                                         +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_ssl_server_security_connector                     +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_alts_server_security_connector                    +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_fake_server_security_connector                    +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_local_server_security_connector                   +56  [NEW]
      [NEW]     +56 vtable for (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials          +56  [NEW]
      [NEW]     +48 vtable for grpc_ssl_credentials                                                          +48  [NEW]
      [NEW]     +48 vtable for grpc_alts_credentials                                                         +48  [NEW]
      [NEW]     +48 vtable for grpc_local_credentials                                                        +48  [NEW]
      [NEW]     +48 vtable for grpc_plugin_credentials                                                       +48  [NEW]
      [NEW]     +48 vtable for grpc_google_iam_credentials                                                   +48  [NEW]
  +382% +15.6Ki src/core/lib/security/transport/security_handshaker.cc                               +15.6Ki  +382%
     +14e2% +3.41Ki on_handshake_data_sent_to_peer                                                       +3.41Ki +14e2%
     +15e2% +3.34Ki on_handshake_data_received_from_peer                                                 +3.34Ki +15e2%
     +17e2% +2.29Ki security_handshaker_do_handshake                                                     +2.29Ki +17e2%
     +18e2% +2.28Ki on_handshake_next_done_grpc_wrapper                                                  +2.28Ki +18e2%
     +45e3% +2.18Ki security_handshaker_destroy                                                          +2.18Ki +45e3%
      +329% +2.17Ki on_peer_checked                                                                      +2.17Ki  +329%
      [NEW]    +544 on_handshake_next_done_locked                                                           +544  [NEW]
      [NEW]    +394 move_read_buffer_into_handshake_buffer                                                  +394  [NEW]
      [NEW]    +323 security_handshake_failed_locked                                                        +323  [NEW]
      [NEW]    +186 check_peer_locked                                                                       +186  [NEW]
      [NEW]    +153 do_handshaker_next_locked                                                               +153  [NEW]
      [NEW]     +69 cleanup_args_for_failure_locked                                                          +69  [NEW]
       +22%     +64 grpc_security_handshaker_create                                                          +64   +22%
       +57%     +23 client_handshaker_factory_add_handshakers                                                +23   +57%
       +57%     +23 server_handshaker_factory_add_handshakers                                                +23   +57%
  +183% +5.99Ki src/core/lib/security/context/security_context.cc                                    +5.99Ki  +183%
     +44e2% +1.81Ki grpc_server_security_context::~grpc_server_security_context                          +1.81Ki +44e2%
     +23e2% +1.33Ki grpc_auth_context_release                                                            +1.33Ki +23e2%
     +27e3% +1.31Ki auth_context_pointer_arg_destroy                                                     +1.31Ki +27e3%
     +21e2% +1.02Ki grpc_client_security_context::~grpc_client_security_context                          +1.02Ki +21e2%
      [NEW]    +454 grpc_auth_context::~grpc_auth_context                                                   +454  [NEW]
      [NEW]    +193 grpc_client_security_context_create                                                     +193  [NEW]
      [NEW]    +112 grpc_auth_context::add_property                                                         +112  [NEW]
      [NEW]     +82 grpc_auth_context::add_cstring_property                                                  +82  [NEW]
      [NEW]     +62 grpc_auth_context::ensure_capacity                                                       +62  [NEW]
       +11%     +55 grpc_call_set_credentials                                                                +55   +11%
      +8.5%     +11 grpc_call_auth_context                                                                   +11  +8.5%
      +200%     +10 auth_context_pointer_arg_copy                                                            +10  +200%
  +173% +5.70Ki src/core/lib/security/transport/client_auth_filter.cc                                +5.70Ki  +173%
      +574% +3.53Ki auth_start_transport_stream_op_batch                                                 +3.53Ki  +574%
     +21e2% +1.34Ki grpc_auth_metadata_context_reset                                                     +1.34Ki +21e2%
     +21e2%    +581 destroy_channel_elem                                                                    +581 +21e2%
       +19%    +155 on_host_checked                                                                         +155   +19%
       +83%     +65 destroy_call_elem                                                                        +65   +83%
       +42%     +20 [Unmapped]                                                                               +20   +42%
       +22%     +16 cancel_get_request_metadata                                                              +16   +22%
      +1.7%      +8 grpc_auth_metadata_context_build                                                          +8  +1.7%
       +11%      +8 cancel_check_call_host                                                                    +8   +11%
  +115% +3.80Ki src/core/lib/security/security_connector/ssl/ssl_security_connector.cc               +3.80Ki  +115%
      [NEW] +2.76Ki (anonymous namespace)::grpc_ssl_channel_security_connector::check_peer               +2.76Ki  [NEW]
      [NEW] +1.12Ki grpc_ssl_server_security_connector_create                                            +1.12Ki  [NEW]
      [NEW] +1.10Ki grpc_ssl_channel_security_connector_create                                           +1.10Ki  [NEW]
      [NEW]    +676 (anonymous namespace)::grpc_ssl_server_security_connector::check_peer                   +676  [NEW]
      [NEW]    +668 (anonymous namespace)::grpc_ssl_server_security_connector::add_handshakers              +668  [NEW]
      [NEW]    +213 (anonymous namespace)::grpc_ssl_channel_security_connector::check_call_host             +213  [NEW]
      [NEW]    +171 (anonymous namespace)::grpc_ssl_channel_security_connector::add_handshakers             +171  [NEW]
      [NEW]    +135 (anonymous namespace)::grpc_ssl_server_security_connector::~grpc_ssl_server_security    +135  [NEW]
      [NEW]    +111 (anonymous namespace)::grpc_ssl_channel_security_connector::cmp(grpc_security_connec    +111  [NEW]
      [NEW]     +60 (anonymous namespace)::grpc_ssl_channel_security_connector::~grpc_ssl_channel_securi     +60  [NEW]
      [NEW]     +24 (anonymous namespace)::grpc_ssl_channel_security_connector::cancel_check_call_host       +24  [NEW]
      [NEW]     +14 (anonymous namespace)::grpc_ssl_server_security_connector::~grpc_ssl_server_security     +14  [NEW]
      [NEW]     +14 (anonymous namespace)::grpc_ssl_channel_security_connector::~grpc_ssl_channel_securi     +14  [NEW]
      [NEW]      +5 (anonymous namespace)::grpc_ssl_server_security_connector::cmp(grpc_security_connect      +5  [NEW]
   +92% +2.45Ki src/core/lib/security/transport/server_auth_filter.cc                                +2.45Ki   +92%
     +86e2% +1.94Ki destroy_channel_elem                                                                 +1.94Ki +86e2%
      +258%    +523 init_call_elem                                                                          +523  +258%
      +1.2%      +2 init_channel_elem                                                                         +2  +1.2%
      +1.1%      +1 [Unmapped]                                                                                +1  +1.1%
   +99% +2.41Ki src/core/lib/security/security_connector/fake/fake_security_connector.cc             +2.41Ki   +99%
      [NEW] +2.16Ki (anonymous namespace)::fake_check_peer(grpc_security_connector*, tsi_peer, grpc_core +2.16Ki  [NEW]
      [NEW]    +934 (anonymous namespace)::grpc_fake_channel_security_connector::check_peer                 +934  [NEW]
      [NEW]    +524 grpc_fake_channel_security_connector_create                                             +524  [NEW]
      [NEW]    +386 (anonymous namespace)::grpc_fake_channel_security_connector::check_call_host            +386  [NEW]
      [NEW]    +332 grpc_fake_server_security_connector_create                                              +332  [NEW]
      [NEW]    +111 (anonymous namespace)::grpc_fake_server_security_connector::~grpc_fake_server_securi    +111  [NEW]
      [NEW]    +108 (anonymous namespace)::grpc_fake_channel_security_connector::cmp(grpc_security_conne    +108  [NEW]
      [NEW]     +55 (anonymous namespace)::grpc_fake_channel_security_connector::~grpc_fake_channel_secu     +55  [NEW]
      [NEW]     +50 (anonymous namespace)::grpc_fake_channel_security_connector::add_handshakers             +50  [NEW]
      [NEW]     +47 (anonymous namespace)::grpc_fake_server_security_connector::add_handshakers              +47  [NEW]
      [NEW]     +37 (anonymous namespace)::grpc_fake_server_security_connector::~grpc_fake_server_securi     +37  [NEW]
      [NEW]     +24 (anonymous namespace)::grpc_fake_channel_security_connector::cancel_check_call_host      +24  [NEW]
      [NEW]     +20 (anonymous namespace)::grpc_fake_server_security_connector::check_peer                   +20  [NEW]
      [NEW]     +14 (anonymous namespace)::grpc_fake_channel_security_connector::~grpc_fake_channel_secu     +14  [NEW]
      [NEW]      +5 (anonymous namespace)::grpc_fake_server_security_connector::cmp(grpc_security_connec      +5  [NEW]
   +79% +1.72Ki src/core/lib/security/security_connector/alts/alts_security_connector.cc             +1.72Ki   +79%
      [NEW]    +886 grpc_core::internal::grpc_alts_auth_context_from_tsi_peer                               +886  [NEW]
      [NEW]    +788 (anonymous namespace)::grpc_alts_channel_security_connector::check_peer                 +788  [NEW]
      [NEW]    +497 grpc_alts_channel_security_connector_create                                             +497  [NEW]
      [NEW]    +412 grpc_alts_server_security_connector_create                                              +412  [NEW]
      [NEW]    +176 (anonymous namespace)::grpc_alts_channel_security_connector::add_handshakers            +176  [NEW]
      [NEW]    +168 (anonymous namespace)::grpc_alts_server_security_connector::add_handshakers             +168  [NEW]
      [NEW]    +139 (anonymous namespace)::grpc_alts_channel_security_connector::check_call_host            +139  [NEW]
      [NEW]    +111 (anonymous namespace)::grpc_alts_server_security_connector::~grpc_alts_server_securi    +111  [NEW]
      [NEW]    +111 grpc_server_security_connector::~grpc_server_security_connector                         +111  [NEW]
      [NEW]     +84 grpc_core::RefCounted<grpc_server_credentials, grpc_core::PolymorphicRefCount>::Unre     +84  [NEW]
      [NEW]     +78 grpc_security_connector::check_peer                                                      +78  [NEW]
      [NEW]     +78 grpc_server_security_connector::add_handshakers                                          +78  [NEW]
      [NEW]     +78 grpc_security_connector::cmp(grpc_security_connector const*) const                       +78  [NEW]
      [NEW]     +55 (anonymous namespace)::grpc_alts_channel_security_connector::cmp(grpc_security_conne     +55  [NEW]
      [NEW]     +38 (anonymous namespace)::alts_set_rpc_protocol_versions                                    +38  [NEW]
      [NEW]     +37 (anonymous namespace)::grpc_alts_server_security_connector::~grpc_alts_server_securi     +37  [NEW]
      [NEW]     +37 grpc_server_security_connector::~grpc_server_security_connector                          +37  [NEW]
      [NEW]     +36 (anonymous namespace)::grpc_alts_channel_security_connector::~grpc_alts_channel_secu     +36  [NEW]
      [NEW]     +32 (anonymous namespace)::grpc_alts_channel_security_connector::~grpc_alts_channel_secu     +32  [NEW]
       +28%     +24 [Other]                                                                                  +24   +28%
      [NEW]     +24 (anonymous namespace)::grpc_alts_channel_security_connector::cancel_check_call_host      +24  [NEW]
   +60% +1.23Ki src/core/lib/security/credentials/composite/composite_credentials.cc                 +1.23Ki   +60%
      [NEW]    +552 grpc_composite_channel_credentials::create_security_connector                           +552  [NEW]
      [NEW]    +384 grpc_composite_call_credentials::grpc_composite_call_credentials                        +384  [NEW]
      [NEW]    +285 grpc_composite_call_credentials::get_request_metadata                                   +285  [NEW]
      [NEW]    +240 grpc_composite_call_credentials::push_to_inner                                          +240  [NEW]
      [NEW]    +203 grpc_call_credentials_array::reserve                                                    +203  [NEW]
      [NEW]    +150 grpc_composite_call_credentials::cancel_get_request_metadata                            +150  [NEW]
      [NEW]    +120 grpc_call_credentials_array::grpc_call_credentials_array                                +120  [NEW]
       +50%    +117 grpc_composite_channel_credentials_create                                               +117   +50%
      [NEW]    +115 grpc_composite_channel_credentials::~grpc_composite_channel_credentials                 +115  [NEW]
      [NEW]    +109 grpc_call_credentials_array::~grpc_call_credentials_array                               +109  [NEW]
      [NEW]     +33 grpc_composite_call_credentials::~grpc_composite_call_credentials                        +33  [NEW]
      [NEW]     +33 grpc_composite_channel_credentials::duplicate_without_call_credentials                   +33  [NEW]
      [NEW]     +24 grpc_composite_call_credentials::~grpc_composite_call_credentials                        +24  [NEW]
      [NEW]     +14 grpc_composite_channel_credentials::~grpc_composite_channel_credentials                  +14  [NEW]
      +0.5%      +1 composite_call_metadata_cb                                                                +1  +0.5%
   +73% +1.19Ki src/core/lib/security/security_connector/local/local_security_connector.cc           +1.19Ki   +73%
      [NEW]    +932 (anonymous namespace)::grpc_local_channel_security_connector::check_peer                +932  [NEW]
      [NEW]    +689 grpc_local_channel_security_connector_create                                            +689  [NEW]
      [NEW]    +454 grpc_local_server_security_connector_create                                             +454  [NEW]
      [NEW]    +152 (anonymous namespace)::grpc_local_channel_security_connector::add_handshakers           +152  [NEW]
      [NEW]    +144 (anonymous namespace)::grpc_local_server_security_connector::add_handshakers            +144  [NEW]
      [NEW]    +139 (anonymous namespace)::grpc_local_channel_security_connector::check_call_host           +139  [NEW]
      [NEW]    +111 (anonymous namespace)::grpc_local_server_security_connector::~grpc_local_server_secu    +111  [NEW]
      [NEW]     +55 (anonymous namespace)::grpc_local_channel_security_connector::cmp(grpc_security_conn     +55  [NEW]
      [NEW]     +37 (anonymous namespace)::grpc_local_server_security_connector::~grpc_local_server_secu     +37  [NEW]
      [NEW]     +36 (anonymous namespace)::grpc_local_channel_security_connector::~grpc_local_channel_se     +36  [NEW]
      [NEW]     +32 (anonymous namespace)::grpc_local_channel_security_connector::~grpc_local_channel_se     +32  [NEW]
       +40%     +26 [Unmapped]                                                                               +26   +40%
      [NEW]     +24 (anonymous namespace)::grpc_local_channel_security_connector::cancel_check_call_host     +24  [NEW]
      [NEW]      +5 (anonymous namespace)::grpc_local_server_security_connector::cmp(grpc_security_conne      +5  [NEW]
   +24%    +913 src/core/lib/security/credentials/google_default/google_default_credentials.cc          +913   +24%
      [NEW] +1.21Ki create_default_creds_from_path                                                       +1.21Ki  [NEW]
      [NEW]    +499 grpc_google_default_channel_credentials::create_security_connector                      +499  [NEW]
       +23%    +416 grpc_google_default_credentials_create                                                  +416   +23%
      [NEW]    +115 grpc_google_default_channel_credentials::~grpc_google_default_channel_credentials       +115  [NEW]
      [NEW]     +14 grpc_google_default_channel_credentials::~grpc_google_default_channel_credentials        +14  [NEW]
       +17%     +11 [Unmapped]                                                                               +11   +17%
  +182%    +752 src/core/lib/security/credentials/alts/alts_credentials.cc                              +752  +182%
      [NEW]    +196 grpc_alts_credentials::create_security_connector                                        +196  [NEW]
      [NEW]    +135 grpc_alts_server_credentials::grpc_alts_server_credentials                              +135  [NEW]
      [NEW]    +119 grpc_alts_server_credentials::create_security_connector                                 +119  [NEW]
      [NEW]    +111 grpc_alts_credentials::grpc_alts_credentials                                            +111  [NEW]
      [NEW]     +82 grpc_alts_server_credentials::~grpc_alts_server_credentials                              +82  [NEW]
      [NEW]     +78 grpc_server_credentials::create_security_connector                                       +78  [NEW]
      [NEW]     +43 grpc_server_credentials::~grpc_server_credentials                                        +43  [NEW]
      [NEW]     +42 grpc_server_credentials::~grpc_server_credentials                                        +42  [NEW]
      [NEW]     +37 grpc_alts_credentials::~grpc_alts_credentials                                            +37  [NEW]
       +37%     +23 [Unmapped]                                                                               +23   +37%
      [NEW]     +14 grpc_alts_credentials::~grpc_alts_credentials                                            +14  [NEW]
      [NEW]     +14 grpc_alts_server_credentials::~grpc_alts_server_credentials                              +14  [NEW]
      [NEW]     +13 grpc_channel_credentials::duplicate_without_call_credentials                             +13  [NEW]
   +11%    +533 src/core/lib/security/credentials/oauth2/oauth2_credentials.cc                          +533   +11%
      [NEW]    +599 grpc_oauth2_token_fetcher_credentials::on_http_response                                 +599  [NEW]
      [NEW]    +496 grpc_oauth2_token_fetcher_credentials::get_request_metadata                             +496  [NEW]
      [NEW]    +418 grpc_google_refresh_token_credentials::fetch_oauth2                                     +418  [NEW]
      [NEW]    +367 grpc_access_token_credentials::grpc_access_token_credentials                            +367  [NEW]
      [NEW]    +309 (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials::fetch_oauth2      +309  [NEW]
      [NEW]    +225 grpc_oauth2_token_fetcher_credentials::cancel_get_request_metadata                      +225  [NEW]
      [NEW]    +112 grpc_oauth2_token_fetcher_credentials::grpc_oauth2_token_fetcher_credentials            +112  [NEW]
      [NEW]     +78 grpc_oauth2_token_fetcher_credentials::fetch_oauth2                                      +78  [NEW]
      [NEW]     +63 grpc_oauth2_token_fetcher_credentials::~grpc_oauth2_token_fetcher_credentials            +63  [NEW]
      [NEW]     +51 grpc_google_refresh_token_credentials::grpc_google_refresh_token_credentials             +51  [NEW]
      [NEW]     +40 grpc_google_refresh_token_credentials::~grpc_google_refresh_token_credentials            +40  [NEW]
       +11%     +36 [Other]                                                                                  +36   +11%
       +16%     +28 [Unmapped]                                                                               +28   +16%
      [NEW]     +26 grpc_access_token_credentials::get_request_metadata                                      +26  [NEW]
      [NEW]     +24 (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials::~grpc_compute_     +24  [NEW]
      [NEW]     +24 grpc_access_token_credentials::cancel_get_request_metadata                               +24  [NEW]
      [NEW]     +23 grpc_access_token_credentials::~grpc_access_token_credentials                            +23  [NEW]
       +17%     +21 grpc_refresh_token_credentials_create_from_auth_refresh_token                            +21   +17%
      +9.9%     +16 grpc_google_compute_engine_credentials_create                                            +16  +9.9%
      [NEW]     +15 (anonymous namespace)::grpc_compute_engine_token_fetcher_credentials::~grpc_compute_     +15  [NEW]
      [NEW]     +14 grpc_access_token_credentials::~grpc_access_token_credentials                            +14  [NEW]
   +20%    +528 src/core/lib/security/credentials/ssl/ssl_credentials.cc                                +528   +20%
      [NEW]    +497 grpc_ssl_credentials::create_security_connector                                         +497  [NEW]
      [NEW]    +283 grpc_ssl_credentials::build_config                                                      +283  [NEW]
      [NEW]    +148 grpc_ssl_server_credentials::grpc_ssl_server_credentials                                +148  [NEW]
      [NEW]    +119 grpc_ssl_server_credentials::create_security_connector                                  +119  [NEW]
      [NEW]     +82 grpc_ssl_server_credentials::~grpc_ssl_server_credentials                                +82  [NEW]
      [NEW]     +66 grpc_ssl_credentials::~grpc_ssl_credentials                                              +66  [NEW]
      [NEW]     +53 grpc_ssl_server_credentials::build_config                                                +53  [NEW]
       +26%     +39 [Unmapped]                                                                               +39   +26%
      [NEW]     +38 grpc_ssl_credentials::grpc_ssl_credentials                                               +38  [NEW]
      [NEW]     +14 grpc_ssl_credentials::~grpc_ssl_credentials                                              +14  [NEW]
      [NEW]     +14 grpc_ssl_server_credentials::~grpc_ssl_server_credentials                                +14  [NEW]
  +208%    +443 src/core/lib/security/credentials/local/local_credentials.cc                            +443  +208%
      [NEW]    +212 grpc_local_credentials::create_security_connector                                       +212  [NEW]
      [NEW]    +119 grpc_local_server_credentials::create_security_connector                                +119  [NEW]
      [NEW]     +61 grpc_local_server_credentials::grpc_local_server_credentials                             +61  [NEW]
      [NEW]     +43 grpc_local_server_credentials::~grpc_local_server_credentials                            +43  [NEW]
      [NEW]     +42 grpc_local_server_credentials::~grpc_local_server_credentials                            +42  [NEW]
      [NEW]     +37 grpc_local_credentials::grpc_local_credentials                                           +37  [NEW]
      [NEW]      +9 grpc_local_credentials::~grpc_local_credentials                                           +9  [NEW]
      [NEW]      +2 grpc_local_credentials::~grpc_local_credentials                                           +2  [NEW]
   +75%    +442 src/core/lib/security/credentials/fake/fake_credentials.cc                              +442   +75%
      [NEW]    +175 (anonymous namespace)::grpc_fake_channel_credentials::create_security_connector         +175  [NEW]
      [NEW]    +119 (anonymous namespace)::grpc_fake_server_credentials::create_security_connector          +119  [NEW]
      [NEW]     +68 grpc_md_only_test_credentials::get_request_metadata                                      +68  [NEW]
      [NEW]     +43 (anonymous namespace)::grpc_fake_server_credentials::~grpc_fake_server_credentials       +43  [NEW]
      [NEW]     +42 (anonymous namespace)::grpc_fake_server_credentials::~grpc_fake_server_credentials       +42  [NEW]
      [NEW]     +32 grpc_md_only_test_credentials::~grpc_md_only_test_credentials                            +32  [NEW]
       +44%     +28 [Unmapped]                                                                               +28   +44%
      [NEW]     +24 grpc_md_only_test_credentials::cancel_get_request_metadata                               +24  [NEW]
      [NEW]     +23 grpc_md_only_test_credentials::~grpc_md_only_test_credentials                            +23  [NEW]
      [NEW]      +9 (anonymous namespace)::grpc_fake_channel_credentials::~grpc_fake_channel_credentials      +9  [NEW]
       +12%      +8 grpc_fake_transport_security_server_credentials_create                                    +8   +12%
      +1.8%      +3 grpc_md_only_test_credentials_create                                                      +3  +1.8%
      [NEW]      +2 (anonymous namespace)::grpc_fake_channel_credentials::~grpc_fake_channel_credentials      +2  [NEW]
   +32%    +396 src/core/lib/http/httpcli_security_connector.cc                                         +396   +32%
       +59%    +344 ssl_handshake                                                                           +344   +59%
      [NEW]    +279 grpc_httpcli_ssl_channel_security_connector::check_peer                                 +279  [NEW]
      [NEW]    +160 grpc_httpcli_ssl_channel_security_connector::add_handshakers                            +160  [NEW]
      [NEW]     +55 grpc_httpcli_ssl_channel_security_connector::~grpc_httpcli_ssl_channel_security_conn     +55  [NEW]
      [NEW]     +24 grpc_httpcli_ssl_channel_security_connector::cancel_check_call_host                      +24  [NEW]
      [NEW]     +14 grpc_httpcli_ssl_channel_security_connector::~grpc_httpcli_ssl_channel_security_conn     +14  [NEW]
      [NEW]     +13 grpc_httpcli_ssl_channel_security_connector::check_call_host                             +13  [NEW]
      [NEW]     +13 grpc_httpcli_ssl_channel_security_connector::cmp(grpc_security_connector const*) con     +13  [NEW]
      [NEW]      +9 grpc_call_credentials::~grpc_call_credentials                                             +9  [NEW]
      [NEW]      +9 grpc_channel_credentials::~grpc_channel_credentials                                       +9  [NEW]
      [NEW]      +2 grpc_call_credentials::~grpc_call_credentials                                             +2  [NEW]
      [NEW]      +2 grpc_channel_credentials::~grpc_channel_credentials                                       +2  [NEW]
  +3.9%    +328 [Other]                                                                                 +328  +3.9%
  +9.0%    +192 src/core/ext/transport/chttp2/client/secure/secure_channel_create.cc                    +192  +9.0%
       +15%    +193 client_channel_factory_create_subchannel                                                +193   +15%
   +12%    +192 src/core/lib/security/credentials/jwt/jwt_credentials.cc                                +192   +12%
      [NEW]    +599 grpc_service_account_jwt_access_credentials::get_request_metadata                       +599  [NEW]
      [NEW]    +215 grpc_service_account_jwt_access_credentials::grpc_service_account_jwt_access_credent    +215  [NEW]
      [NEW]     +63 grpc_service_account_jwt_access_credentials::reset_cache                                 +63  [NEW]
      [NEW]     +46 grpc_service_account_jwt_access_credentials::~grpc_service_account_jwt_access_creden     +46  [NEW]
      [NEW]     +24 grpc_service_account_jwt_access_credentials::cancel_get_request_metadata                 +24  [NEW]
      +2.5%     +16 grpc_service_account_jwt_access_credentials_create                                       +16  +2.5%
      [NEW]     +14 grpc_service_account_jwt_access_credentials::~grpc_service_account_jwt_access_creden     +14  [NEW]
       +32%     +11 [Unmapped]                                                                               +11   +32%
   +14%    +112 src/core/lib/security/credentials/iam/iam_credentials.cc                                +112   +14%
      [NEW]    +241 grpc_google_iam_credentials::grpc_google_iam_credentials                                +241  [NEW]
      [NEW]     +26 grpc_google_iam_credentials::get_request_metadata                                        +26  [NEW]
      [NEW]     +24 grpc_google_iam_credentials::cancel_get_request_metadata                                 +24  [NEW]
      [NEW]     +24 grpc_google_iam_credentials::~grpc_google_iam_credentials                                +24  [NEW]
       +86%     +18 [Unmapped]                                                                               +18   +86%
      [NEW]     +14 grpc_google_iam_credentials::~grpc_google_iam_credentials                                +14  [NEW]

 -------------- SHRINKING                                                                            --------------
 -11.4%    -272 src/core/lib/security/credentials/credentials.cc                                        -272 -11.4%
     -52.2%    -120 [Unmapped]                                                                              -120 -52.2%
      [DEL]    -109 grpc_channel_credentials_create_security_connector                                      -109  [DEL]
     -83.5%     -96 grpc_server_credentials_set_auth_metadata_processor                                      -96 -83.5%
      [DEL]     -82 grpc_server_credentials_unref                                                            -82  [DEL]
      [DEL]     -69 grpc_server_credentials_create_security_connector                                        -69  [DEL]
      [DEL]     -58 grpc_call_credentials_unref                                                              -58  [DEL]
      [DEL]     -58 grpc_channel_credentials_unref                                                           -58  [DEL]
      [DEL]     -43 grpc_credentials_metadata_request_create                                                 -43  [DEL]
      [DEL]     -37 grpc_channel_credentials_duplicate_without_call_credentials                              -37  [DEL]
      [DEL]     -30 grpc_credentials_metadata_request_destroy                                                -30  [DEL]
      [DEL]     -30 grpc_call_credentials_get_request_metadata                                               -30  [DEL]
      [DEL]     -26 grpc_call_credentials_cancel_get_request_metadata                                        -26  [DEL]
      [DEL]     -23 grpc_call_credentials_ref                                                                -23  [DEL]
      [DEL]     -23 grpc_server_credentials_ref                                                              -23  [DEL]
      [DEL]     -23 grpc_channel_credentials_ref                                                             -23  [DEL]
  -1.1%     -15 src/core/lib/security/security_connector/security_connector.cc                           -15  -1.1%
      [DEL]    -215 grpc_channel_security_connector_cmp                                                     -215  [DEL]
      [DEL]    -186 grpc_security_connector_check_peer                                                      -186  [DEL]
      [DEL]    -167 grpc_server_security_connector_cmp                                                      -167  [DEL]
      [DEL]    -166 grpc_channel_security_connector_check_call_host                                         -166  [DEL]
      [DEL]     -70 grpc_security_connector_cmp                                                              -70  [DEL]
     -36.4%     -51 [Unmapped]                                                                               -51 -36.4%
      [DEL]     -50 grpc_security_connector_unref                                                            -50  [DEL]
      [DEL]     -40 grpc_channel_security_connector_cancel_check_call_host                                   -40  [DEL]
      [DEL]     -23 grpc_security_connector_ref                                                              -23  [DEL]
      [DEL]     -18 grpc_server_security_connector_add_handshakers                                           -18  [DEL]
      [DEL]     -18 grpc_channel_security_connector_add_handshakers                                          -18  [DEL]

  +4.2% +64.7Ki TOTAL                                                                                +1.11Mi   +10%


****************************************************************

libgrpc++.so

     VM SIZE                                                                                            FILE SIZE
 ++++++++++++++ GROWING                                                                              ++++++++++++++
  +0.4% +1.21Ki [None]                                                                                +254Ki  +3.2%
      +0.4% +1.18Ki [Unmapped]                                                                            +254Ki  +3.2%
      [NEW]     +92 typeinfo name for std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocat     +92  [NEW]
      [NEW]     +56 vtable for std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<grpc     +56  [NEW]
       +21%     +24 [None]                                                                                     0  [ = ]
      [NEW]     +24 typeinfo for std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<gr     +24  [NEW]
   +55% +3.97Ki src/cpp/client/secure_credentials.cc                                                 +3.97Ki   +55%
      [NEW] +2.05Ki grpc_core::RefCounted<grpc_auth_context, grpc_core::NonPolymorphicRefCount>::Unref   +2.05Ki  [NEW]
       +70% +1.08Ki grpc::MetadataCredentialsPluginWrapper::InvokePlugin                                 +1.08Ki   +70%
      [NEW]    +454 grpc_auth_context::~grpc_auth_context                                                   +454  [NEW]
      [NEW]    +200 void std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >    +200  [NEW]
      +208%     +75 grpc::SecureCallCredentials::~SecureCallCredentials                                      +75  +208%
      +208%     +75 grpc::SecureChannelCredentials::~SecureChannelCredentials                                +75  +208%
      +105%     +61 std::_Sp_counted_ptr<grpc::SecureCallCredentials*, (__gnu_cxx::_Lock_policy)2>::_M_d     +61  +105%
      +105%     +61 std::_Sp_counted_ptr<grpc::SecureChannelCredentials*, (__gnu_cxx::_Lock_policy)2>::_     +61  +105%
      +134%     +59 grpc::SecureCallCredentials::~SecureCallCredentials                                      +59  +134%
      +134%     +59 grpc::SecureChannelCredentials::~SecureChannelCredentials                                +59  +134%
      [NEW]      +9 grpc_call_credentials::~grpc_call_credentials                                             +9  [NEW]
      [NEW]      +9 grpc_channel_credentials::~grpc_channel_credentials                                       +9  [NEW]
      +4.1%      +8 grpc::(anonymous namespace)::WrapCallCredentials                                          +8  +4.1%
      +4.1%      +8 grpc::(anonymous namespace)::WrapChannelCredentials                                       +8  +4.1%
      [NEW]      +2 grpc_call_credentials::~grpc_call_credentials                                             +2  [NEW]
      [NEW]      +2 grpc_channel_credentials::~grpc_channel_credentials                                       +2  [NEW]
  +158% +2.61Ki src/cpp/common/secure_auth_context.cc                                                +2.61Ki  +158%
     +77e2% +1.36Ki grpc::SecureAuthContext::~SecureAuthContext                                          +1.36Ki +77e2%
     +33e2% +1.31Ki grpc::SecureAuthContext::~SecureAuthContext                                          +1.31Ki +33e2%
      [NEW]    +200 void std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >    +200  [NEW]
  +685% +1.86Ki src/cpp/common/secure_create_auth_context.cc                                         +1.86Ki  +685%
      [NEW] +1.35Ki std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<grpc::SecureAut +1.35Ki  [NEW]
      +249%    +495 grpc::CreateAuthContext                                                                 +495  +249%
      [NEW]     +52 std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<grpc::SecureAut     +52  [NEW]
      [NEW]      +5 std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<grpc::SecureAut      +5  [NEW]
      [NEW]      +5 std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<grpc::SecureAut      +5  [NEW]
      [NEW]      +2 std::_Sp_counted_ptr_inplace<grpc::SecureAuthContext, std::allocator<grpc::SecureAut      +2  [NEW]
   +22% +1.14Ki src/cpp/server/secure_server_credentials.cc                                          +1.14Ki   +22%
       +55% +1.16Ki grpc::AuthMetadataProcessorAyncWrapper::InvokeProcessor                              +1.16Ki   +55%

  +1.9% +10.8Ki TOTAL                                                                                 +264Ki  +3.2%



@grpc-testing
Copy link

[trickle] No significant performance differences

@grpc-testing
Copy link

Objective-C binary sizes
*****************STATIC******************
  New size                      Old size
   737,376       Core (>)        731,780

 2,026,842      Total (>)      2,020,870

***************FRAMEWORKS****************
  New size                      Old size
 4,105,230       Core (>)      3,970,386

11,311,970      Total (>)     11,177,115


@grpc-testing
Copy link

[microbenchmarks] No significant performance differences

@soheilhy
Copy link
Contributor Author

Failures are known flakes: #17132 and #17338

@soheilhy soheilhy merged commit 3c3436d into grpc:master Dec 13, 2018
Core conversion to idiomatic C++ automation moved this from In progress to Done Dec 13, 2018
@lock lock bot locked as resolved and limited conversation to collaborators Mar 13, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
release notes: no Indicates if PR should not be in release notes
Development

Successfully merging this pull request may close these issues.

None yet

5 participants