• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..03-May-2022-

allocator/H03-May-2022-20,72514,170

android/H16-Feb-2021-58,08039,787

containers/H16-Feb-2021-17,08911,352

debug/H03-May-2022-12,1027,916

files/H03-May-2022-23,96416,564

fuchsia/H16-Feb-2021-2,9371,894

functional/H16-Feb-2021-350194

hash/H16-Feb-2021-2,0671,297

i18n/H03-May-2022-8,7015,870

ios/H16-Feb-2021-1,7811,247

json/H16-Feb-2021-5,6724,047

mac/H16-Feb-2021-8,3555,760

memory/H03-May-2022-13,8038,977

message_loop/H03-May-2022-9,2605,920

metrics/H16-Feb-2021-23,02314,833

nix/H16-Feb-2021-498339

numerics/H03-May-2022-3,9592,990

posix/H03-May-2022-1,5991,022

power_monitor/H16-Feb-2021-1,503973

process/H03-May-2022-14,7119,872

profiler/H03-May-2022-12,2457,756

ranges/H16-Feb-2021-7,1644,042

sampling_heap_profiler/H03-May-2022-1,8941,288

strings/H03-May-2022-16,01911,014

synchronization/H03-May-2022-5,0263,067

system/H03-May-2022-2,5721,815

task/H16-Feb-2021-52,27335,106

test/H03-May-2022-36,84124,400

third_party/H16-Feb-2021-55,30135,890

threading/H03-May-2022-18,24911,206

time/H03-May-2022-7,1344,606

timer/H16-Feb-2021-2,4501,530

trace_event/H03-May-2022-28,89920,187

tracing/H16-Feb-2021-11895

util/H16-Feb-2021-5,1433,353

win/H16-Feb-2021-23,91616,390

BUILD.gnH A D03-May-2022150.7 KiB4,1813,941

DEPSH A D16-Feb-2021585 2319

DIR_METADATAH A D16-Feb-202143 43

OWNERSH A D16-Feb-2021989 3728

PRESUBMIT.pyH A D16-Feb-20213.4 KiB10079

README.mdH A D16-Feb-20213.8 KiB8268

SECURITY_OWNERSH A D16-Feb-2021637 1514

at_exit.ccH A D16-Feb-20213.3 KiB11675

at_exit.hH A D16-Feb-20212.7 KiB8737

at_exit_unittest.ccH A D16-Feb-20212.4 KiB8864

atomic_ref_count.hH A D16-Feb-20212.6 KiB7028

atomic_sequence_num.hH A D16-Feb-20211,018 3215

atomicops.hH A D16-Feb-20216.3 KiB15167

atomicops_internals_atomicword_compat.hH A D16-Feb-20213.7 KiB10568

atomicops_internals_portable.hH A D16-Feb-20218.5 KiB220147

atomicops_internals_x86_msvc.hH A D16-Feb-20215.8 KiB180126

atomicops_unittest.ccH A D16-Feb-20217.7 KiB249176

auto_reset.hH A D16-Feb-20211.6 KiB5330

auto_reset_unittest.ccH A D16-Feb-2021844 3420

barrier_closure.ccH A D16-Feb-20211.2 KiB5234

barrier_closure.hH A D16-Feb-2021938 299

barrier_closure_unittest.ccH A D16-Feb-20212.5 KiB8353

base64.ccH A D16-Feb-20211.3 KiB4527

base64.hH A D16-Feb-2021889 3012

base64_decode_fuzzer.ccH A D16-Feb-2021492 169

base64_encode_fuzzer.ccH A D16-Feb-2021977 2816

base64_unittest.ccH A D16-Feb-20211.4 KiB5534

base64url.ccH A D16-Feb-20213.4 KiB10263

base64url.hH A D16-Feb-20211.8 KiB5725

base64url_unittest.ccH A D16-Feb-20213.5 KiB11673

base_export.hH A D16-Feb-2021725 3020

base_paths.ccH A D16-Feb-20211.5 KiB5241

base_paths.hH A D16-Feb-20211.9 KiB5631

base_paths_android.ccH A D16-Feb-20212.2 KiB6745

base_paths_android.hH A D16-Feb-2021687 2611

base_paths_fuchsia.ccH A D16-Feb-20211 KiB4030

base_paths_fuchsia.hH A D16-Feb-2021621 2712

base_paths_mac.hH A D16-Feb-2021575 2510

base_paths_mac.mmH A D16-Feb-20214.6 KiB138123

base_paths_posix.ccH A D03-May-20223.9 KiB12197

base_paths_posix.hH A D16-Feb-2021821 2810

base_paths_win.ccH A D16-Feb-20217.9 KiB216182

base_paths_win.hH A D16-Feb-20212.7 KiB5828

base_switches.ccH A D03-May-20227.2 KiB16447

base_switches.hH A D03-May-20221.9 KiB6548

big_endian.ccH A D16-Feb-20212.7 KiB132103

big_endian.hH A D16-Feb-20214.3 KiB14084

big_endian_unittest.ccH A D16-Feb-20218.2 KiB264211

bind.hH A D16-Feb-202120.9 KiB536246

bind_internal.hH A D16-Feb-202139.2 KiB1,104695

bind_post_task.hH A D16-Feb-20213.7 KiB8628

bind_post_task_internal.hH A D16-Feb-20212.9 KiB8753

bind_post_task_unittest.ccH A D16-Feb-20214.7 KiB159106

bind_post_task_unittest.ncH A D16-Feb-20211,008 3122

bind_unittest.ccH A D16-Feb-202150.8 KiB1,6371,200

bind_unittest.ncH A D16-Feb-202114.6 KiB346271

bit_cast.hH A D16-Feb-20213 KiB7820

bit_cast_unittest.ccH A D16-Feb-2021584 3220

bits.hH A D16-Feb-20217.8 KiB235156

bits_unittest.ccH A D16-Feb-202110.4 KiB278237

build_time.ccH A D16-Feb-2021748 2612

build_time.hH A D16-Feb-2021949 318

build_time_unittest.ccH A D16-Feb-20211.2 KiB4635

callback.hH A D16-Feb-20219.3 KiB229125

callback_forward.hH A D16-Feb-2021792 2914

callback_helpers.ccH A D16-Feb-20211,004 4126

callback_helpers.hH A D16-Feb-20215.9 KiB186110

callback_helpers_unittest.ccH A D16-Feb-20216.3 KiB184140

callback_internal.ccH A D16-Feb-20212.8 KiB10274

callback_internal.hH A D16-Feb-20217.4 KiB219127

callback_list.hH A D16-Feb-202112.5 KiB341156

callback_list_unittest.ccH A D16-Feb-202119.3 KiB607416

callback_list_unittest.ncH A D16-Feb-20211.4 KiB5540

callback_unittest.ccH A D16-Feb-202124.8 KiB723605

callback_unittest.ncH A D16-Feb-20216 KiB145113

cancelable_callback.hH A D16-Feb-20214.9 KiB15781

cancelable_callback_unittest.ccH A D16-Feb-20215.9 KiB206130

check.ccH A D16-Feb-20213.9 KiB11689

check.hH A D16-Feb-20215.7 KiB16082

check_example.ccH A D16-Feb-20211.2 KiB4019

check_op.ccH A D16-Feb-20212 KiB8965

check_op.hH A D16-Feb-202110.1 KiB241152

check_unittest.ccH A D16-Feb-202116.5 KiB482375

command_line.ccH A D16-Feb-202121 KiB626474

command_line.hH A D16-Feb-202110.7 KiB25292

command_line_unittest.ccH A D16-Feb-202121.3 KiB590476

compiler_specific.hH A D16-Feb-202110.9 KiB309158

component_export.hH A D16-Feb-20213.6 KiB7732

component_export_unittest.ccH A D16-Feb-20212 KiB8355

cpu.ccH A D03-May-202219.9 KiB598411

cpu.hH A D03-May-20225.3 KiB161108

cpu_affinity_posix.ccH A D16-Feb-20213.9 KiB136114

cpu_affinity_posix.hH A D16-Feb-20211.6 KiB4317

cpu_affinity_posix_unittest.ccH A D16-Feb-20214.9 KiB13791

cpu_unittest.ccH A D16-Feb-20214.7 KiB170101

critical_closure.hH A D16-Feb-20212.9 KiB9452

critical_closure_internal_ios.mmH A D16-Feb-2021656 2718

dcheck_is_on.hH A D16-Feb-2021378 158

deferred_sequenced_task_runner.ccH A D16-Feb-20214 KiB130101

deferred_sequenced_task_runner.hH A D16-Feb-20213.3 KiB9755

deferred_sequenced_task_runner_unittest.ccH A D16-Feb-20216.9 KiB216178

enterprise_util.hH A D16-Feb-20211.9 KiB6333

enterprise_util_mac.mmH A D16-Feb-20219.3 KiB261221

enterprise_util_mac_unittest.mmH A D16-Feb-20211 KiB3021

enterprise_util_win.ccH A D16-Feb-2021628 227

environment.ccH A D16-Feb-20213.6 KiB12488

environment.hH A D16-Feb-20211.7 KiB6234

environment_unittest.ccH A D16-Feb-20212.8 KiB10359

export_template.hH A D16-Feb-20216.4 KiB14839

feature_list.ccH A D16-Feb-202123 KiB630433

feature_list.hH A D16-Feb-202118.3 KiB385121

feature_list_unittest.ccH A D16-Feb-202130.1 KiB678514

file_descriptor_posix.hH A D16-Feb-20212.3 KiB6226

file_descriptor_store.ccH A D16-Feb-20212.2 KiB7453

file_descriptor_store.hH A D16-Feb-20212.3 KiB7340

file_version_info.hH A D16-Feb-20212.4 KiB7139

file_version_info_mac.hH A D16-Feb-20211.5 KiB4528

file_version_info_mac.mmH A D16-Feb-20212.8 KiB9778

file_version_info_win.ccH A D16-Feb-20216.3 KiB202153

file_version_info_win.hH A D16-Feb-20212.5 KiB7745

file_version_info_win_unittest.ccH A D16-Feb-20216.2 KiB179138

format_macros.hH A D16-Feb-20212.4 KiB9856

gmock_unittest.ccH A D16-Feb-20213.9 KiB13685

gtest_prod_util.hH A D16-Feb-20211.9 KiB6712

guid.ccH A D16-Feb-20214.4 KiB161106

guid.hH A D16-Feb-20213.7 KiB10240

guid_unittest.ccH A D16-Feb-20215.5 KiB168129

immediate_crash.hH A D16-Feb-20216 KiB16961

immediate_crash_unittest.ccH A D16-Feb-20218.9 KiB238145

lazy_instance.hH A D16-Feb-20217.6 KiB21196

lazy_instance_helpers.ccH A D16-Feb-20212.6 KiB6533

lazy_instance_helpers.hH A D16-Feb-20214.6 KiB10242

lazy_instance_unittest.ccH A D16-Feb-202110 KiB322229

linux_util.ccH A D03-May-20226.4 KiB232178

linux_util.hH A D16-Feb-20212.2 KiB5823

linux_util_unittest.ccH A D16-Feb-20212.6 KiB7764

location.ccH A D16-Feb-20213.1 KiB10572

location.hH A D16-Feb-20214.9 KiB14881

location_unittest.ccH A D03-May-20221.4 KiB4429

logging.ccH A D16-Feb-202136.9 KiB1,136842

logging.hH A D16-Feb-202130 KiB742311

logging_chromeos.ccH A D16-Feb-20213.2 KiB9164

logging_unittest.ccH A D03-May-202229 KiB889652

logging_win.ccH A D16-Feb-20214.2 KiB13993

logging_win.hH A D16-Feb-20212.5 KiB8541

macros.hH A D16-Feb-20211.9 KiB4915

native_library.ccH A D16-Feb-2021460 168

native_library.hH A D16-Feb-20214.6 KiB13775

native_library_fuchsia.ccH A D16-Feb-20213.1 KiB9874

native_library_ios.mmH A D16-Feb-20211.2 KiB4836

native_library_mac.mmH A D16-Feb-20214.4 KiB129111

native_library_posix.ccH A D03-May-20222.2 KiB7146

native_library_unittest.ccH A D03-May-20225.4 KiB165108

native_library_win.ccH A D16-Feb-20219.1 KiB259167

no_destructor.hH A D16-Feb-20213.5 KiB9931

no_destructor_unittest.ccH A D16-Feb-20216.9 KiB217140

notreached.ccH A D16-Feb-2021698 2310

notreached.hH A D16-Feb-20211.4 KiB4732

observer_list.hH A D16-Feb-202110.4 KiB348197

observer_list_internal.ccH A D16-Feb-2021688 2112

observer_list_internal.hH A D16-Feb-20215 KiB14899

observer_list_perftest.ccH A D16-Feb-20214.2 KiB12991

observer_list_threadsafe.ccH A D16-Feb-2021492 179

observer_list_threadsafe.hH A D16-Feb-202110 KiB271169

observer_list_threadsafe_unittest.ccH A D16-Feb-202115.3 KiB515359

observer_list_types.ccH A D16-Feb-2021415 178

observer_list_types.hH A D16-Feb-20211.5 KiB4922

observer_list_unittest.ccH A D16-Feb-202129.1 KiB1,066806

observer_list_unittest.ncH A D16-Feb-20211.3 KiB3928

one_shot_event.ccH A D16-Feb-20213.3 KiB10475

one_shot_event.hH A D16-Feb-20213.9 KiB10742

one_shot_event_unittest.ccH A D16-Feb-20215.1 KiB174135

optional.hH A D16-Feb-202132.6 KiB954658

optional_unittest.ccH A D16-Feb-202149 KiB2,2731,824

optional_unittest.ncH A D16-Feb-20215.1 KiB167123

os_compat_android.ccH A D16-Feb-20215.5 KiB17896

os_compat_android.hH A D16-Feb-2021584 229

os_compat_android_unittest.ccH A D16-Feb-20211.4 KiB4220

os_compat_nacl.ccH A D16-Feb-2021587 3121

os_compat_nacl.hH A D16-Feb-2021421 177

parameter_pack.hH A D16-Feb-20212.5 KiB9258

parameter_pack_unittest.ccH A D16-Feb-20212.7 KiB7760

path_service.ccH A D16-Feb-20218.5 KiB348251

path_service.hH A D16-Feb-20213.6 KiB9431

path_service_unittest.ccH A D03-May-202211.1 KiB316245

pending_task.ccH A D16-Feb-20211.3 KiB4422

pending_task.hH A D16-Feb-20212.9 KiB9141

pickle.ccH A D16-Feb-202112.4 KiB447350

pickle.hH A D16-Feb-202114 KiB347158

pickle_fuzzer.ccH A D16-Feb-20213.2 KiB126114

pickle_unittest.ccH A D16-Feb-202116.6 KiB600431

post_task_and_reply_with_result_internal.hH A D16-Feb-20211.1 KiB3821

rand_util.ccH A D16-Feb-20212.4 KiB8353

rand_util.hH A D16-Feb-20212.6 KiB7934

rand_util_fuchsia.ccH A D16-Feb-2021360 167

rand_util_nacl.ccH A D16-Feb-2021684 2818

rand_util_posix.ccH A D16-Feb-20213.2 KiB10660

rand_util_unittest.ccH A D16-Feb-20215.8 KiB171106

rand_util_win.ccH A D16-Feb-20211.1 KiB3924

run_loop.ccH A D16-Feb-202110.9 KiB342227

run_loop.hH A D16-Feb-202114.3 KiB356135

run_loop_unittest.ccH A D16-Feb-202121.4 KiB623435

safe_numerics_unittest.ccH A D16-Feb-202180.1 KiB1,7931,528

scoped_clear_last_error.hH A D16-Feb-20211.8 KiB5931

scoped_clear_last_error_unittest.ccH A D16-Feb-20211.2 KiB5944

scoped_clear_last_error_win.ccH A D16-Feb-2021495 2111

scoped_generic.hH A D16-Feb-202111.7 KiB349174

scoped_generic_unittest.ccH A D16-Feb-20217.6 KiB353254

scoped_multi_source_observation.hH A D16-Feb-20213.3 KiB10446

scoped_multi_source_observation_unittest.ccH A D16-Feb-20216 KiB214160

scoped_native_library.ccH A D16-Feb-20211.2 KiB4125

scoped_native_library.hH A D16-Feb-20212 KiB6530

scoped_native_library_unittest.ccH A D16-Feb-20211.7 KiB4930

scoped_observation.hH A D16-Feb-20212.6 KiB9036

scoped_observation_unittest.ccH A D16-Feb-20213.7 KiB148108

scoped_observer.hH A D16-Feb-20212.6 KiB9044

security_unittest.ccH A D03-May-20227.3 KiB183112

sequence_checker.hH A D16-Feb-20215 KiB13857

sequence_checker_impl.ccH A D16-Feb-20213 KiB9452

sequence_checker_impl.hH A D16-Feb-20212.2 KiB6225

sequence_checker_unittest.ccH A D16-Feb-20219.2 KiB287195

sequence_checker_unittest.ncH A D16-Feb-20211.1 KiB4329

sequence_token.ccH A D16-Feb-20212.7 KiB9770

sequence_token.hH A D16-Feb-20214 KiB11851

sequence_token_unittest.ccH A D16-Feb-20214.2 KiB13492

sequenced_task_runner.ccH A D16-Feb-20211.1 KiB3924

sequenced_task_runner.hH A D16-Feb-20217.5 KiB20252

sequenced_task_runner_helpers.hH A D16-Feb-20211.1 KiB4322

sequenced_task_runner_unittest.ccH A D16-Feb-20213.1 KiB10679

single_thread_task_runner.hH A D16-Feb-20211.4 KiB3713

stl_util.hH A D16-Feb-202125.4 KiB717518

stl_util_unittest.ccH A D16-Feb-202121.6 KiB752616

supports_user_data.ccH A D16-Feb-20212.3 KiB7551

supports_user_data.hH A D16-Feb-20213.3 KiB9851

supports_user_data_unittest.ccH A D16-Feb-20212.3 KiB7853

sync_socket.ccH A D16-Feb-2021851 3216

sync_socket.hH A D16-Feb-20215.1 KiB14669

sync_socket_nacl.ccH A D16-Feb-20211.6 KiB7451

sync_socket_posix.ccH A D16-Feb-20216.7 KiB225158

sync_socket_unittest.ccH A D16-Feb-20215.5 KiB190133

sync_socket_win.ccH A D16-Feb-202110.4 KiB319234

sys_byteorder.hH A D16-Feb-20213.2 KiB137101

sys_byteorder_unittest.ccH A D16-Feb-20213.8 KiB143119

syslog_logging.ccH A D03-May-20224.5 KiB165120

syslog_logging.hH A D16-Feb-20211.8 KiB5428

task_runner.ccH A D16-Feb-20211.8 KiB6842

task_runner.hH A D16-Feb-20216.3 KiB17048

task_runner_unittest.ccH A D16-Feb-20213.8 KiB157112

task_runner_util.hH A D16-Feb-20211.8 KiB5727

task_runner_util_unittest.ccH A D16-Feb-20213.9 KiB158114

template_util.hH A D16-Feb-202111.1 KiB295130

template_util_unittest.ccH A D16-Feb-20217.3 KiB190143

thread_annotations.hH A D16-Feb-202110 KiB26563

thread_annotations_unittest.ccH A D16-Feb-20211.2 KiB5943

thread_annotations_unittest.ncH A D16-Feb-20211.8 KiB7254

token.ccH A D16-Feb-20211.1 KiB4728

token.hH A D16-Feb-20212.7 KiB8947

token_unittest.ccH A D16-Feb-20212 KiB6849

tools_sanity_unittest.ccH A D16-Feb-202112.5 KiB425301

traits_bag.hH A D16-Feb-202110 KiB261119

traits_bag_unittest.ccH A D16-Feb-20216.9 KiB223158

traits_bag_unittest.ncH A D16-Feb-20211.8 KiB5240

tuple.hH A D16-Feb-20214.2 KiB11362

tuple_unittest.ccH A D16-Feb-20213.1 KiB11986

unguessable_token.ccH A D16-Feb-20211.2 KiB4223

unguessable_token.hH A D16-Feb-20214.4 KiB12657

unguessable_token_unittest.ccH A D16-Feb-20214.6 KiB146107

updateable_sequenced_task_runner.hH A D16-Feb-20211 KiB3117

value_iterators.ccH A D16-Feb-20215.9 KiB229158

value_iterators.hH A D16-Feb-20216.3 KiB195131

value_iterators_unittest.ccH A D16-Feb-202110.2 KiB331250

values.ccH A D16-Feb-202147.2 KiB1,6961,307

values.hH A D16-Feb-202144.6 KiB1,028386

values_unittest.ccH A D16-Feb-202191.6 KiB2,5642,094

version.ccH A D16-Feb-20215.9 KiB195134

version.hH A D16-Feb-20212.6 KiB7834

version_unittest.ccH A D16-Feb-20215.7 KiB224193

vlog.ccH A D16-Feb-20215.1 KiB182141

vlog.hH A D16-Feb-20212.6 KiB7728

vlog_unittest.ccH A D16-Feb-20214.7 KiB12494

README.md

1# What is this
2Contains a written down set of principles and other information on //base.
3Please add to it!
4
5## About //base:
6
7Chromium is a very mature project. Most things that are generally useful are
8already here and things not here aren't generally useful.
9
10The bar for adding stuff to base is that it must have demonstrated wide
11applicability. Prefer to add things closer to where they're used (i.e. "not
12base"), and pull into base only when needed. In a project our size,
13sometimes even duplication is OK and inevitable.
14
15Adding a new logging macro `DPVELOG_NE` is not more clear than just
16writing the stuff you want to log in a regular logging statement, even
17if it makes your calling code longer. Just add it to your own code.
18
19If the code in question does not need to be used inside base, but will have
20multiple consumers across the codebase, consider placing it in a new directory
21under components/ instead.
22
23base is written for the Chromium project and is not intended to be used
24outside it.  Using base outside of src.git is explicitly not supported,
25and base makes no guarantees about API (or even ABI) stability (like all
26other code in Chromium).  New code that depends on base/ must be in
27src.git. Code that's not in src.git but pulled in through DEPS (for
28example, v8) cannot use base.
29
30## Qualifications for being in //base OWNERS
31  * interest and ability to learn low level/high detail/complex c++ stuff
32  * inclination to always ask why and understand everything (including external
33    interactions like win32) rather than just hoping the author did it right
34  * mentorship/experience
35  * demonstrated good judgement (esp with regards to public APIs) over a length
36    of time
37
38Owners are added when a contributor has shown the above qualifications and
39when they express interest. There isn't an upper bound on the number of OWNERS.
40
41## Design and naming
42  * Be sure to use the base namespace.
43  * STL-like constructs should adhere as closely to STL as possible. Functions
44    and behaviors not present in STL should only be added when they are related
45    to the specific data structure implemented by the container.
46  * For STL-like constructs our policy is that they should use STL-like naming
47    even when it may conflict with the style guide. So functions and class names
48    should be lower case with underscores. Non-STL-like classes and functions
49    should use Google naming.
50
51## Performance testing
52
53Since the primitives provided by //base are used very widely, it is important to
54ensure they scale to the necessary workloads and perform well under all
55supported platforms. The `base_perftests` target is a suite of
56synthetic microbenchmarks that measure performance in various scenarios:
57
58  * BasicPostTaskPerfTest: Exercises MessageLoopTaskRunner's multi-threaded
59    queue in isolation.
60  * ConditionVariablePerfTest: Measures thread switching cost of condition
61    variables.
62  * IntegratedPostTaskPerfTest: Exercises the full MessageLoop/RunLoop
63    machinery.
64  * JSONPerfTest: Tests JSONWriter and JSONReader performance.
65  * MessageLoopPerfTest: Measures the speed of task posting in various
66    configurations.
67  * ObserverListPerfTest: Exercises adding, removing and signalling observers.
68  * PthreadEventPerfTest: Establishes the baseline thread switching cost using
69    pthreads.
70  * ScheduleWorkTest: Measures the overhead of MessagePump::ScheduleWork.
71  * SequenceManagerPerfTest: Benchmarks SequenceManager scheduling with various
72    underlying task runners.
73  * TaskObserverPerfTest: Measures the incremental cost of adding task
74    observers.
75  * TaskPerfTest: Checks the cost of posting tasks between threads.
76  * WaitableEvent{Thread,}PerfTest: Measures waitable events in single and
77    multithreaded scenarios.
78
79Regressions in these benchmarks can generally by caused by 1) operating system
80changes, 2) compiler version or flag changes or 3) changes in //base code
81itself.
82