// Copyright 2025 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

syntax = "proto2";

package perfetto.protos.chrome_enums;

// Note: the protobuf C++ generator puts all enum values directly into the
// containing namespace. In C++ code prefer to shorten long names with an alias
// (eg. `namespace chrome_enums = perfetto::protos::chrome_enums`).

// More detailed process breakdown than content::ProcessType.
enum ProcessType {
  PROCESS_UNSPECIFIED = 0;
  PROCESS_BROWSER = 1;
  PROCESS_RENDERER = 2;
  PROCESS_UTILITY = 3;
  PROCESS_ZYGOTE = 4;
  PROCESS_SANDBOX_HELPER = 5;
  PROCESS_GPU = 6;
  PROCESS_PPAPI_PLUGIN = 7;
  PROCESS_PPAPI_BROKER = 8;
  PROCESS_SERVICE_NETWORK = 9;
  PROCESS_SERVICE_TRACING = 10;
  PROCESS_SERVICE_STORAGE = 11;
  PROCESS_SERVICE_AUDIO = 12;
  PROCESS_SERVICE_DATA_DECODER = 13;
  PROCESS_SERVICE_UTIL_WIN = 14;
  PROCESS_SERVICE_PROXY_RESOLVER = 15;
  PROCESS_SERVICE_CDM = 16;
  PROCESS_SERVICE_VIDEO_CAPTURE = 17;
  PROCESS_SERVICE_UNZIPPER = 18;
  PROCESS_SERVICE_MIRRORING = 19;
  PROCESS_SERVICE_FILEPATCHER = 20;
  PROCESS_SERVICE_TTS = 21;
  PROCESS_SERVICE_PRINTING = 22;
  PROCESS_SERVICE_QUARANTINE = 23;
  PROCESS_SERVICE_CROS_LOCALSEARCH = 24;
  PROCESS_SERVICE_CROS_ASSISTANT_AUDIO_DECODER = 25;
  PROCESS_SERVICE_FILEUTIL = 26;
  PROCESS_SERVICE_PRINTCOMPOSITOR = 27;
  PROCESS_SERVICE_PAINTPREVIEW = 28;
  PROCESS_SERVICE_SPEECHRECOGNITION = 29;
  PROCESS_SERVICE_XRDEVICE = 30;
  PROCESS_SERVICE_READICON = 31;
  PROCESS_SERVICE_LANGUAGEDETECTION = 32;
  PROCESS_SERVICE_SHARING = 33;
  PROCESS_SERVICE_MEDIAPARSER = 34;
  PROCESS_SERVICE_QRCODEGENERATOR = 35;
  PROCESS_SERVICE_PROFILEIMPORT = 36;
  PROCESS_SERVICE_IME = 37;
  PROCESS_SERVICE_RECORDING = 38;
  PROCESS_SERVICE_SHAPEDETECTION = 39;
  PROCESS_RENDERER_EXTENSION = 40;
  PROCESS_SERVICE_MEDIA_FOUNDATION = 41;
}

enum ThreadType {
  THREAD_UNSPECIFIED = 0;

  THREAD_MAIN = 1;
  THREAD_IO = 2;

  THREAD_POOL_BG_WORKER = 3;
  THREAD_POOL_FG_WORKER = 4;
  THREAD_POOL_FG_BLOCKING = 5;
  THREAD_POOL_BG_BLOCKING = 6;
  THREAD_POOL_SERVICE = 7;

  THREAD_COMPOSITOR = 8;
  THREAD_VIZ_COMPOSITOR = 9;
  THREAD_COMPOSITOR_WORKER = 10;

  THREAD_SERVICE_WORKER = 11;
  THREAD_NETWORK_SERVICE = 12;

  THREAD_CHILD_IO = 13;
  THREAD_BROWSER_IO = 14;

  THREAD_BROWSER_MAIN = 15;
  THREAD_RENDERER_MAIN = 16;
  THREAD_UTILITY_MAIN = 17;
  THREAD_GPU_MAIN = 18;

  THREAD_CACHE_BLOCKFILE = 19;
  THREAD_MEDIA = 20;
  THREAD_AUDIO_OUTPUTDEVICE = 21;
  THREAD_AUDIO_INPUTDEVICE = 22;
  THREAD_GPU_MEMORY = 23;
  THREAD_GPU_VSYNC = 24;
  THREAD_DXA_VIDEODECODER = 25;
  THREAD_BROWSER_WATCHDOG = 26;
  THREAD_WEBRTC_NETWORK = 27;
  THREAD_WINDOW_OWNER = 28;
  THREAD_WEBRTC_SIGNALING = 29;
  THREAD_WEBRTC_WORKER = 30;
  THREAD_PPAPI_MAIN = 31;
  THREAD_GPU_WATCHDOG = 32;
  THREAD_SWAPPER = 33;
  THREAD_GAMEPAD_POLLING = 34;
  THREAD_WEBCRYPTO = 35;
  THREAD_DATABASE = 36;
  THREAD_PROXYRESOLVER = 37;
  THREAD_DEVTOOLSADB = 38;
  THREAD_NETWORKCONFIGWATCHER = 39;
  THREAD_WASAPI_RENDER = 40;
  THREAD_LOADER_LOCK_SAMPLER = 41;

  THREAD_MEMORY_INFRA = 50;
  THREAD_SAMPLING_PROFILER = 51;

  THREAD_COMPOSITOR_GPU = 52;
}
