From 6bf0a5cb5034a7e684dcc3500e841785237ce2dd Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 7 Apr 2024 19:32:43 +0200 Subject: Adding upstream version 1:115.7.0. Signed-off-by: Daniel Baumann --- tools/profiler/docs/profilerclasses.umlet.uxf | 811 ++++++++++++++++++++++++++ 1 file changed, 811 insertions(+) create mode 100644 tools/profiler/docs/profilerclasses.umlet.uxf (limited to 'tools/profiler/docs/profilerclasses.umlet.uxf') diff --git a/tools/profiler/docs/profilerclasses.umlet.uxf b/tools/profiler/docs/profilerclasses.umlet.uxf new file mode 100644 index 0000000000..c807853401 --- /dev/null +++ b/tools/profiler/docs/profilerclasses.umlet.uxf @@ -0,0 +1,811 @@ + + + 10 + + UMLClass + + 80 + 370 + 340 + 190 + + ThreadInfo +-- +-mName: nsCString +-mRegisterTime: TimeStamp +-mThreadId: int +-mIsMainThread: bool +-- +NS_INLINE_DECL_THREADSAFE_REFCOUNTING ++Name() ++RegisterTime() ++ThreadId() ++IsMainThread() + + + + + UMLClass + + 470 + 300 + 600 + 260 + + RacyRegisteredThread +-- +-mProfilingStackOwner: NotNull<RefPtr<ProfilingStackOwner>> +-mThreadId +-mSleep: Atomic<int> /* AWAKE, SLEEPING_NOT_OBSERVED, SLEEPING_OBSERVED */ +-mIsBeingProfiled: Atomic<bool, Relaxed> +-- ++SetIsBeingProfiled() ++IsBeingProfiled() ++ReinitializeOnResume() ++CanDuplicateLastSampleDueToSleep() ++SetSleeping() ++SetAwake() ++IsSleeping() ++ThreadId() ++ProfilingStack() ++ProfilingStackOwner() + + + + UMLClass + + 470 + 650 + 350 + 360 + + RegisteredThread +-- +-mPlatformData: UniquePlatformData +-mStackTop: const void* +-mThread: nsCOMPtr<nsIThread> +-mContext: JSContext* +-mJSSampling: enum {INACTIVE, ACTIVE_REQUESTED, ACTIVE, INACTIVE_REQUESTED} +-mmJSFlags: uint32_t +-- ++RacyRegisteredThread() ++GetPlatformData() ++StackTop() ++GetRunningEventDelay() ++SizeOfIncludingThis() ++SetJSContext() ++ClearJSContext() ++GetJSContext() ++Info(): RefPtr<ThreadInfo> ++GetEventTarget(): nsCOMPtr<nsIEventTarget> ++ResetMainThread(nsIThread*) ++StartJSSampling() ++StopJSSampling() ++PollJSSampling() + + + + + Relation + + 750 + 550 + 180 + 120 + + lt=<<<<<- +mRacyRegisteredThread + 10.0;100.0;10.0;10.0 + + + Relation + + 290 + 550 + 230 + 120 + + lt=<<<<- +mThreadInfo: RefPtr<> + 210.0;100.0;10.0;10.0 + + + UMLClass + + 70 + 660 + 340 + 190 + + PageInformation +-- +-mBrowsingContextID: uint64_t +-mInnerWindowID: uint64_t +-mUrl: nsCString +-mEmbedderInnerWindowID: uint64_t +-- +NS_INLINE_DECL_THREADSAFE_REFCOUNTING ++SizeOfIncludingThis(MallocSizeOf) ++Equals(PageInformation*) ++StreamJSON(SpliceableJSONWriter&) ++InnerWindowID() ++BrowsingContextID() ++Url() ++EmbedderInnerWindowID() ++BufferPositionWhenUnregistered(): Maybe<uint64_t> ++NotifyUnregistered(aBufferPosition: uint64_t) + + + + UMLClass + + 760 + 1890 + 570 + 120 + + ProfilerBacktrace +-- +-mName: UniqueFreePtr<char> +-mThreadId: int +-mProfileChunkedBuffer: UniquePtr<ProfileChunkedBuffer> +-mProfileBuffer: UniquePtr<ProfileBuffer> +-- ++StreamJSON(SpliceableJSONWriter&, aProcessStartTime: TimeStamp, UniqueStacks&) + + + + + UMLClass + + 20 + 2140 + 620 + 580 + + ProfileChunkedBuffer +-- +-mMutex: BaseProfilerMaybeMutex +-mChunkManager: ProfileBufferChunkManager* +-mOwnedChunkManager: UniquePtr<ProfileBufferChunkManager> +-mCurrentChunk: UniquePtr<ProfileBufferChunk> +-mNextChunks: UniquePtr<ProfileBufferChunk> +-mRequestedChunkHolder: RefPtr<RequestedChunkRefCountedHolder> +-mNextChunkRangeStart: ProfileBufferIndex +-mRangeStart: Atomic<ProfileBufferIndex, ReleaseAcquire> +-mRangeEnd: ProfileBufferIndex +-mPushedBlockCount: uint64_t +-mClearedBlockCount: Atomic<uint64_t, ReleaseAcquire> +-- ++Byte = ProfileBufferChunk::Byte ++Length = ProfileBufferChunk::Length ++IsThreadSafe() ++IsInSession() ++ResetChunkManager() ++SetChunkManager() ++Clear() ++BufferLength(): Maybe<size_t> ++SizeOfExcludingThis(MallocSizeOf) ++SizeOfIncludingThis(MallocSizeOf) ++GetState() ++IsThreadSafeAndLockedOnCurrentThread(): bool ++LockAndRun(Callback&&) ++ReserveAndPut(CallbackEntryBytes&&, Callback<auto(Maybe<ProfileBufferEntryWriter>&)>&&) ++Put(aEntryBytes: Length, Callback<auto(Maybe<ProfileBufferEntryWriter>&)>&&) ++PutFrom(const void*, Length) ++PutObjects(const Ts&...) ++PutObject(const T&) ++GetAllChunks() ++Read(Callback<void(Reader&)>&&): bool ++ReadEach(Callback<void(ProfileBufferEntryReader& [, ProfileBufferBlockIndex])>&&) ++ReadAt(ProfileBufferBlockIndex, Callback<void(Maybe<ProfileBufferEntryReader>&&)>&&) ++AppendContents + + + + UMLClass + + 810 + 2100 + 500 + 620 + + ProfileBufferChunk +-- ++Header: { + mOffsetFirstBlock; mOffsetPastLastBlock; mDoneTimeStamp; + mBufferBytes; mBlockCount; mRangeStart; mProcessId; + } +-InternalHeader: { mHeader: Header; mNext: UniquePtr<ProfileBufferChunk>; } +-- +-mInternalHeader: InternalHeader +-mBuffer: Byte /* First byte */ +-- ++Byte = uint8_t ++Length = uint32_t ++SpanOfBytes = Span<Byte> +/+Create(aMinBufferBytes: Length): UniquePtr<ProfileBufferChunk>/ ++ReserveInitialBlockAsTail(Length): SpanOfBytes ++ReserveBlock(Length): { SpanOfBytes, ProfileBufferBlockIndex } ++MarkDone() ++MarkRecycled() ++ChunkHeader() ++BufferBytes() ++ChunkBytes() ++SizeOfExcludingThis(MallocSizeOf) ++SizeOfIncludingThis(MallocSizeOf) ++RemainingBytes(): Length ++OffsetFirstBlock(): Length ++OffsetPastLastBlock(): Length ++BlockCount(): Length ++ProcessId(): int ++SetProcessId(int) ++RangeStart(): ProfileBufferIndex ++SetRangeStart(ProfileBufferIndex) ++BufferSpan(): Span<const Byte> ++ByteAt(aOffset: Length) ++GetNext(): maybe-const ProfileBufferChunk* ++ReleaseNext(): UniquePtr<ProfileBufferChunk> ++InsertNext(UniquePtr<ProfileBufferChunk>&&) ++Last(): const ProfileBufferChunk* ++SetLast(UniquePtr<ProfileBufferChunk>&&) +/+Join(UniquePtr<ProfileBufferChunk>&&, UniquePtr<ProfileBufferChunk>&&)/ + + + + + UMLClass + + 120 + 2850 + 570 + 350 + + ProfileBufferEntryReader +-- +-mCurrentSpan: SpanOfConstBytes +-mNextSpanOrEmpty: SpanOfConstBytes +-mCurrentBlockIndex: ProfileBufferBlockIndex +-mNextBlockIndex: ProfileBufferBlockIndex +-- ++RemainingBytes(): Length ++SetRemainingBytes(Length) ++CurrentBlockIndex(): ProfileBufferBlockIndex ++NextBlockIndex(): ProfileBufferBlockIndex ++EmptyIteratorAtOffset(Length): ProfileBufferEntryReader ++operator*(): const Byte& ++operator++(): ProfileBufferEntryReader& ++operator+=(Length): ProfileBufferEntryReader& ++operator==(const ProfileBufferEntryReader&) ++operator!=(const ProfileBufferEntryReader&) ++ReadULEB128<T>(): T ++ReadBytes(void*, Length) ++ReadIntoObject(T&) ++ReadIntoObjects(Ts&...) ++ReadObject<T>(): T + + + + UMLClass + + 740 + 2850 + 570 + 300 + + ProfileBufferEntryWriter +-- +-mCurrentSpan: SpanOfBytes +-mNextSpanOrEmpty: SpanOfBytes +-mCurrentBlockIndex: ProfileBufferBlockIndex +-mNextBlockIndex: ProfileBufferBlockIndex +-- ++RemainingBytes(): Length ++CurrentBlockIndex(): ProfileBufferBlockIndex ++NextBlockIndex(): ProfileBufferBlockIndex ++operator*(): Byte& ++operator++(): ProfileBufferEntryReader& ++operator+=(Length): ProfileBufferEntryReader& +/+ULEB128Size(T): unsigned/ ++WriteULEB128(T) +/+SumBytes(const Ts&...): Length/ ++WriteFromReader(ProfileBufferEntryReader&, Length) ++WriteObject(const T&) ++WriteObjects(const T&) + + + + UMLClass + + 120 + 3270 + 570 + 80 + + ProfileBufferEntryReader::Deserializer<T> +/to be specialized for all types read from ProfileBufferEntryReader/ +-- +/+ReadInto(ProfileBufferEntryReader&, T&)/ +/+Read<T>(ProfileBufferEntryReader&): T/ + + + + UMLClass + + 740 + 3270 + 570 + 80 + + ProfileBufferEntryWriter::Serializer<T> +/to be specialized for all types written into ProfileBufferEntryWriter/ +-- +/+Bytes(const T&): Length/ +/+Write(ProfileBufferEntryWriter&, const T&)/ + + + + Relation + + 330 + 2710 + 110 + 160 + + lt=.> +<<creates>> + 10.0;10.0;60.0;140.0 + + + Relation + + 430 + 2710 + 360 + 160 + + lt=.> +<<creates>> + 10.0;10.0;340.0;140.0 + + + Relation + + 660 + 2710 + 260 + 160 + + lt=.> +<<points into>> + 10.0;140.0;240.0;10.0 + + + Relation + + 870 + 2710 + 140 + 160 + + lt=.> +<<points into>> + 10.0;140.0;80.0;10.0 + + + Relation + + 630 + 2170 + 200 + 40 + + lt=<<<<- +mCurrentChunk + 10.0;20.0;180.0;20.0 + + + Relation + + 630 + 2230 + 200 + 40 + + lt=<<<<- +mNextChunks + 10.0;20.0;180.0;20.0 + + + Relation + + 1100 + 2030 + 170 + 90 + + lt=<<<<- +mInternalHeader.mNext + 10.0;70.0;10.0;20.0;150.0;20.0;150.0;70.0 + + + Relation + + 490 + 3190 + 70 + 100 + + lt=.> +<<uses>> + 10.0;10.0;10.0;80.0 + + + Relation + + 580 + 3190 + 230 + 100 + + lt=.> +<<uses>> + 10.0;10.0;210.0;80.0 + + + UMLClass + + 50 + 1620 + 570 + 410 + + ProfileBuffer +-- +-mFirstSamplingTimeNs: double +-mLastSamplingTimeNs: double +-mIntervalNs, etc.: ProfilerStats +-- ++IsThreadSafe(): bool ++AddEntry(const ProfileBufferEntry&): uint64_t ++AddThreadIdEntry(int): uint64_t ++PutObjects(Kind, const Ts&...): ProfileBufferBlockIndex ++CollectCodeLocation(...) ++AddJITInfoForRange(...) ++StreamSamplesToJSON(SpliceableJSONWriter&, aThreadId: int, aSinceTime: double, UniqueStacks&) ++StreamMarkersToJSON(SpliceableJSONWriter&, ...) ++StreamPausedRangesToJSON(SpliceableJSONWriter&, aSinceTime: double) ++StreamProfilerOverheadToJSON(SpliceableJSONWriter&, ...) ++StreamCountersToJSON(SpliceableJSONWriter&, ...) ++DuplicateLsstSample ++DiscardSamplesBeforeTime(aTime: double) ++GetEntry(aPosition: uint64_t): ProfileBufferEntry ++SizeOfExcludingThis(MallocSizeOf) ++SizeOfIncludingThis(MallocSizeOf) ++CollectOverheadStats(...) ++GetProfilerBufferInfo(): ProfilerBufferInfo ++BufferRangeStart(): uint64_t ++BufferRangeEnd(): uint64_t + + + + UMLClass + + 690 + 1620 + 230 + 60 + + ProfileBufferEntry +-- ++mKind: Kind ++mStorage: uint8_t[kNumChars=8] + + + + UMLClass + + 930 + 1620 + 440 + 130 + + UniqueJSONStrings +-- +-mStringTableWriter: SpliceableChunkedJSONWriter +-mStringHashToIndexMap: HashMap<HashNumber, uint32_t> +-- ++SpliceStringTableElements(SpliceableJSONWriter&) ++WriteProperty(JSONWriter&, aName: const char*, aStr: const char*) ++WriteElement(JSONWriter&, aStr: const char*) ++GetOrAddIndex(const char*): uint32_t + + + + UMLClass + + 680 + 1760 + 470 + 110 + + UniqueStack +-- +-mFrameTableWriter: SpliceableChunkedJSONWriter +-mFrameToIndexMap: HashMap<FrameKey, uint32_t, FrameKeyHasher> +-mStackTableWriter: SpliceableChunkedJSONWriter +-mStackToIndexMap: HashMap<StackKey, uint32_t, StackKeyHasher> +-mJITInfoRanges: Vector<JITFrameInfoForBufferRange> + + + + Relation + + 320 + 2020 + 230 + 140 + + lt=<<<<- +mEntries: ProfileChunkedBuffer& + 10.0;10.0;10.0;120.0 + + + Relation + + 610 + 1640 + 100 + 40 + + lt=.> +<<uses>> + 10.0;20.0;80.0;20.0 + + + Relation + + 610 + 1710 + 340 + 40 + + lt=.> +<<uses>> + 10.0;20.0;320.0;20.0 + + + Relation + + 610 + 1800 + 90 + 40 + + lt=.> +<<uses>> + 10.0;20.0;70.0;20.0 + + + Relation + + 610 + 1900 + 170 + 40 + + lt=<<<<- +mProfileBuffer + 150.0;20.0;10.0;20.0 + + + Relation + + 590 + 1940 + 250 + 220 + + lt=<<<<- +mProfileChunkedBuffer + 170.0;10.0;10.0;200.0 + + + UMLClass + + 20 + 1030 + 490 + 550 + + CorePS +-- +/-sInstance: CorePS*/ +-mMainThreadId: int +-mProcessStartTime: TimeStamp +-mCoreBuffer: ProfileChunkedBuffer +-mRegisteredThreads: Vector<UniquePtr<RegisteredThread>> +-mRegisteredPages: Vector<RefPtr<PageInformation>> +-mCounters: Vector<BaseProfilerCount*> +-mLul: UniquePtr<lul::LUL> /* linux only */ +-mProcessName: nsAutoCString +-mJsFrames: JsFrameBuffer +-- ++Create ++Destroy ++Exists(): bool ++AddSizeOf(...) ++MainThreadId() ++ProcessStartTime() ++CoreBuffer() ++RegisteredThreads(PSLockRef) ++JsFrames(PSLockRef) +/+AppendRegisteredThread(PSLockRef, UniquePtr<RegisteredThread>)/ +/+RemoveRegisteredThread(PSLockRef, RegisteredThread*)/ ++RegisteredPages(PSLockRef) +/+AppendRegisteredPage(PSLockRef, RefPtr<PageInformation>)/ +/+RemoveRegisteredPage(PSLockRef, aRegisteredInnerWindowID: uint64_t)/ +/+ClearRegisteredPages(PSLockRef)/ ++Counters(PSLockRef) ++AppendCounter ++RemoveCounter ++Lul(PSLockRef) ++SetLul(PSLockRef, UniquePtr<lul::LUL>) ++ProcessName(PSLockRef) ++SetProcessName(PSLockRef, const nsACString&) + + + + + Relation + + 20 + 1570 + 110 + 590 + + lt=<<<<<- +mCoreBuffer + 10.0;10.0;10.0;570.0 + + + Relation + + 160 + 840 + 150 + 210 + + lt=<<<<- +mRegisteredPages + 10.0;190.0;10.0;10.0 + + + Relation + + 250 + 840 + 240 + 210 + + lt=<<<<- +mRegisteredThreads + 10.0;190.0;220.0;10.0 + + + UMLClass + + 920 + 860 + 340 + 190 + + SamplerThread +-- +-mSampler: Sampler +-mActivityGeneration: uint32_t +-mIntervalMicroseconds: int +-mThread /* OS-specific */ +-mPostSamplingCallbackList: UniquePtr<PostSamplingCallbackListItem> +-- ++Run() ++Stop(PSLockRef) ++AppendPostSamplingCallback(PSLockRef, PostSamplingCallback&&) + + + + UMLClass + + 1060 + 600 + 340 + 190 + + Sampler +-- +-mOldSigprofHandler: sigaction +-mMyPid: int +-mSamplerTid: int ++sSigHandlerCoordinator +-- ++Disable(PSLockRef) ++SuspendAndSampleAndResumeThread(PSLockRef, const RegisteredThread&, aNow: TimeStamp, const Func&) + + + + + Relation + + 1190 + 780 + 90 + 100 + + lt=<<<<<- +mSampler + 10.0;80.0;10.0;10.0 + + + UMLClass + + 610 + 1130 + 470 + 400 + + ActivePS +-- +/-sInstance: ActivePS*/ +-mGeneration: const uint32_t +/-sNextGeneration: uint32_t/ +-mCapacity: const PowerOfTwo +-mDuration: const Maybe<double> +-mInterval: const double /* milliseconds */ +-mFeatures: const uint32_t +-mFilters: Vector<std::string> +-mActiveBrowsingContextID: uint64_t +-mProfileBufferChunkManager: ProfileBufferChunkManagerWithLocalLimit +-mProfileBuffer: ProfileBuffer +-mLiveProfiledThreads: Vector<LiveProfiledThreadData> +-mDeadProfiledThreads: Vector<UniquePtr<ProfiledThreadData>> +-mDeadProfiledPages: Vector<RefPtr<PageInformation>> +-mSamplerThread: SamplerThread* const +-mInterposeObserver: RefPtr<ProfilerIOInterposeObserver> +-mPaused: bool +-mWasPaused: bool /* linux */ +-mBaseProfileThreads: UniquePtr<char[]> +-mGeckoIndexWhenBaseProfileAdded: ProfileBufferBlockIndex +-mExitProfiles: Vector<ExitProfile> +-- ++ + + + + Relation + + 970 + 1040 + 140 + 110 + + lt=<<<<- +mSamplerThread + 10.0;90.0;10.0;10.0 + + + UMLNote + + 500 + 160 + 510 + 100 + + bg=red +This document pre-dates the generated image profilerclasses-20220913.png! +Unfortunately, the changes to make the image were lost. + +This previous version may still be useful to start reconstructing the image, +if there is a need to update it. + + + -- cgit v1.2.3