On 10/15/20 2:33 PM, Claudio Fontana wrote: > On 10/14/20 10:08 PM, Richard Henderson wrote: >> On 10/14/20 12:23 PM, Claudio Fontana wrote: >>> +++ b/accel/tcg/tcg-cpus-mttcg.h >>> @@ -10,14 +10,4 @@ >>> #ifndef TCG_CPUS_MTTCG_H >>> #define TCG_CPUS_MTTCG_H >>> >>> -/* >>> - * Multi-threaded TCG >>> - * >>> - * In the multi-threaded case each vCPU has its own thread. The TLS >>> - * variable current_cpu can be used deep in the code to find the >>> - * current CPUState for a given thread. >>> - */ >>> - >>> -void *tcg_cpu_thread_fn(void *arg); >>> - >>> #endif /* TCG_CPUS_MTTCG_H */ >> >> Hum. Do we really need to create these headers in the previous patch? >> Because >> now we have an empty one. >> >> Why not just put all of tcg-cpus-*.h into tcg-cpus.h? >> >> Otherwise this looks ok. >> >> >> r~ >> > > There are some symbols required between -icount, -rr, and -mttcg, and in > particular in the -mttcg case, this requirement goes away after start_vcpu is > also refactored. > > Will take a look again, at the very least the mttcg.h should be removed > completely. > > Ciao, > > Claudio >
To be more precise, tcg-cpus-icount.h ends up with functions that icount provides (to -rr) to be able to consider icount in the part of the code that is mostly rr. tcg-cpus-rr.h contains the functions that "rr" provides (to -icount), since icount just reuses those. Ciao, Claudio