1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public
3 * License, v. 2.0. If a copy of the MPL was not distributed with this
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 include protocol PGMPContent;
8 include protocol PGMPTimer;
9 include protocol PGMPStorage;
10 include protocol PProfiler;
13 [MoveOnly] using mozilla::UntrustedModulesData from "mozilla/UntrustedModulesData.h";
14 [MoveOnly] using mozilla::ModulePaths from "mozilla/UntrustedModulesData.h";
15 [MoveOnly] using mozilla::ModulesMapResult from "mozilla/UntrustedModulesData.h";
18 include "mozilla/ipc/ByteBufUtils.h";
19 include "GMPParent.h";
22 using mozilla::dom::NativeThreadId from "mozilla/dom/NativeThreadId.h";
27 [NeedsOtherPid, NestedUpTo=inside_sync, ChildImpl="GMPChild", ParentImpl="GMPParent", ChildProc=GMPlugin]
34 async InitCrashReporter(NativeThreadId threadId);
38 async PGMPContentChildDestroyed();
40 // Sent from time-to-time to limit the amount of telemetry vulnerable to loss
41 // Buffer contains bincoded Rust structs.
42 // https://firefox-source-docs.mozilla.org/toolkit/components/glean/dev/ipc.html
43 async FOGData(ByteBuf buf);
46 async GetModulesTrust(ModulePaths aModPaths, bool aRunAtNormalPriority)
47 returns (ModulesMapResult? modMapResult);
48 #endif // defined(XP_WIN)
51 async CrashPluginNow();
52 [Nested=inside_sync] sync StartPlugin(nsString adapter);
53 async ProvideStorageId(nsCString storageId);
54 async PreloadLibs(nsCString libs);
56 async InitGMPContentChild(Endpoint<PGMPContentChild> endpoint);
57 async InitProfiler(Endpoint<PProfilerChild> endpoint);
58 async PreferenceUpdate(Pref pref);
60 // Tells the GMP process to flush any pending telemetry.
61 // Used in tests and ping assembly. Buffer contains bincoded Rust structs.
62 // https://firefox-source-docs.mozilla.org/toolkit/components/glean/dev/ipc.html
63 async FlushFOGData() returns (ByteBuf buf);
66 async InitDllServices(bool canRecordReleaseTelemetry,
67 bool aIsReadyForBackgroundProcessing);
69 async GetUntrustedModulesData() returns (UntrustedModulesData? data);
72 * This method is used to notify a child process to start
73 * processing module loading events in UntrustedModulesProcessor.
74 * This should be called when the parent process has gone idle.
76 async UnblockUntrustedModulesThread();
77 #endif // defined(XP_WIN)
80 // Asks the GMP process to trigger test-only instrumentation.
81 // The unused returned value is to have a promise we can await.
82 async TestTriggerMetrics() returns (bool unused);
84 // Attempt a graceful shutdown and collect a profile if available.
85 async Shutdown() returns (nsCString profile);
89 } // namespace mozilla