Добрый день.
Возможно сообщу уже известное, но вдруг пригодится.
В файле xio.c
/*****************************************************************************/
* Performs an input operation for a 32-bit memory location by reading from the
* specified address and returning the value read from that address.
* @param InAddress contains the address to perform the input operation at.
* @return
* The value read from the specified input address.
* @note
* None.
******************************************************************************/
u32 XIo_In32(XIo_Address InAddress)
{
/* read the contents of the I/O location and then synchronize the I/O such that the I/O operation completes before proceeding on*/
#ifdef __GNUC__
u32 IoContents;
__asm__ volatile ("eieio; lwz %0,0(%1)":"=r" (IoContents):"b"
(InAddress));
return IoContents;
#else
SYNCHRONIZE_IO;
return *(u32 *) InAddress;
#endif
}
в свою очередь (файл ppc440x5_um.pdf), команда процессора lwz RT, D(RA)
EA ← (RA|0) + EXTS(D)
(RT) ← MS(EA,4)
An effective address (EA) is formed by adding a displacement to a base address. The displacement is
obtained by sign-extending the 16-bit D field to 32 bits. The base address is 0 if the RA field is 0 and is the
contents of register RA otherwise.
The word at the EA is placed into register RT
К сожалению не нашел информации, сколько тактов команда занимает...