`_remote_debugging`: `RemoteUnwinder(..., jit=True)`
还没有人认领这个 Issue。
- 主要语言
- Python
- 星标
- 77.2k
- 派生
- 35.9k
- PR 合并指标
- PR 指标待抓取
描述
Feature or enhancement
Proposal:
:)
The idea here is to expose JIT internals a bit more in the Tachyon profiler.
The questions that could be answered trivially:
- Is JIT actually used? How often?
- Which executor is hot?
- What change made the largest difference (
diff_flamegraph), in terms of % spent in JIT? Per line?
A bit harder:
- Which UOPs actually eat time?
- Which stensils are good?
- What guards or deopts are bad?
- What is the trace shape?
The very minimal change that I'm thinking about here is just adding --jit flag (active for --jsonl and maybe for --live but it's a catnip), and adding JitInfo to ThreadInfo.
That's how it could look:
JitInfo(
executor_id,
flags
)
This will requires extending debug offsets, obviously.
We could potentially expose native_pc, native_offset, uop_index, exit_index etc. The question would be how to expose metadata for it without balooning JitInfo, and how far we can get without blocking and native unwinding. :)
I'm pretty much open to any other ideas.
There will be definitely some performance impact (more VM reads), but hidden behind the --enable-experimental-jit flag should be bearable, and we could be more playful, going back and forth.
If you think it makes sense, I'd be willing to take a shot, but this will take multiple PRs.
Has this already been discussed elsewhere?
No response given
Links to previous discussion of this feature:
No response
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
首先跟踪 _remote_debugging、RemoteUnwinder(..., jit=True) 以及现有的 ThreadInfo 流程。比较针对 --jsonl 以及可能的 --live 所提议的 --jit 行为,然后检查调试偏移量的处理方式。完成的要求是确定在 --enable-experimental-jit 后面公开 JitInfo 及其元数据的范围,同时考虑性能影响。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- python
- 领域
- devtools, performance
- Issue 类型
- 功能
- 难度
- 5/5
- 预计耗时
- 一周以上
- 活跃度
- 冷清
- 描述清晰度
- 需要澄清
- 新手友好度
- 25/100