Nagram/TMessagesProj/jni/voip/webrtc/base
2020-09-30 16:48:47 +03:00
..
allocator Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
android Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
containers Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
debug Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
files Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
hash Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
i18n Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
json Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
memory Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
message_loop Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
metrics Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
nix Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
numerics Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
posix Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
power_monitor Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
process Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
profiler Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
sampling_heap_profiler Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
strings Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
synchronization Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
system Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
task Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
third_party Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
threading Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
time Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
timer Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
trace_event Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
util Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
at_exit.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
at_exit.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
atomic_ref_count.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
atomic_sequence_num.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
atomicops_internals_atomicword_compat.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
atomicops_internals_portable.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
atomicops_internals_x86_msvc.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
atomicops.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
auto_reset.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
barrier_closure.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
barrier_closure.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base64_decode_fuzzer.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base64_encode_fuzzer.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base64.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base64.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base64url.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base64url.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base_export.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base_paths_android.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base_paths_android.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base_paths_fuchsia.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base_paths_fuchsia.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base_paths_mac.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base_paths_mac.mm Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base_paths_posix.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base_paths_posix.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base_paths_win.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base_paths_win.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base_paths.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base_paths.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base_switches.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
base_switches.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
big_endian.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
big_endian.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
bind_helpers.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
bind_internal.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
bind.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
bit_cast.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
bits.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
build_time.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
build_time.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
callback_forward.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
callback_helpers.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
callback_helpers.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
callback_internal.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
callback_internal.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
callback_list.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
callback.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
cancelable_callback.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
check_example.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
command_line.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
command_line.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
compiler_specific.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
component_export.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
cpu.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
cpu.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
critical_closure_internal_ios.mm Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
critical_closure.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
deferred_sequenced_task_runner.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
deferred_sequenced_task_runner.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
enterprise_util_mac.mm Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
enterprise_util_win.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
enterprise_util.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
environment.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
environment.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
export_template.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
feature_list.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
feature_list.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
file_descriptor_posix.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
file_descriptor_store.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
file_descriptor_store.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
file_version_info_mac.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
file_version_info_mac.mm Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
file_version_info_win.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
file_version_info_win.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
file_version_info.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
format_macros.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
gtest_prod_util.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
guid.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
guid.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
immediate_crash.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
lazy_instance_helpers.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
lazy_instance_helpers.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
lazy_instance.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
linux_util.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
linux_util.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
location.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
location.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
logging_win.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
logging_win.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
logging.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
logging.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
macros.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
native_library_fuchsia.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
native_library_ios.mm Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
native_library_mac.mm Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
native_library_posix.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
native_library_win.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
native_library.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
native_library.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
no_destructor.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
observer_list_internal.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
observer_list_internal.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
observer_list_perftest.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
observer_list_threadsafe.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
observer_list_threadsafe.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
observer_list_types.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
observer_list_types.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
observer_list.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
one_shot_event.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
one_shot_event.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
optional.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
os_compat_android.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
os_compat_android.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
os_compat_nacl.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
os_compat_nacl.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
OWNERS Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
parameter_pack.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
path_service.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
path_service.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
pending_task.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
pending_task.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
pickle_fuzzer.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
pickle.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
pickle.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
post_task_and_reply_with_result_internal.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
rand_util_fuchsia.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
rand_util_nacl.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
rand_util_posix.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
rand_util_win.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
rand_util.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
rand_util.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
README.md Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
run_loop.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
run_loop.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
scoped_clear_last_error_win.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
scoped_clear_last_error.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
scoped_generic.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
scoped_native_library.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
scoped_native_library.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
scoped_observer.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
SECURITY_OWNERS Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
sequence_checker_impl.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
sequence_checker_impl.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
sequence_checker.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
sequence_token.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
sequence_token.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
sequenced_task_runner_helpers.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
sequenced_task_runner.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
sequenced_task_runner.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
single_thread_task_runner.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
stl_util.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
supports_user_data.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
supports_user_data.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
sync_socket_nacl.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
sync_socket_posix.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
sync_socket_win.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
sync_socket.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
sync_socket.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
sys_byteorder.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
syslog_logging.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
syslog_logging.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
task_runner_util.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
task_runner.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
task_runner.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
template_util.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
thread_annotations.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
token.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
token.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
traits_bag.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
tuple.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
unguessable_token.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
unguessable_token.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
updateable_sequenced_task_runner.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
value_conversions.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
value_conversions.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
value_iterators.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
value_iterators.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
values.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
values.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
version.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
version.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
vlog.cc Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00
vlog.h Update to 7.1.0 (2090) 2020-09-30 16:48:47 +03:00

What is this

Contains a written down set of principles and other information on //base. Please add to it!

About //base:

Chromium is a very mature project. Most things that are generally useful are already here and things not here aren't generally useful.

Base is pulled into many projects. For example, various ChromeOS daemons. So the bar for adding stuff is that it must have demonstrated wide applicability. Prefer to add things closer to where they're used (i.e. "not base"), and pull into base only when needed. In a project our size, sometimes even duplication is OK and inevitable.

Adding a new logging macro DPVELOG_NE is not more clear than just writing the stuff you want to log in a regular logging statement, even if it makes your calling code longer. Just add it to your own code.

If the code in question does not need to be used inside base, but will have multiple consumers across the codebase, consider placing it in a new directory under components/ instead.

Qualifications for being in //base OWNERS

  • interest and ability to learn low level/high detail/complex c++ stuff
  • inclination to always ask why and understand everything (including external interactions like win32) rather than just hoping the author did it right
  • mentorship/experience
  • demonstrated good judgement (esp with regards to public APIs) over a length of time

Owners are added when a contributor has shown the above qualifications and when they express interest. There isn't an upper bound on the number of OWNERS.

Design and naming

  • Be sure to use the base namespace.
  • STL-like constructs should adhere as closely to STL as possible. Functions and behaviors not present in STL should only be added when they are related to the specific data structure implemented by the container.
  • For STL-like constructs our policy is that they should use STL-like naming even when it may conflict with the style guide. So functions and class names should be lower case with underscores. Non-STL-like classes and functions should use Google naming.

Performance testing

Since the primitives provided by //base are used very widely, it is important to ensure they scale to the necessary workloads and perform well under all supported platforms. The base_perftests target is a suite of synthetic microbenchmarks that measure performance in various scenarios:

  • BasicPostTaskPerfTest: Exercises MessageLoopTaskRunner's multi-threaded queue in isolation.
  • ConditionVariablePerfTest: Measures thread switching cost of condition variables.
  • IntegratedPostTaskPerfTest: Exercises the full MessageLoop/RunLoop machinery.
  • JSONPerfTest: Tests JSONWriter and JSONReader performance.
  • MessageLoopPerfTest: Measures the speed of task posting in various configurations.
  • ObserverListPerfTest: Exercises adding, removing and signalling observers.
  • PthreadEventPerfTest: Establishes the baseline thread switching cost using pthreads.
  • ScheduleWorkTest: Measures the overhead of MessagePump::ScheduleWork.
  • SequenceManagerPerfTest: Benchmarks SequenceManager scheduling with various underlying task runners.
  • TaskObserverPerfTest: Measures the incremental cost of adding task observers.
  • TaskPerfTest: Checks the cost of posting tasks between threads.
  • WaitableEvent{Thread,}PerfTest: Measures waitable events in single and multithreaded scenarios.

Regressions in these benchmarks can generally by caused by 1) operating system changes, 2) compiler version or flag changes or 3) changes in //base code itself.