This code relies on some utility functions for handling DMA commands. Enter those functions as dma_utils.s
这段代码依赖于一些实用函数来处理DMA命令。
The spu_mfcdma32() function allows DMA from a 32-bit subset of the PPE's theoretical 64-bit address space which is plenty for our purposes.
spu_mfcdma32()函数允许从PPE的(理论上)64位地址空间中的32 位子集中使用DMA 方式获取数据,这对于我们的目的来说已经足够了。
Queue DMA GETs for all buffers.
对所有缓冲区的DMA GET进行排队。
Each buffer gets a unique DMA tag ID.
每个缓冲区获得一个惟一的DMA标记ID。
The SPU queues a DMA PUT to transmit the buffer back to main memory.
SPU对DMA PUT进行排队,从而将缓冲区传输回主内存。
DMA transfers are managed by a third peripheral called a DMA controller.
DMA传输由叫DMA控制器的第三方外设进行管理。
Therefore, they cannot be accessed directly, but must be moved in through DMA.
因而,它们不能被直接访问,而必须通过DMA 移进来。
This command causes the SPE to immediately return with the status of the DMA channels.
这个命令会导致SPE立即返回dma通道的状态。
You then use a DMA command to fetch the full structure, and wait for the DMA to complete.
然后使用dma命令来获取整个结构,等待DMA完成。
Using spu_mfcstat allows you to both check on the status of DMA requests and wait for them.
使用spu_mfcstat让您可以既检查dma请求的状态,又进行等待。
The real power of mailboxes comes when a program combines the mailbox and the DMA approach.
当程序组合使用了邮箱和DMA方法时,才会显出邮箱的真正实力。
Before getting into the details of the main program, I'll explore the DMA utility functions.
在深入介绍主程序细节之前,我要先来探讨一下dma实用函数。
Queue a DMA GETB to refill the buffer with more data after the existing data is stored back.
对DMAGETB进行排队,从而在将现有数据存储回去之后,用更多数据重新填充缓冲区。
The DMA 5000 measures a sample in 40 seconds, considerably increasing efficiency in your lab.
DMA 5000在40秒内测量一种样品,在相当程度上提高实验室的工作效率。
Think of this as a specialized version of the C library function select, but for DMA transfers.
可以把它看作C库函数select的特殊版本,但是针对的是DMA传输。
The SPU queues a DMA GET to pull a portion of the problem data set from main memory to a buffer.
SPU对DMA GET进行排队,从而将涉及的数据集的一部分从主内存传输到一个缓冲区。
The essential hardwares of computer contain CPU, memory, interrupt controller, DMA controller, etc.
计算机硬件的核心器件有CPU、内存、中断控制器、DMA控制器,等等。
The transferTo() method causes the file contents to be copied into a read buffer by the DMA engine.
transferTo()方法引发DMA引擎将文件内容拷贝到一个读取缓冲区。
GETB, PUTB, GETF, and PUTF are the primary fence and barrier-related DMA commands for single buffers.
对于单一缓冲区,GETB、PUTB、GETF和PUTF是与fence和barrier相关的主要dma命令。
The transferTo() method causes the file contents to be copied into a kernel buffer by the DMA engine.
transferTo()方法引发DMA引擎将文件内容拷贝到内核缓冲区。
This is because you are using barriers with your transfers, and you are using the same DMA tag for them.
这是因为正在对传输使用barrier,并对它们使用相同的DMA标签。
This Chapter describes the features common to all the DMAchannels, as well as how DMA operations are set up.
这一章描述了所有DMA通道的公共特征以及如何设置DMA操作。
For instance, one of the problems with the original code is that it is limited to the size of a DMA transfer.
举例来说,原来代码的一个问题是一次dma传输的大小有限制。
The third copy happens as the DMA engine passes the data from the kernel socket buffers to the protocol engine.
数据的第三次复制发生在dma引擎将数据从内核套接字缓冲区传到协议引擎时。
A DMA request always involves moving data between the SPE local store and a virtual address space on the PPE side.
dma请求通常会涉及数据在SPE本地存储与ppe端虚拟地址空间之间进行移动。
Step three: the third copy happens as the DMA engine passes the data from the kernel socket buffers to the protocol engine.
步骤三:dma模块将数据由socket的缓冲区传递给协议引擎时,第3次复制发生。
In this application, you will only have one DMA command active at a time, so all of your operations will use 0 as the DMA tag.
在这个应用程序中,一次只有一个dma命令是激活的,所以所有的操作都将使用0作为DMA标签。
Whether it's an argument passed in or an address gotten some other way, the DMA targets must be aligned on cache lines (16 bytes).
不管是传入的参数还是通过其他方式获得的地址,DMA的目标地址必须要与缓存线路(16字节)进行对齐。
The Cell BE Handbook defines the sequence of channel operations needed to perform a DMA transfer on pages 450-456 (see Resources).
CellBE 手册的第 450 到 456页定义了执行DMA传输所需的信道操作的顺序(请参见 参考资料)。
A fence establishes the constraint that a given DMA transfer only execute after all previous commands using the same tag have completed.
fence建立了这样一个约束:某个给定的dma传输只有在前面的所有使用相同标签的命令全部执行完成之后才会执行。
应用推荐