/[qemu]/qemu/target-mips/op.c
ViewVC logotype

Diff of /qemu/target-mips/op.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.4 by bellard, Sun Oct 30 21:39:18 2005 UTC revision 1.5 by bellard, Mon Dec 5 19:59:36 2005 UTC
# Line 207  void op_addo (void) Line 207  void op_addo (void)
207      tmp = T0;      tmp = T0;
208      T0 += T1;      T0 += T1;
209      if ((T0 >> 31) ^ (T1 >> 31) ^ (tmp >> 31)) {      if ((T0 >> 31) ^ (T1 >> 31) ^ (tmp >> 31)) {
210          CALL_FROM_TB1(do_raise_exception, EXCP_OVERFLOW);          CALL_FROM_TB1(do_raise_exception_direct, EXCP_OVERFLOW);
211      }      }
212      RETURN();      RETURN();
213  }  }
# Line 225  void op_subo (void) Line 225  void op_subo (void)
225      tmp = T0;      tmp = T0;
226      T0 = (int32_t)T0 - (int32_t)T1;      T0 = (int32_t)T0 - (int32_t)T1;
227      if (!((T0 >> 31) ^ (T1 >> 31) ^ (tmp >> 31))) {      if (!((T0 >> 31) ^ (T1 >> 31) ^ (tmp >> 31))) {
228          CALL_FROM_TB1(do_raise_exception, EXCP_OVERFLOW);          CALL_FROM_TB1(do_raise_exception_direct, EXCP_OVERFLOW);
229      }      }
230      RETURN();      RETURN();
231  }  }
# Line 364  static inline void set_HILO (uint64_t HI Line 364  static inline void set_HILO (uint64_t HI
364    
365  void op_mult (void)  void op_mult (void)
366  {  {
367      set_HILO((int64_t)T0 * (int64_t)T1);      set_HILO((int64_t)(int32_t)T0 * (int64_t)(int32_t)T1);
368      RETURN();      RETURN();
369  }  }
370    
# Line 378  void op_madd (void) Line 378  void op_madd (void)
378  {  {
379      int64_t tmp;      int64_t tmp;
380    
381      tmp = ((int64_t)T0 * (int64_t)T1);      tmp = ((int64_t)(int32_t)T0 * (int64_t)(int32_t)T1);
382      set_HILO((int64_t)get_HILO() + tmp);      set_HILO((int64_t)get_HILO() + tmp);
383      RETURN();      RETURN();
384  }  }
# Line 396  void op_msub (void) Line 396  void op_msub (void)
396  {  {
397      int64_t tmp;      int64_t tmp;
398    
399      tmp = ((int64_t)T0 * (int64_t)T1);      tmp = ((int64_t)(int32_t)T0 * (int64_t)(int32_t)T1);
400      set_HILO((int64_t)get_HILO() - tmp);      set_HILO((int64_t)get_HILO() - tmp);
401      RETURN();      RETURN();
402  }  }
# Line 595  void op_pmon (void) Line 595  void op_pmon (void)
595  void op_trap (void)  void op_trap (void)
596  {  {
597      if (T0) {      if (T0) {
598          CALL_FROM_TB1(do_raise_exception, EXCP_TRAP);          CALL_FROM_TB1(do_raise_exception_direct, EXCP_TRAP);
599      }      }
600      RETURN();      RETURN();
601  }  }
602    
603    void op_debug (void)
604    {
605      CALL_FROM_TB1(do_raise_exception_direct, EXCP_DEBUG);
606    }
607    
608  void op_set_lladdr (void)  void op_set_lladdr (void)
609  {  {
610      env->CP0_LLAddr = T2;      env->CP0_LLAddr = T2;
# Line 654  void op_exit_tb (void) Line 659  void op_exit_tb (void)
659      EXIT_TB();      EXIT_TB();
660  }  }
661    
662    void op_wait (void)
663    {
664        env->halted = 1;
665        CALL_FROM_TB1(do_raise_exception, EXCP_HLT);
666    }

Legend:
Removed from v.1.4  
changed lines
  Added in v.1.5

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26