On 11/6/20 7:27 AM, Peter Maydell wrote: > +#ifdef TARGET_SPARC64 > +/* win_helper.c */ > +target_ulong cpu_get_ccr(CPUSPARCState *env1); > +void cpu_put_ccr(CPUSPARCState *env1, target_ulong val); > +target_ulong cpu_get_cwp64(CPUSPARCState *env1); > +void cpu_put_cwp64(CPUSPARCState *env1, int cwp); > + > +static inline uint64_t sparc64_tstate(CPUSPARCState *env) > +{ > + uint64_t tstate = (cpu_get_ccr(env) << 32) | > + ((env->asi & 0xff) << 24) | ((env->pstate & 0xf3f) << 8) | > + cpu_get_cwp64(env); > + > + if (env->def.features & CPU_FEATURE_GL) { > + tstate |= (env->gl & 7ULL) << 40; > + } > + return tstate; > +} > +#endif
Given that this inline function calls 2 other out-of-line functions, I think it might as well be out-of-line itself. I'd place it in win_helper.c alongside the functions that it calls. But either way, Reviewed-by: Richard Henderson <richard.hender...@linaro.org> r~