arm - PLD指令的使用

标签 arm cpu-cache mmu cortex-a8

我对ARM Cortex A8中PLD指令的使用有一些疑问。由于我在循环内使用指令,因此可能存在越界内存访问。我怀疑这是否会导致段错误。我在ARM manual which states that中读到

Because a PLD instruction is handled as any other load instruction by all levels of cache, the PLD instruction follows standard data-dependency rules and eviction procedures. During any stage of PLD execution, the PLD instruction is ignored in case of an address translation fault, a cache hit, or an abort.

因此,如果进行越界内存访问,相应的 PLD 指令是否会被忽略是我的疑问。

最佳答案

PLD 指令不会产生段错误。如果 PLD 要求内存系统访问不存在的内存区域,则会被忽略。

来自 ARM ARM

The Preload instructions are hints, and so implementations can treat them as NOPs without affecting the functional behavior of the device. The instructions do not generate synchronous Data Abort exceptions, but the memory system operations might, under exceptional circumstances, generate asynchronous aborts.

...

However, a memory operation performed as a result of one of these memory system hints might trigger an asynchronous event, so influencing the execution of the processor. Examples of the asynchronous events that might be triggered are asynchronous aborts and interrupts.

关于arm - PLD指令的使用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13139872/

相关文章:

c - 我如何在c中在运行时定义一个函数

performance - L2 取指令未命中远高于 L1 取指令未命中

c - x86指令缓存是如何同步的?

profiler - 在 x86-64 中测量 TLB 未命中处理成本

c - 设置边界保护数组

c - 将 C 语言翻译成 ARM 汇编语言

arm - 如何在不按住启动键的情况下从 SD 卡启动 NanoPC-T2 (FriendlyARM)?

linux - Boost 交叉编译 arm,尽管在 user-config.jam 中有定义,但工具集未被识别

linux - 无法使用 linux perf 对硬件缓存事件进行采样

linux - 了解 pmap 输出