[base] Move the CHECK and CHECK_op macros to more light-weight headers
This provides cheaper (in terms of compile time) alternatives for code that just wants to do a few simple CHECKs without pulling in the full weight of logging.h. On Linux, the preprocessed size of check.h and check_op.h are 2% and 62% of logging.h, respectively. Splitting the CHECK and CHECK_op macros out to separate files also reduces the complexity of logging.h which has become very complicated. As a bonus, the new implementation is leaner, causing a 3% local compile-time reduction for the chrome target on Linux even though no includes have been changed yet. Bug: 1031540 Change-Id: If7aca321f077110bea0907e487d2e8d29a8c50fd Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2128112 Commit-Queue: Nico Weber <thakis@chromium.org> Reviewed-by:Nico Weber <thakis@chromium.org> Cr-Commit-Position: refs/heads/master@{#758287}
Showing
base/check.cc
0 → 100644
base/check.h
0 → 100644
base/check_op.cc
0 → 100644
base/check_op.h
0 → 100644
This diff is collapsed.
Please register or sign in to comment