protozero: Remove protozero from the name of files

Second part of:
https://android-review.googlesource.com/c/platform/external/perfetto/+/606697

Script:
mv ./src/protozero/protozero_message_unittest.cc ./src/protozero/message_unittest.cc
mv ./src/protozero/protozero_message.cc ./src/protozero/message.cc
mv ./src/protozero/protozero_message_handle.cc ./src/protozero/message_handle.cc
mv ./src/protozero/protozero_message_handle_unittest.cc ./src/protozero/message_handle_unittest.cc
mv ./include/perfetto/protozero/protozero_message.h ./include/perfetto/protozero/message.h
mv ./include/perfetto/protozero/protozero_message_handle.h ./include/perfetto/protozero/message_handle.h
find . -type f -name '*.h' | grep -v buildtools | grep -v out | while read f; do sed -i 's/protozero_message\.h/message\.h/g' $f; done
find . -type f -name '*.h' | grep -v buildtools | grep -v out | while read f; do sed -i 's/protozero_message_handle\.h/message_handle\.h/g' $f; done
find . -type f -name '*.cc' | grep -v buildtools | grep -v out | while read f; do sed -i 's/protozero_message\.h/message\.h/g' $f; done
find . -type f -name '*.cc' | grep -v buildtools | grep -v out | while read f; do sed -i 's/protozero_message_handle\.h/message_handle\.h/g' $f; done
find . -type f -name '*.gn' | grep -v buildtools | grep -v out | while read f; do sed -i 's/protozero_message/message/g' $f; done
find . -type f -name '*.gn' | grep -v buildtools | grep -v out | while read f; do sed -i 's/protozero_message_handle/message_handle/g' $f; done

Bug: 70386249
Change-Id: Ifdeda80db539070ec2f07466de32f855a7cc85cc
diff --git a/Android.bp b/Android.bp
index 864e38d..0f910c6 100644
--- a/Android.bp
+++ b/Android.bp
@@ -47,9 +47,9 @@
     "src/ipc/unix_socket.cc",
     "src/process_stats/file_utils.cc",
     "src/process_stats/procfs_utils.cc",
+    "src/protozero/message.cc",
+    "src/protozero/message_handle.cc",
     "src/protozero/proto_utils.cc",
-    "src/protozero/protozero_message.cc",
-    "src/protozero/protozero_message_handle.cc",
     "src/protozero/scattered_stream_writer.cc",
     "src/traced/probes/probes.cc",
     "src/traced/probes/probes_producer.cc",
@@ -118,9 +118,9 @@
     "src/ipc/host_impl.cc",
     "src/ipc/service_proxy.cc",
     "src/ipc/unix_socket.cc",
+    "src/protozero/message.cc",
+    "src/protozero/message_handle.cc",
     "src/protozero/proto_utils.cc",
-    "src/protozero/protozero_message.cc",
-    "src/protozero/protozero_message_handle.cc",
     "src/protozero/scattered_stream_writer.cc",
     "src/traced/perfetto_cmd/main.cc",
     "src/traced/perfetto_cmd/perfetto_cmd.cc",
@@ -231,9 +231,9 @@
     "src/ipc/unix_socket.cc",
     "src/process_stats/file_utils.cc",
     "src/process_stats/procfs_utils.cc",
+    "src/protozero/message.cc",
+    "src/protozero/message_handle.cc",
     "src/protozero/proto_utils.cc",
-    "src/protozero/protozero_message.cc",
-    "src/protozero/protozero_message_handle.cc",
     "src/protozero/scattered_stream_writer.cc",
     "src/traced/probes/probes_producer.cc",
     "src/tracing/core/chunked_protobuf_input_stream.cc",
@@ -1815,9 +1815,9 @@
     "src/ipc/host_impl.cc",
     "src/ipc/service_proxy.cc",
     "src/ipc/unix_socket.cc",
+    "src/protozero/message.cc",
+    "src/protozero/message_handle.cc",
     "src/protozero/proto_utils.cc",
-    "src/protozero/protozero_message.cc",
-    "src/protozero/protozero_message_handle.cc",
     "src/protozero/scattered_stream_writer.cc",
     "src/tracing/core/chunked_protobuf_input_stream.cc",
     "src/tracing/core/data_source_config.cc",
@@ -1939,12 +1939,12 @@
     "src/ipc/test/ipc_integrationtest.cc",
     "src/ipc/unix_socket.cc",
     "src/ipc/unix_socket_unittest.cc",
+    "src/protozero/message.cc",
+    "src/protozero/message_handle.cc",
+    "src/protozero/message_handle_unittest.cc",
+    "src/protozero/message_unittest.cc",
     "src/protozero/proto_utils.cc",
     "src/protozero/proto_utils_unittest.cc",
-    "src/protozero/protozero_message.cc",
-    "src/protozero/protozero_message_handle.cc",
-    "src/protozero/protozero_message_handle_unittest.cc",
-    "src/protozero/protozero_message_unittest.cc",
     "src/protozero/scattered_stream_writer.cc",
     "src/protozero/scattered_stream_writer_unittest.cc",
     "src/protozero/test/fake_scattered_buffer.cc",
diff --git a/include/perfetto/ftrace_reader/ftrace_controller.h b/include/perfetto/ftrace_reader/ftrace_controller.h
index 69c174f..32a0f2d 100644
--- a/include/perfetto/ftrace_reader/ftrace_controller.h
+++ b/include/perfetto/ftrace_reader/ftrace_controller.h
@@ -33,7 +33,7 @@
 #include "perfetto/base/task_runner.h"
 #include "perfetto/base/weak_ptr.h"
 #include "perfetto/ftrace_reader/ftrace_config.h"
-#include "perfetto/protozero/protozero_message_handle.h"
+#include "perfetto/protozero/message_handle.h"
 
 namespace perfetto {
 
diff --git a/include/perfetto/protozero/BUILD.gn b/include/perfetto/protozero/BUILD.gn
index 137a966..7b91fe4 100644
--- a/include/perfetto/protozero/BUILD.gn
+++ b/include/perfetto/protozero/BUILD.gn
@@ -18,9 +18,9 @@
   ]
   sources = [
     "contiguous_memory_range.h",
+    "message.h",
+    "message_handle.h",
     "proto_field_descriptor.h",
-    "protozero_message.h",
-    "protozero_message_handle.h",
     "scattered_stream_writer.h",
   ]
 }
diff --git a/include/perfetto/protozero/protozero_message.h b/include/perfetto/protozero/message.h
similarity index 97%
rename from include/perfetto/protozero/protozero_message.h
rename to include/perfetto/protozero/message.h
index a0fb23a..6cfc041 100644
--- a/include/perfetto/protozero/protozero_message.h
+++ b/include/perfetto/protozero/message.h
@@ -14,8 +14,8 @@
  * limitations under the License.
  */
 
-#ifndef INCLUDE_PERFETTO_PROTOZERO_PROTOZERO_MESSAGE_H_
-#define INCLUDE_PERFETTO_PROTOZERO_PROTOZERO_MESSAGE_H_
+#ifndef INCLUDE_PERFETTO_PROTOZERO_MESSAGE_H_
+#define INCLUDE_PERFETTO_PROTOZERO_MESSAGE_H_
 
 #include <assert.h>
 #include <stdint.h>
@@ -236,4 +236,4 @@
 
 }  // namespace protozero
 
-#endif  // INCLUDE_PERFETTO_PROTOZERO_PROTOZERO_MESSAGE_H_
+#endif  // INCLUDE_PERFETTO_PROTOZERO_MESSAGE_H_
diff --git a/include/perfetto/protozero/protozero_message_handle.h b/include/perfetto/protozero/message_handle.h
similarity index 91%
rename from include/perfetto/protozero/protozero_message_handle.h
rename to include/perfetto/protozero/message_handle.h
index c61501a..c5242ee 100644
--- a/include/perfetto/protozero/protozero_message_handle.h
+++ b/include/perfetto/protozero/message_handle.h
@@ -14,12 +14,12 @@
  * limitations under the License.
  */
 
-#ifndef INCLUDE_PERFETTO_PROTOZERO_PROTOZERO_MESSAGE_HANDLE_H_
-#define INCLUDE_PERFETTO_PROTOZERO_PROTOZERO_MESSAGE_HANDLE_H_
+#ifndef INCLUDE_PERFETTO_PROTOZERO_MESSAGE_HANDLE_H_
+#define INCLUDE_PERFETTO_PROTOZERO_MESSAGE_HANDLE_H_
 
 #include <functional>
 
-#include "perfetto/protozero/protozero_message.h"
+#include "perfetto/protozero/message.h"
 
 namespace protozero {
 
@@ -90,4 +90,4 @@
 
 }  // namespace protozero
 
-#endif  // INCLUDE_PERFETTO_PROTOZERO_PROTOZERO_MESSAGE_HANDLE_H_
+#endif  // INCLUDE_PERFETTO_PROTOZERO_MESSAGE_HANDLE_H_
diff --git a/include/perfetto/tracing/core/trace_writer.h b/include/perfetto/tracing/core/trace_writer.h
index 101d6c1..d29930d 100644
--- a/include/perfetto/tracing/core/trace_writer.h
+++ b/include/perfetto/tracing/core/trace_writer.h
@@ -17,7 +17,7 @@
 #ifndef INCLUDE_PERFETTO_TRACING_CORE_TRACE_WRITER_H_
 #define INCLUDE_PERFETTO_TRACING_CORE_TRACE_WRITER_H_
 
-#include "perfetto/protozero/protozero_message_handle.h"
+#include "perfetto/protozero/message_handle.h"
 
 namespace perfetto {
 
diff --git a/src/ftrace_reader/cpu_reader.h b/src/ftrace_reader/cpu_reader.h
index d33992b..de55176 100644
--- a/src/ftrace_reader/cpu_reader.h
+++ b/src/ftrace_reader/cpu_reader.h
@@ -29,7 +29,7 @@
 #include "perfetto/base/scoped_file.h"
 #include "perfetto/base/thread_checker.h"
 #include "perfetto/ftrace_reader/ftrace_controller.h"
-#include "perfetto/protozero/protozero_message.h"
+#include "perfetto/protozero/message.h"
 #include "proto_translation_table.h"
 
 namespace perfetto {
diff --git a/src/protozero/BUILD.gn b/src/protozero/BUILD.gn
index faf5cc7..beb3f1d 100644
--- a/src/protozero/BUILD.gn
+++ b/src/protozero/BUILD.gn
@@ -27,9 +27,9 @@
     "../base",
   ]
   sources = [
+    "message.cc",
+    "message_handle.cc",
     "proto_utils.cc",
-    "protozero_message.cc",
-    "protozero_message_handle.cc",
     "scattered_stream_writer.cc",
   ]
 }
@@ -45,9 +45,9 @@
     "../base",
   ]
   sources = [
+    "message_handle_unittest.cc",
+    "message_unittest.cc",
     "proto_utils_unittest.cc",
-    "protozero_message_handle_unittest.cc",
-    "protozero_message_unittest.cc",
     "scattered_stream_writer_unittest.cc",
     "test/fake_scattered_buffer.cc",
     "test/fake_scattered_buffer.h",
diff --git a/src/protozero/protozero_message.cc b/src/protozero/message.cc
similarity index 97%
rename from src/protozero/protozero_message.cc
rename to src/protozero/message.cc
index 2f69a1d..843f76d 100644
--- a/src/protozero/protozero_message.cc
+++ b/src/protozero/message.cc
@@ -14,12 +14,12 @@
  * limitations under the License.
  */
 
-#include "perfetto/protozero/protozero_message.h"
+#include "perfetto/protozero/message.h"
 
 #include <type_traits>
 
 #include "perfetto/base/logging.h"
-#include "perfetto/protozero/protozero_message_handle.h"
+#include "perfetto/protozero/message_handle.h"
 
 #if __BYTE_ORDER__ != __ORDER_LITTLE_ENDIAN__
 // The memcpy() for float and double below needs to be adjusted if we want to
diff --git a/src/protozero/protozero_message_handle.cc b/src/protozero/message_handle.cc
similarity index 95%
rename from src/protozero/protozero_message_handle.cc
rename to src/protozero/message_handle.cc
index c059411..4fe4f4e 100644
--- a/src/protozero/protozero_message_handle.cc
+++ b/src/protozero/message_handle.cc
@@ -14,11 +14,11 @@
  * limitations under the License.
  */
 
-#include "perfetto/protozero/protozero_message_handle.h"
+#include "perfetto/protozero/message_handle.h"
 
 #include <utility>
 
-#include "perfetto/protozero/protozero_message.h"
+#include "perfetto/protozero/message.h"
 
 namespace protozero {
 
diff --git a/src/protozero/protozero_message_handle_unittest.cc b/src/protozero/message_handle_unittest.cc
similarity index 90%
rename from src/protozero/protozero_message_handle_unittest.cc
rename to src/protozero/message_handle_unittest.cc
index edc0c75..1ca4c28 100644
--- a/src/protozero/protozero_message_handle_unittest.cc
+++ b/src/protozero/message_handle_unittest.cc
@@ -14,10 +14,10 @@
  * limitations under the License.
  */
 
-#include "perfetto/protozero/protozero_message_handle.h"
+#include "perfetto/protozero/message_handle.h"
 
 #include "gtest/gtest.h"
-#include "perfetto/protozero/protozero_message.h"
+#include "perfetto/protozero/message.h"
 
 namespace protozero {
 
diff --git a/src/protozero/protozero_message_unittest.cc b/src/protozero/message_unittest.cc
similarity index 99%
rename from src/protozero/protozero_message_unittest.cc
rename to src/protozero/message_unittest.cc
index 4d707f5..5b24d4e 100644
--- a/src/protozero/protozero_message_unittest.cc
+++ b/src/protozero/message_unittest.cc
@@ -14,8 +14,8 @@
  * limitations under the License.
  */
 
-#include "perfetto/protozero/protozero_message.h"
-#include "perfetto/protozero/protozero_message_handle.h"
+#include "perfetto/protozero/message.h"
+#include "perfetto/protozero/message_handle.h"
 
 #include <limits>
 #include <memory>
diff --git a/src/protozero/protoc_plugin/protozero_generator.cc b/src/protozero/protoc_plugin/protozero_generator.cc
index a3b742d..fa954de 100644
--- a/src/protozero/protoc_plugin/protozero_generator.cc
+++ b/src/protozero/protoc_plugin/protozero_generator.cc
@@ -247,7 +247,7 @@
         "#include <stddef.h>\n"
         "#include <stdint.h>\n\n"
         "#include \"perfetto/protozero/proto_field_descriptor.h\"\n"
-        "#include \"perfetto/protozero/protozero_message.h\"\n",
+        "#include \"perfetto/protozero/message.h\"\n",
         "greeting", greeting, "guard", guard);
     stub_cc_->Print(
         "$greeting$\n"
diff --git a/src/protozero/test/protozero_conformance_unittest.cc b/src/protozero/test/protozero_conformance_unittest.cc
index bb771cc..ed5c6a1 100644
--- a/src/protozero/test/protozero_conformance_unittest.cc
+++ b/src/protozero/test/protozero_conformance_unittest.cc
@@ -19,7 +19,7 @@
 #include <vector>
 
 #include "gtest/gtest.h"
-#include "perfetto/protozero/protozero_message_handle.h"
+#include "perfetto/protozero/message_handle.h"
 #include "src/protozero/test/fake_scattered_buffer.h"
 
 // Autogenerated headers in out/*/gen/
diff --git a/src/tracing/core/trace_writer_impl.h b/src/tracing/core/trace_writer_impl.h
index 13b178c..249e106 100644
--- a/src/tracing/core/trace_writer_impl.h
+++ b/src/tracing/core/trace_writer_impl.h
@@ -19,7 +19,7 @@
 
 #include <forward_list>
 
-#include "perfetto/protozero/protozero_message_handle.h"
+#include "perfetto/protozero/message_handle.h"
 #include "perfetto/protozero/scattered_stream_writer.h"
 #include "perfetto/tracing/core/basic_types.h"
 #include "perfetto/tracing/core/shared_memory_abi.h"