The Android NTP page and omnibox suggestions launch a process for each
image that needs decoding. This can lead to launching many processes on
startup or while typing in the omnibox. Process launching is very
expensive on Android, so this patch batches these decode requests
together to use the same process.
Bug: 1322594
Change-Id: If4872ff85df2753a7e59e660f031a8ffe7a84147
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3628164
Reviewed-by: Carlos Knippschild <carlosk@chromium.org>
Reviewed-by: Marc Treib <treib@chromium.org>
Reviewed-by: Robert Sesek <rsesek@chromium.org>
Reviewed-by: Kristi Park <kristipark@chromium.org>
Commit-Queue: Clark DuVall <cduvall@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1000128}
This CL is a no-op.
Only fixing instances where base::Time (and Ticks/Delta) is used in
a statement (i.e. not as a parameter to avoid adding includes in mere
overrides). Skipping pointer and reference qualified instances.
i.e. matches this regex:
'(\n *[^/\n][^/\n][^/\n]*base::(Time|Thread)(Ticks|Delta)?\b[^*&][^)]*;)'
and skipping files that have any existing fwd-decl for any of the
variants.
This is a prereq to remove unused base/task/post_task.h includes in
https://chromium-review.googlesource.com/c/chromium/src/+/3555247
Bug: 1026641
Change-Id: I87b43a8dc92bdceb67f4bd59b327b54813aa72a6
AX-Relnotes: n/a.
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3557354
Commit-Queue: Gabriel Charette <gab@chromium.org>
Auto-Submit: Gabriel Charette <gab@chromium.org>
Reviewed-by: Daniel Cheng <dcheng@chromium.org>
Commit-Queue: Daniel Cheng <dcheng@chromium.org>
Owners-Override: Daniel Cheng <dcheng@chromium.org>
Cr-Commit-Position: refs/heads/main@{#987283}
GetList() will be reimplemented in a future CL with an updated
signature, so existing uses need to be renamed out of the way.
Unlike TakeList() and TakeDict(), GetList() is used quite widely. This
CL migrates a number of uses using the following set of automated steps:
sed -i "s|\.GetList()|.GetListDeprecated()|g" \
$(git gs "GetList()" --name-only)
git checkout -- base/values.cc base/values.h
git checkout -- base/values_unittest.cc third_party/dom_distiller_js
git checkout -- tools/clang
git cl format
Bug: 1291666
Change-Id: I0413b4857cbf38943333988e36da53f44aab7a15
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3435727
Reviewed-by: danakj chromium <danakj@chromium.org>
Commit-Queue: danakj chromium <danakj@chromium.org>
Owners-Override: danakj chromium <danakj@chromium.org>
Cr-Commit-Position: refs/heads/main@{#966793}
GetList() will be reimplemented in a future CL with an updated
signature, so existing uses need to be renamed out of the way.
Unlike TakeList() and TakeDict(), GetList() is used quite widely. This
CL migrates a number of uses using the following set of automated steps:
sed -i "s|->GetList()|->GetListDeprecated()|g" \
$(git gs "GetList()" --name-only)
git checkout -- base/values_unittest.cc third_party/dom_distiller_js
git cl format
Bug: 1291666
Change-Id: I1b7a92fcb4874e7afb82d4bd092c1c9de2cc3d05
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3430698
Reviewed-by: danakj chromium <danakj@chromium.org>
Owners-Override: danakj chromium <danakj@chromium.org>
Commit-Queue: Daniel Cheng <dcheng@chromium.org>
Cr-Commit-Position: refs/heads/main@{#966487}
This patch renames `GURL::GetOrigin()` to
`GURL::DeprecatedGetOriginAsURL()`. A subsequent patch will
reintroduce a `GURL::GetOrigin()` that returns a `url::Origin`
rather than a `GURL`.
This patch was brought to you by sed, followed by a little manual
work to deal with look-alike methods (most notably
`CascadePriority::GetOrigin()` and `NudgeTracker::GetOrigin()`) and
two or three spots that held pointers to GURLs:
```
git grep -n -l ".GetOrigin(" | \
xargs -L1 sed -i '' \
-e 's/\.GetOrigin(/.DeprecatedGetOriginAsURL(/g'
```
Bug: 512374
Change-Id: I03fb290650b8759d9849af0911cad9bdc92a5132
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3220292
Commit-Queue: Mike West <mkwst@chromium.org>
Reviewed-by: Daniel Cheng <dcheng@chromium.org>
Owners-Override: Daniel Cheng <dcheng@chromium.org>
Cr-Commit-Position: refs/heads/main@{#931431}
This CL was generated by using tools/git/move_source_file.py to change
the includes for those files:
base/bind_post_task.h
base/deferred_sequenced_task_runner.h
base/post_task_and_reply_with_result_internal.h
base/sequenced_task_runner.h
base/sequenced_task_runner_helpers.h
base/single_thread_task_runner.h
base/task_runner.h
base/task_runner_util.h
base/updateable_sequenced_task_runner.h
Then formatted using "git cl format". DEPS files were fixed with a
simple search and replace script.
Bug: 1255932
Change-Id: I0d9b5ddd9260fde5e4581e6c6e0080bdb0ed2c44
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3209175
Reviewed-by: Gabriel Charette <gab@chromium.org>
Owners-Override: Gabriel Charette <gab@chromium.org>
Commit-Queue: Gabriel Charette <gab@chromium.org>
Cr-Commit-Position: refs/heads/main@{#929867}
base::ClampToRange will return bogus results if `lo` is greater
than `hi`. This is a source of bugs. Because of this, base::clamp
CHECKs in that case. This CL moves users of base::ClampToRange
over if they pass their tests with base::clamp, preventing
errors in the future.
Bug: 1231569
Change-Id: Id12046d6cab2736f9f3c7df068345394f45fd01c
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3045786
Commit-Queue: Avi Drissman <avi@chromium.org>
Commit-Queue: Daniel Cheng <dcheng@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Daniel Cheng <dcheng@chromium.org>
Reviewed-by: danakj <danakj@chromium.org>
Owners-Override: Daniel Cheng <dcheng@chromium.org>
Owners-Override: Lei Zhang <thestig@chromium.org>
Cr-Commit-Position: refs/heads/master@{#905034}
This is an attempt to remove inactive OWNERS from Chromium.
In 2021 June, I wrote a tool to list potentially inactive OWNERS
in the past six months. I added the list to the spreadsheet
(https://docs.google.com/spreadsheets/d/1vkyGq1lAn_ZhbvzlZvQMKFBLcH9db0xBMFr-ZzWM7no/edit?)
and asked the listed people to flip "Drop me" to "Keep me" if
they want to stay as an OWNER. I sent the reminder email twice.
This CL removes OWNERS who are still marked as "Drop me".
Note: It's possible that someone couldn't respond to my emails
because they were on a long vacation etc. In that case, they can
simply add their name back. haraken@ will LGTM the change.
Bug: None
Change-Id: Iad57f8ea2308fd5c285b0ca79c19690c79f3d6dd
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3010910
Commit-Queue: Kentaro Hara <haraken@chromium.org>
Owners-Override: Kentaro Hara <haraken@chromium.org>
Reviewed-by: Yaron Friedman <yfriedman@chromium.org>
Reviewed-by: Takuto Ikuta <tikuta@chromium.org>
Reviewed-by: Yuki Shiino <yukishiino@chromium.org>
Cr-Commit-Position: refs/heads/master@{#902330}
base::Erase() and base::EraseIf() have been moved to
base/containers/cxx20_erase.h, so .cc files that use these functions,
but no other function from base/stl_util.h, can directly include
cxx20_erase.h and not stl_util.h.
Bug: 1211125
Change-Id: Ia8f213f1136ac4c5278cd096b1270002884b556d
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2994779
Reviewed-by: Colin Blundell <blundell@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
Cr-Commit-Position: refs/heads/master@{#897400}
It is only required for specific GCC versions to work around a compiler
bug. This effectively removes the header from the file from the
perspective of most developers, since they build with Clang.
Then do IWYU for files that are missing STL includes to fix the build.
Change-Id: I3bc9aafdbe2a890d56c4a7d8dc0da26a59dc033d
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2991855
Commit-Queue: Nico Weber <thakis@chromium.org>
Reviewed-by: Nico Weber <thakis@chromium.org>
Owners-Override: Nico Weber <thakis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#896752}
In order to reduce build times, generated mojom.h files will use
forward declarations more aggressively after https://crrev.com/c/2932644
In particular, mojom.h files which define an interface may not provide
full definitions of method parameter types defined in other mojoms.
This reduces the size of those interfaces, but it means that
implementors and callers of such methods may have to include more
headers, as is done in this CL.
Bug: 242216
Change-Id: I2159c9a0bf0d085a49711628132c120318f8b4f5
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2959875
Auto-Submit: Hans Wennborg <hans@chromium.org>
Reviewed-by: Nico Weber <thakis@chromium.org>
Owners-Override: Nico Weber <thakis@chromium.org>
Commit-Queue: Hans Wennborg <hans@chromium.org>
Cr-Commit-Position: refs/heads/master@{#892528}
This way the constructor can be supplied an argument that configures
how signed-in state is treated. This is important for WebLayer as
the signed-in state doesn't make sense, and should be effectively
ignored.
BUG=1148350
TEST=covered by tests
Change-Id: Ia3e2d02ba28df41d3f3160ebd02379875bc1bdb0
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2595519
Reviewed-by: John Abd-El-Malek <jam@chromium.org>
Reviewed-by: Ted Choc <tedchoc@chromium.org>
Reviewed-by: Rohit Rao <rohitrao@chromium.org>
Reviewed-by: John Wu <jzw@chromium.org>
Reviewed-by: Alexei Svitkine <asvitkine@chromium.org>
Commit-Queue: Scott Violet <sky@chromium.org>
Cr-Commit-Position: refs/heads/master@{#889895}
base::size() has been moved to base/cxx17_backports.h, so .cc files that
use base::size(), but no other function from base/stl_util.h, can
directly include base/cxx17_backports.h and not base/stl_util.h.
Bug: 1210983
Change-Id: I445378492ab1193ea76ca0c0b9958e9cb9c4ca0f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2915464
Reviewed-by: Colin Blundell <blundell@chromium.org>
Reviewed-by: Greg Kerr <kerrnel@chromium.org>
Commit-Queue: Greg Kerr <kerrnel@chromium.org>
Auto-Submit: Lei Zhang <thestig@chromium.org>
Cr-Commit-Position: refs/heads/master@{#886365}
Headers that do not reference base::FilePath do not need to include
base/files/file_path.h. This reduces the amount of data necessary to
build the chrome target by 175 MB.
Bug: 242216
Change-Id: I7abd8d9fc1862a2dca11292719ab5b9146ab04d1
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2878909
Reviewed-by: Peter Boström <pbos@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
Owners-Override: Lei Zhang <thestig@chromium.org>
Cr-Commit-Position: refs/heads/master@{#880501}
List of files to delete from generated using the following command:
git grep -l base/strings/stringprintf.h | \
xargs grep -L 'StringPrint[fV]' | xargs grep -L StringAppend | \
grep -E '(cc|mm|h)$'
Change-Id: Ibc72245f08730b4d25283e2d966235b61513c7ae
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2849392
Reviewed-by: Peter Boström <pbos@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
Owners-Override: Lei Zhang <thestig@chromium.org>
Cr-Commit-Position: refs/heads/master@{#876365}