The recent formatter alphebetizing change is causing a lot of noise in
code reviews. Figured it'd be worth a clean-up CL.
Exact command I ran:
find . -name "*.gn*" -exec gn format --in-place "{}" \;
TBR=ddorwin@chromium.org
BUG=554928
CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel
Review URL: https://codereview.chromium.org/1464873002
Cr-Commit-Position: refs/heads/master@{#360891}
The aim is to make scoped_ptr and std::unique_ptr functionally
identical so scoped_ptr can simply be a typedef.
BUG=554298
Review URL: https://codereview.chromium.org/1445003002
Cr-Commit-Position: refs/heads/master@{#360539}
GetUniqueStatement() and GetUntrackedStatement() attempt to be
pedantic about errors preparing statements, because often those errors
indicate either a syntax error in the SQL being prepared, or an error
with the database schema it is being prepared against. That makes
testing code against various other problems like corruption
challenging. This change attempts to restrict the flagged errors to
include fewer errors unrelated to the form of the SQL statement (or
schema).
Additionally, slightly improve the debug output for OnSqliteError()
for databases which haven't been tagged.
BUG=537742
Review URL: https://codereview.chromium.org/1434173003
Cr-Commit-Position: refs/heads/master@{#359452}
With regular I/O, filesystem corruption would cause SQLite to return
SQLITE_IOERR codes. With memory-mapping, filesystem errors can cause a
crash when accessed. There are databases with filesystem corruption,
this CL only enables memory-mapped I/O for parts of the database which
have been successfully read at some point using regular I/O.
BUG=537742
Review URL: https://codereview.chromium.org/1426743006
Cr-Commit-Position: refs/heads/master@{#358672}
SQLite implements a hint to request the databases be truncated or
expanded to multiples of a chunk size. This was originally implemented
to reduce filesystem fragmentation, and it also can improve performance
because file sizes don't vary as much.
For a memory-mapped database, it also reduces the number of calls to
adjust the memory map when the database size changes.
BUG=551108
Review URL: https://codereview.chromium.org/1402373007
Cr-Commit-Position: refs/heads/master@{#358121}
Recovery may be used to recover files with I/O errors, which would not
interact well with memory-mapped I/O.
[AFAICT, SQLite doesn't use memory-mapped I/O on temporary files, but as
of yet I don't see why this might be.]
BUG=551110
Review URL: https://codereview.chromium.org/1414563010
Cr-Commit-Position: refs/heads/master@{#358083}
Follow-up CL to crrev.com/1425793002. Adds an extra |name|
argument to the memory-infra RegisterDumpProvider methods.
This allow to see the names of the dump providers in the trace
and diagnose dump providers getting stuck or taking more time
than usual.
No further behavioral change is introduced by this CL.
BUG=547764
TBR=xhwang@chromium.org,simonhatch@chromium.org,jochen@chromium.org,shess@chromium.org,piman@chromium.org
CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel
Review URL: https://codereview.chromium.org/1406213005
Cr-Commit-Position: refs/heads/master@{#357089}
The ThumbnailDatabase error handler attempts to capture generic data
about the error, which is then uploaded for diagnostics with
DumpWithoutCrashing(). Database with errors which are not repaired
upload new dumps repeatedly. This change adds a tracking file alongside
the database file, which has the dual purpose of recording whether a
previous dump was attempted, and also verifying that files can be
created in the profile directory. If the profile directory is too
broken to create files, then diagnostic data is unlikely to inform a
fix.
BUG=543321,362505,526614,240396
Review URL: https://codereview.chromium.org/1393393007
Cr-Commit-Position: refs/heads/master@{#355632}
The process-wide memory usage statistics of sqlite library is added to
chrome://tracing. The memory usage of sqlite library is mainly through
sqlite_malloc. The total usage of the process is recorded by
sqlite3_memory_used() api. This CL also adds per-connection memory
usage to tracing. Each connection uses memory for cache, schema and
statement, and these usages are recorded. sqlit3_malloc uses malloc
internally to allocate memory. So, thie memory is traced as
sub-allocation from system_allocator(malloc).
This CL lets us keep track of sqlite memory usage in chrome telemetry.
BUG=466141
Review URL: https://codereview.chromium.org/1327063002
Cr-Commit-Position: refs/heads/master@{#353549}
This is a redo of https://codereview.chromium.org/1245873002c6649f2e01
with fix for Official build.
Further reduce the boilerplate in .isolate files and is necessary to add debug
symbols, to be done in a follow up.
Slightly accelerate ninja file parsing by blacklisting more extensions.
sbox_validation_tests wasn't run on Windows since
https://codereview.chromium.org/1212003003/ (~2 months ago). Thankfully this CL
uncovered this copy-paste error.
TBR=jam@chromium.org
BUG=98637
CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel
Review URL: https://codereview.chromium.org/1320793004
Cr-Commit-Position: refs/heads/master@{#347912}
Further reduce the boilerplate in .isolate files and is necessary to add debug
symbols, to be done in a follow up.
Slightly accelerate ninja file parsing by blacklisting more extensions.
sbox_validation_tests wasn't run on Windows since
https://codereview.chromium.org/1212003003/ (~2 months ago). Thankfully this CL
uncovered this copy-paste error.
TBR=jam@chromium.org
BUG=98637
CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel
Review URL: https://codereview.chromium.org/1245873002
Cr-Commit-Position: refs/heads/master@{#347027}
Reason for revert:
Suspected of breaking chromium.webkit Mac builders, see https://code.google.com/p/chromium/issues/detail?id=526208
Summary:
Incompatible library version: httpd requires version 9.0.0 or later, but libsqlite3.dylib provides version 0.0.0
/b/build/slave/WebKit_Mac10_6__dbg_/build/src/out/Debug/libsqlite3.dylib seems to be used instead of expected/intended /usr/lib/libsqlite3.dylib
Original issue's description:
> [sqlite] Respect the gyp and gn component switch.
>
> SQLITE_API is the existing mechanism SQLite provides, and is used in
> preference to inventing a new SQLITE_EXPORT symbol (like
> sql/sql_export.h and other examples).
>
> CoreServices.framework is necessary on OSX because of the Time Machine
> patch.
>
> Remove sql/proxy.{h,cc}, which was necessary to work around SQLite
> linking statically into both component shlibs and unit test executables.
>
> [Relanding https://codereview.chromium.org/1322463002/ ]
>
> BUG=489444
> TBR=michaeln@chromium.org, thakis@chromium.org, brettw@chromium.org
>
> Committed: https://crrev.com/f71db5c36625ff00feb8283028631303ae5caa7c
> Cr-Commit-Position: refs/heads/master@{#346536}
TBR=michaeln@chromium.org,thakis@chromium.org,brettw@chromium.org,shess@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=489444
Review URL: https://codereview.chromium.org/1325833003
Cr-Commit-Position: refs/heads/master@{#346615}
SQLITE_API is the existing mechanism SQLite provides, and is used in
preference to inventing a new SQLITE_EXPORT symbol (like
sql/sql_export.h and other examples).
CoreServices.framework is necessary on OSX because of the Time Machine
patch.
Remove sql/proxy.{h,cc}, which was necessary to work around SQLite
linking statically into both component shlibs and unit test executables.
[Relanding https://codereview.chromium.org/1322463002/ ]
BUG=489444
TBR=michaeln@chromium.org, thakis@chromium.org, brettw@chromium.org
Review URL: https://codereview.chromium.org/1306863006
Cr-Commit-Position: refs/heads/master@{#346536}
Reason for revert:
ARRGH! win8_chromium_gn_dgb is still broken.
Original issue's description:
> [sqlite] Respect the gyp and gn component switch.
>
> SQLITE_API is the existing mechanism SQLite provides, and is used in
> preference to inventing a new SQLITE_EXPORT symbol (like
> sql/sql_export.h and other examples).
>
> CoreServices.framework is necessary on OSX because of the Time Machine
> patch.
>
> Remove sql/proxy.{h,cc}, which was necessary to work around SQLite
> linking statically into both component shlibs and unit test executables.
>
> [Relanding https://codereview.chromium.org/1322463002/ ]
>
> BUG=489444
> TBR=michaeln@chromium.org, thakis@chromium.org
>
> Committed: https://crrev.com/02ce712af589a5b722ebbf5c2fffb3e0d4849963
> Cr-Commit-Position: refs/heads/master@{#346212}
TBR=michaeln@chromium.org,thakis@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=489444
Review URL: https://codereview.chromium.org/1307363007
Cr-Commit-Position: refs/heads/master@{#346213}
SQLITE_API is the existing mechanism SQLite provides, and is used in
preference to inventing a new SQLITE_EXPORT symbol (like
sql/sql_export.h and other examples).
CoreServices.framework is necessary on OSX because of the Time Machine
patch.
Remove sql/proxy.{h,cc}, which was necessary to work around SQLite
linking statically into both component shlibs and unit test executables.
[Relanding https://codereview.chromium.org/1322463002/ ]
BUG=489444
TBR=michaeln@chromium.org, thakis@chromium.org
Review URL: https://codereview.chromium.org/1325513002
Cr-Commit-Position: refs/heads/master@{#346212}
Reason for revert:
Broken build on the Builder: Win x64 GN (dbg).
Failure example: http://build.chromium.org/p/chromium.win/builders/Win%20x64%20GN%20%28dbg%29/builds/8549
Original issue's description:
> [sqlite] Respect the gyp and gn component switch.
>
> SQLITE_API is the existing mechanism SQLite provides, and is used in
> preference to inventing a new SQLITE_EXPORT symbol (like
> sql/sql_export.h and other examples).
>
> CoreServices.framework is necessary on OSX because of the Time Machine
> patch.
>
> Remove sql/proxy.{h,cc}, which was necessary to work around SQLite
> linking statically into both component shlibs and unit test executables.
>
> BUG=489444
>
> Committed: https://crrev.com/4ec68d9ad2d3e0c74967a17946c8bf7ed4450f73
> Cr-Commit-Position: refs/heads/master@{#346151}
TBR=michaeln@chromium.org,shess@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=489444
Review URL: https://codereview.chromium.org/1324523004
Cr-Commit-Position: refs/heads/master@{#346179}
SQLITE_API is the existing mechanism SQLite provides, and is used in
preference to inventing a new SQLITE_EXPORT symbol (like
sql/sql_export.h and other examples).
CoreServices.framework is necessary on OSX because of the Time Machine
patch.
Remove sql/proxy.{h,cc}, which was necessary to work around SQLite
linking statically into both component shlibs and unit test executables.
BUG=489444
Review URL: https://codereview.chromium.org/1322463002
Cr-Commit-Position: refs/heads/master@{#346151}
Previously landed 10-minute, 1-hour, and 1-day histograms. Based on
those I expect 1-week to get around 20% worse.
BUG=489784
Review URL: https://codereview.chromium.org/1316493006
Cr-Commit-Position: refs/heads/master@{#345366}
This will be used to track improvements occuring from enabling
memory-mapped I/O.
BUG=489784
Review URL: https://codereview.chromium.org/1283033004
Cr-Commit-Position: refs/heads/master@{#343100}
Remove StringToLowerASCII. This removes the template and makes a consistent call that can take a string piece.
http_response_headers.cc in HttpResponseHeaders::RemoveHeaderLine there seemed to be a bug where it did
std::string old_header_name_lowercase(name);
where it actually meant
std::string old_header_name_lowercase(old_header_name);
I fixed this.
There were a number of cases where url.host() or url.scheme() was passed to ToLowerASCII. These are already guaranteed lower-case, so I removed the call.
There were a number of cases in net that did return ToLowerASCII().c_str() when the return type is a std::string, which is unnecessary and wasteful. I removed the c_str() call.
NOPRESUBMIT=true
(for touching code with wstrings)
Review URL: https://codereview.chromium.org/1282363003
Cr-Commit-Position: refs/heads/master@{#342869}
Currently, GetHistogramSamplesSinceCreation can return null if no histogram was generated. But that depends also on tests run prior to the current test. This CL changes this to returning empty samples instead, so that independently of previously run tests, the current test always gets the same response even if it does not generate any histograms.
BUG=473689
Review URL: https://codereview.chromium.org/1264123002
Cr-Commit-Position: refs/heads/master@{#341498}
This enables the following tests to be run under
swarming on a GN bot:
- angle_unittests
- accessibility_unittests
- compositor_unittests
- cc_unittests
- ipc_tests
- gl_unittests
- sandbox_linux_unittests
- gn_unittests
- skia_unittests
- sql_unittests
- url_unittests
R=brettw@chromium.org, maruel@chromium.org
BUG=504079
CQ_EXTRA_TRYBOTS=tryserver.chromium.mac:mac_chromium_gn_rel
Review URL: https://codereview.chromium.org/1248673005
Cr-Commit-Position: refs/heads/master@{#339973}
In addition to saving the cookies to the file system service (per the
previous patch), we also modify the filesystem service to take a
client. When the shell connection to the file system service is broken,
instead of quitting immediately, we broadcast a shutdown notification to
all of our clients, and wait for them to close the directory objects.
This solves the timing problems during shutdown.
BUG=493311
TBR=shess@chromium.orgR=jam@chromium.org,erikwright@chromium.org
First Review URL: https://codereview.chromium.org/1179413010
Review URL: https://codereview.chromium.org/1231493002
Cr-Commit-Position: refs/heads/master@{#338888}
Change "Separator" from string to StringPIece (most are constants). Remove char versions for symmetry with SplitString.
Update callers who pass empty separators to use a base::StringPiece()
Change chromecast/base/metrics/cast_metrics_helper.cc to not use JoinString at all and just append to the output (code is simpler and faster).
TBR=zelidrag@chromium.org for chromeos
Committed: https://crrev.com/0eabfa001ba06d3c66992b95b69a988ef0633992
Cr-Commit-Position: refs/heads/master@{#338762}
patch from issue 1223153003 at patchset 160001 (http://crrev.com/1223153003#ps160001)
BUG=
Review URL: https://codereview.chromium.org/1230243005
Cr-Commit-Position: refs/heads/master@{#338819}
Change "Separator" from string to StringPIece (most are constants). Remove char versions for symmetry with SplitString.
Update callers who pass empty separators to use a base::StringPiece()
Change chromecast/base/metrics/cast_metrics_helper.cc to not use JoinString at all and just append to the output (code is simpler and faster).
TBR=zelidrag@chromium.org for chromeos
Review URL: https://codereview.chromium.org/1223153003
Cr-Commit-Position: refs/heads/master@{#338762}