On Fri, Jul 23, 2010 at 7:08 AM, Blue Swirl <blauwir...@gmail.com> wrote: > On Thu, Jul 22, 2010 at 2:06 AM, Jun Koi <junkoi2...@gmail.com> wrote: >> Hi, >> >> Function regs_to_env() in target-i386/exec.h has a code like below: >> >> ... >> #ifdef reg_EAX >> env->regs[R_EAX] = EAX >> #endif >> ... >> >> However, elsewhere we have EAX defined as: >> >> #define EAX (env->regs[R_EAX]) >> >> This means effectively, we have code like: >> >> env->regs[R_EAX] = env->regs[R_EAX]; >> >> What is the meaning of this code? That looks pointless to me, but I >> guess I must be wrong here... > > Yes, those lines don't exist anymore, they were used before TCG. IIRC > EAX was defined to AREG1 etc. >
hey, that sounds funny. will you take a patch removing both regs_to_env() and env_to_regs() ? thanks, J