Commit b451c942 authored by Xi Cheng's avatar Xi Cheng Committed by Commit Bot

Remove base:: as this is already in namespace base

Change-Id: I32519c87031058bb49b0ab005e4f8128d9502200
Reviewed-on: https://chromium-review.googlesource.com/1087590Reviewed-by: default avatarMike Wittman <wittman@chromium.org>
Commit-Queue: Xi Cheng <chengx@chromium.org>
Cr-Commit-Position: refs/heads/master@{#564664}
parent e5b12863
......@@ -132,7 +132,7 @@ size_t GetModuleIndex(const uintptr_t instruction_pointer,
StackSamplingProfiler::Module module(
reinterpret_cast<uintptr_t>(inf.dli_fbase), GetUniqueId(inf.dli_fbase),
base::FilePath(inf.dli_fname));
FilePath(inf.dli_fname));
modules->push_back(module);
auto base_module_address = reinterpret_cast<uintptr_t>(inf.dli_fbase);
......
......@@ -139,7 +139,7 @@ void RewritePointersToStackMemory(uintptr_t top, uintptr_t bottom,
};
// Rewrite pointers in the context.
for (size_t i = 0; i < base::size(nonvolatile_registers); ++i) {
for (size_t i = 0; i < size(nonvolatile_registers); ++i) {
DWORD64* const reg = &(context->*nonvolatile_registers[i]);
RewritePointerIfInOriginalStack(top, bottom, stack_copy,
reinterpret_cast<const void**>(reg));
......@@ -221,7 +221,7 @@ std::string GetBuildIDForModule(HMODULE module_handle) {
DWORD age;
win::PEImage(module_handle).GetDebugId(&guid, &age, /* pdb_file= */ nullptr);
const int kGUIDSize = 39;
base::string16 build_id;
string16 build_id;
int result =
::StringFromGUID2(guid, WriteInto(&build_id, kGUIDSize), kGUIDSize);
if (result != kGUIDSize)
......@@ -482,7 +482,7 @@ bool NativeStackSamplerWin::GetModuleForHandle(
StackSamplingProfiler::Module* module) {
wchar_t module_name[MAX_PATH];
DWORD result_length =
::GetModuleFileName(module_handle, module_name, base::size(module_name));
::GetModuleFileName(module_handle, module_name, size(module_name));
if (result_length == 0)
return false;
......
......@@ -756,7 +756,7 @@ StackSamplingProfiler::StackSamplingProfiler(
const SamplingParams& params,
const CompletedCallback& callback,
NativeStackSamplerTestDelegate* test_delegate)
: StackSamplingProfiler(base::PlatformThread::CurrentId(),
: StackSamplingProfiler(PlatformThread::CurrentId(),
params,
callback,
test_delegate) {}
......
......@@ -867,7 +867,7 @@ PROFILER_TEST_F(StackSamplingProfilerTest, StopSafely) {
params[1].sampling_interval = TimeDelta::FromMilliseconds(1);
params[1].samples_per_burst = 100000;
SampleRecordedCounter samples_recorded[base::size(params)];
SampleRecordedCounter samples_recorded[size(params)];
TestProfilerInfo profiler_info0(target_thread_id, params[0],
&samples_recorded[0]);
......@@ -1080,7 +1080,7 @@ PROFILER_TEST_F(StackSamplingProfilerTest, SamplerIdleShutdown) {
// happens asynchronously. Watch until the thread actually exits. This test
// will time-out in the case of failure.
while (StackSamplingProfiler::TestAPI::IsSamplingThreadRunning())
PlatformThread::Sleep(base::TimeDelta::FromMilliseconds(1));
PlatformThread::Sleep(TimeDelta::FromMilliseconds(1));
}
// Checks that additional requests will restart a stopped profiler.
......@@ -1189,7 +1189,7 @@ PROFILER_TEST_F(StackSamplingProfilerTest, IdleShutdownAbort) {
// except to wait a reasonable amount of time and then check. Since the
// thread was just running ("perform" blocked until it was), it should
// finish almost immediately and without any waiting for tasks or events.
PlatformThread::Sleep(base::TimeDelta::FromMilliseconds(200));
PlatformThread::Sleep(TimeDelta::FromMilliseconds(200));
EXPECT_TRUE(StackSamplingProfiler::TestAPI::IsSamplingThreadRunning());
// Ensure that it's still possible to run another sampler.
......@@ -1485,7 +1485,7 @@ PROFILER_TEST_F(StackSamplingProfilerTest, MultipleProfilerThreads) {
ProfilerThread profiler_thread2("profiler2", target_thread_id, params2);
profiler_thread1.Start();
profiler_thread2.Start();
PlatformThread::Sleep(base::TimeDelta::FromMilliseconds(10));
PlatformThread::Sleep(TimeDelta::FromMilliseconds(10));
// This will (approximately) synchronize the two threads.
profiler_thread1.Go();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment