Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(217)

Unified Diff: mojo/public/c/system/tests/core_perftest.cc

Issue 1779993002: mojo_public_system_perftests: replace mojo::Thread with base::SimpleThread. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « mojo/public/c/system/tests/BUILD.gn ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/public/c/system/tests/core_perftest.cc
diff --git a/mojo/public/c/system/tests/core_perftest.cc b/mojo/public/c/system/tests/core_perftest.cc
index dc5566e73b194ab4f9c1aec97f65d2022e7739f7..80734d305b5ab91cde8bdac9f3e982a2d04b77e1 100644
--- a/mojo/public/c/system/tests/core_perftest.cc
+++ b/mojo/public/c/system/tests/core_perftest.cc
@@ -10,24 +10,26 @@
#include <stdint.h>
#include <stdio.h>
+#include "base/threading/simple_thread.h"
#include "mojo/public/cpp/system/macros.h"
#include "mojo/public/cpp/test_support/test_support.h"
#include "mojo/public/cpp/test_support/test_utils.h"
#include "testing/gtest/include/gtest/gtest.h"
-// TODO(vtl): (here and below) crbug.com/342893
#if !defined(WIN32)
#include <time.h>
-#include "mojo/public/cpp/utility/thread.h"
#endif // !defined(WIN32)
namespace {
#if !defined(WIN32)
-class MessagePipeWriterThread : public mojo::Thread {
+class MessagePipeWriterThread : public base::SimpleThread {
public:
MessagePipeWriterThread(MojoHandle handle, uint32_t num_bytes)
- : handle_(handle), num_bytes_(num_bytes), num_writes_(0) {}
+ : SimpleThread("MessagePipeWriterThread"),
+ handle_(handle),
+ num_bytes_(num_bytes),
+ num_writes_(0) {}
~MessagePipeWriterThread() override {}
void Run() override {
@@ -62,10 +64,12 @@ class MessagePipeWriterThread : public mojo::Thread {
DISALLOW_COPY_AND_ASSIGN(MessagePipeWriterThread);
};
-class MessagePipeReaderThread : public mojo::Thread {
+class MessagePipeReaderThread : public base::SimpleThread {
public:
explicit MessagePipeReaderThread(MojoHandle handle)
- : handle_(handle), num_reads_(0) {}
+ : SimpleThread("MessagePipeReaderThread"),
+ handle_(handle),
+ num_reads_(0) {}
~MessagePipeReaderThread() override {}
void Run() override {
« no previous file with comments | « mojo/public/c/system/tests/BUILD.gn ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698