hi all:<div> The codes is:</div><div><div>static int match(int len,const char * name,struct dir_entry * de)</div><div>{</div><div> register int same __asm__("ax");</div><div><br></div><div> if (!de || !de->inode || len > NAME_LEN)</div>
<div> return 0;</div><div> if (len < NAME_LEN && de->name[len])</div><div> return 0;</div><div> <b>__asm__ ("cld\n\t"</b></div><div> "fs ; repe ; cmpsb\n\t"</div>
<div> "setz %%al"</div><div> :"=a" (same)</div><div> :"0" (0),"S" ((long) name),"D" ((long) de->name),"c" (len)</div>
<div> :"cx","di","si");</div><div> return same;</div><div>}</div></div><div><br></div><div>When I make it, the error messages is:</div><div><b>namei.c:35: error: can't find a register in class ‘AREG’ while reloading ‘asm’</b></div>
<div><b><br></b></div><div><b>This is why? </b></div><div><b>Thank you</b></div><div><br></div>