linux - 英特尔处理器如何访问 Branch Trace Store 缓冲区?

标签 linux linux-kernel x86 kernel intel

intel 处理器具有 Branch Trace Store(BTS)功能,记录分支并将它们存储在用户/程序指定的缓冲区中。其实我想知道处理器是通过MMU单元(页表)访问BTS缓冲区还是直接物理访问BTS缓冲区?

最佳答案

来自 Intel Manual Volume 3, Chapter 17.4.9 (BTS and DS Save Area) Debug Store 区域的 32 位版本的图像

enter image description here

BTS buffer base — Linear address of the first byte of the BTS buffer. This address should point to a natural doubleword boundary.

对于 IA32_DS_AREA MSR

Write the base linear address of the DS buffer management area into the IA32_DS_AREA MSR.


通常,您为处理器设置的每个地址都是线性地址,因此它独立于段集,因此只有在激活时才会发生分页。
当然,只有在不创建递归依赖性的情况下才会如此,例如 CR3 寄存器。

直接回答您的问题:如果激活了分页,则会翻译给定的地址,否则将按原样使用

关于linux - 英特尔处理器如何访问 Branch Trace Store 缓冲区?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31271403/

相关文章:

linux - 如果 git 仓库已经存在,我可以克隆它吗?

linux-kernel - Bootargs 格式以启用 Linux 内核模块的动态调试

linux-kernel - 如何在U-Boot和Linux内核中添加自定义TAG变量?

linux - "call"中的 x86 段错误正常运行

linux - 比较磁盘分区中的两个值,发送 80% 阈值的警报

c++ - 在 C++ 文件中链接 mat.h

linux - 通过评估 CPU 寄存器找出系统锁定时正在执行哪个 Linux 进程

linux - 在 linux 中获取页面的 pte

c - 将变量参数传递给 makecontext 函数

c++ - 在 C++ 中使用内联汇编对缓冲区中的数字求和