docs: rebuild Debug API content
This commit is contained in:
@@ -1,33 +1,38 @@
|
||||
# Profiler::MarkEvent
|
||||
|
||||
公开方法,详见头文件声明。
|
||||
记录一个带时间戳的事件标记。
|
||||
|
||||
```cpp
|
||||
void MarkEvent(const char* name, uint64_t timestamp, uint32_t threadId);
|
||||
```
|
||||
|
||||
该方法声明于 `XCEngine/Debug/Profiler.h`,当前页面用于固定 `Profiler` 类目录下的方法级 canonical 路径。
|
||||
## 行为说明
|
||||
|
||||
**参数:**
|
||||
- `name` - 参数语义详见头文件声明。
|
||||
- `timestamp` - 参数语义详见头文件声明。
|
||||
- `threadId` - 参数语义详见头文件声明。
|
||||
当前实现是空函数,不会保存事件,也不会产生输出。
|
||||
|
||||
**返回:** `void` - 无返回值。
|
||||
从接口形状看,它原本应该用于把离散事件插入时间线上,但这一能力目前尚未接入内部样本系统。
|
||||
|
||||
**示例:**
|
||||
## 参数
|
||||
|
||||
- `name` - 事件名称。当前实现不会使用。
|
||||
- `timestamp` - 事件时间戳。当前实现不会使用。
|
||||
- `threadId` - 事件线程 ID。当前实现不会使用。
|
||||
|
||||
## 返回值
|
||||
|
||||
- 无。
|
||||
|
||||
## 线程语义
|
||||
|
||||
- 当前为空实现,无额外线程语义。
|
||||
|
||||
## 示例
|
||||
|
||||
```cpp
|
||||
#include <XCEngine/Debug/Profiler.h>
|
||||
|
||||
void Example() {
|
||||
XCEngine::Debug::Profiler object;
|
||||
// 根据上下文补齐参数后调用 Profiler::MarkEvent(...)。
|
||||
(void)object;
|
||||
}
|
||||
XCEngine::Debug::Profiler::Get().MarkEvent("GPUSubmit", 0, 0);
|
||||
```
|
||||
|
||||
## 相关文档
|
||||
|
||||
- [返回类总览](Profiler.md)
|
||||
- [返回模块目录](../Debug.md)
|
||||
- [返回类型总览](Profiler.md)
|
||||
- [SetMarker](SetMarker.md)
|
||||
|
||||
Reference in New Issue
Block a user