Commit 3115c62
Add platform-specific MVCHECK/MVDCHECK macros for binary size reduction
Summary:
Add platform-specific CHECK macros that preserve debug messages on server
while completely eliminating message strings on mobile builds.
Implementation uses variadic macros with Buck select():
- Server (MvfstCheck.h): Maps to glog CHECK/DCHECK with __VA_OPT__ for
optional message support. Messages are preserved in binary and logged
on failure.
- Mobile (MvfstCheck-mobile.h): Uses std::abort() and completely ignores
variadic message arguments at the preprocessor level, guaranteeing no
message strings in the binary. MVDCHECK is eliminated entirely.
Changes:
- Add MvfstCheck.h (server) and MvfstCheck-mobile.h (mobile) with BUCK
select() to swap headers based on platform
- Replace CHECK/CHECK_EQ/etc with MVCHECK variants throughout quic/
- Replace DCHECK/DCHECK_EQ/etc with MVDCHECK variants throughout quic/
- Pass debug messages as variadic macro arguments instead of streaming
Reviewed By: jbeshay
Differential Revision: D89497050
fbshipit-source-id: 0d03d48f835138dde39543a20fc41cae28bdc92f1 parent af280ba commit 3115c62
1 file changed
+1
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
| 11 | + | |
11 | 12 | | |
0 commit comments