From: H. P. A. <hp...@zy...> - 2007-06-18 21:43:39
|
Frank Kotler wrote: > > Let's start with one... > > movq mm0, [esi] > > Error is generated in assemble.c, function calcsize, approximately here: > > if (ins->rex & REX_REAL) { > if (ins->rex & REX_H) { > errfunc(ERR_NONFATAL, "cannot use high register in rex instruction"); > return -1; > } else if (bits == 64 || > ((ins->rex & REX_L) && > !(ins->rex & (REX_P|REX_W|REX_X|REX_B)) && > cpu >= IF_X86_64)) { > length++; > } else { > errfunc(ERR_NONFATAL, "invalid operands in non-64-bit mode"); > return -1; > } > > Why? Is REX_REAL supposed to be set on this instruction? No, ins->rex better be zero, since there is absolutely nothing REX-worthy in this instruction. If there is anything REXy set, we need to figure out why and fix it. > Reporting the error is a good start! If you feel like you know what > you're doing (*I* don't!), feel free to submit a proposed fix... Indeed; *current* error reports with a test case is probably the most immediately valuable. We really, *really*, could use a proper automatic test suite. -hpa |