Revision 92af06d2 target-mips/op_helper.c

b/target-mips/op_helper.c
168 168
#endif /* TARGET_MIPS64 */
169 169

  
170 170
/* 64 bits arithmetic for 32 bits hosts */
171
#if TARGET_LONG_BITS > HOST_LONG_BITS
172 171
static always_inline uint64_t get_HILO (void)
173 172
{
174
    return (env->HI[env->current_tc][0] << 32) | (uint32_t)env->LO[env->current_tc][0];
173
    return ((uint64_t)(env->HI[env->current_tc][0]) << 32) | (uint32_t)env->LO[env->current_tc][0];
175 174
}
176 175

  
177 176
static always_inline void set_HILO (uint64_t HILO)
......
192 191
    env->HI[env->current_tc][0] = (int32_t)(HILO >> 32);
193 192
}
194 193

  
194
#if TARGET_LONG_BITS > HOST_LONG_BITS
195 195
void do_madd (void)
196 196
{
197 197
    int64_t tmp;
......
223 223
    tmp = ((uint64_t)(uint32_t)T0 * (uint64_t)(uint32_t)T1);
224 224
    set_HILO(get_HILO() - tmp);
225 225
}
226
#endif /* TARGET_LONG_BITS > HOST_LONG_BITS */
226 227

  
227 228
/* Multiplication variants of the vr54xx. */
228 229
void do_muls (void)
......
294 295
{
295 296
    set_HIT0_LO(0 - ((uint64_t)(uint32_t)T0 * (uint64_t)(uint32_t)T1));
296 297
}
297
#endif /* TARGET_LONG_BITS > HOST_LONG_BITS */
298 298

  
299 299
#ifdef TARGET_MIPS64
300 300
void do_dmult (void)

Also available in: Unified diff