This is wrong, it writes all 64 bits of both registers, and it also reads all 64 bits if the two registers are eax (because it leaves them unmodified, or rather, it doesn't read or write anything). @bchurchill, could you advise how to fix this? You hacked Codegen.hs to not have it use the property WRITE_SX (presumably because of the eax/eax case?). It seems the table cannot be use to get a fully accurate read/write set, because it depends on whether we are looking at eax/eax or not. Maybe just always saying all 64 bits are read and written?
@bchurchill, could you advise what the best fix is? I'm happy to implement it afterwards.
We decided that xchgl_r32_eax should have a maybe_read_set of r32, and a maybe_write_set of rax. Every other variant of xchgl does the normal zero-extend.
This is wrong, it writes all 64 bits of both registers, and it also reads all 64 bits if the two registers are eax (because it leaves them unmodified, or rather, it doesn't read or write anything). @bchurchill, could you advise how to fix this? You hacked Codegen.hs to not have it use the property WRITE_SX (presumably because of the eax/eax case?). It seems the table cannot be use to get a fully accurate read/write set, because it depends on whether we are looking at eax/eax or not. Maybe just always saying all 64 bits are read and written?
@bchurchill, could you advise what the best fix is? I'm happy to implement it afterwards.