请汇编高手给解释下下面几句话的意思和这个函数实现的功能,这个函数是3d游戏编程大师中的函数
inlinevoidMem_Set_WORD(void*dest,USHORTdata,intcount){//thisfunctionfillsorsetsunsign...
inline void Mem_Set_WORD(void *dest, USHORT data, int count){
// this function fills or sets unsigned 16-bit aligned memory
// count is number of words
//Write_Error("{");
_asm {
mov edi, dest ; edi points to destination memory
mov ecx, count ; number of 16-bit words to move
mov ax, data ; 16-bit data
rep stosw ; move data
} // end asm
//Write_Error("}");
}
每句汇编语句后分号后的是注释嘛? 展开
// this function fills or sets unsigned 16-bit aligned memory
// count is number of words
//Write_Error("{");
_asm {
mov edi, dest ; edi points to destination memory
mov ecx, count ; number of 16-bit words to move
mov ax, data ; 16-bit data
rep stosw ; move data
} // end asm
//Write_Error("}");
}
每句汇编语句后分号后的是注释嘛? 展开
2个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询