[Apache TVM Discuss] [Questions] How to manually controll CPU affinity in multithreading scenario?

2021-07-04 Thread Xiu Zhiping via Apache TVM Discuss
Thanks @FrozenGene, is there a plan to add this in the future? I think this could be a useful function to add. --- [Visit Topic](https://discuss.tvm.apache.org/t/how-to-manually-controll-cpu-affinity-in-multithreading-scenario/10348/5) to respond. You are receiving this because you enabl

[Apache TVM Discuss] [Questions] How to manually controll CPU affinity in multithreading scenario?

2021-06-29 Thread Xiu Zhiping via Apache TVM Discuss
Hello, I have a machine with 40 cpu cores, and a process that runs a TVM application on 10 threads. I wish that each TVM thread will use 4 cpu cores so I set TVM_NUM_THREADS=4. Then what happens is without cpu affinity (TVM_BIND_THREADS=0), the 10 threads will try to occupy cpus randomly, sl