You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tvm.apache.org by GitBox <gi...@apache.org> on 2020/01/20 09:46:39 UTC

[GitHub] [incubator-tvm] u99127 commented on issue #4747: [ThreadPool] Solve ARM BIG.LITTLE heterogeneous multicores

u99127 commented on issue #4747: [ThreadPool] Solve ARM BIG.LITTLE heterogeneous multicores
URL: https://github.com/apache/incubator-tvm/pull/4747#issuecomment-576192552
 
 
   > 
   > 
   > Follow up #4344 . Previous PR solves OpenCV + TVM slow performance and AutoTVM Python CPU affinity problem. However, previous PR has two problem:
   > 
   >     * doesn't solve ARM  BIG.LITTLE heterogeneous multicores.
   >       For example, we have 2xA72 + 4xA53, previous pr will add all cpu to CPU SET even we call `config_thread_pool` to restrict TVM runs on 4 little cores. So, TVM_MASTER_THREAD could run A72 big core. This is not we want.
   >       Solution: we should restrict master in the little cpus or big cpus according to users's setting.
   
   This approach needs to be added as comments in the code explaining how this is expected to work. Further I suspect it is TVM_BIND_MASTER_THREAD that you refer to above ?  What is the role of the TVM master thread ? Is it another thread that does compute or is it a "controlling" thread ? 
   
   > 
   >     * Not all Linux variant OS has `pthread_atfork`. For example, Alibaba's AliOS doesn't have this api.
   
   pthread_atfork IIRC originally comes from the posix group from Issue 5 as documented [here](https://pubs.opengroup.org/onlinepubs/009695399/functions/pthread_atfork.html). Checking the other libcs suggest that all other mainstream Linux runtimes like glibc, musl and bionic support this and thus are we working around a limitation of AliOS here ?
   
   
   >       Solution: unified android and linux's way. We will call `SetFullCpuAffinity` if we don't have `TVM_BIND_MASTER_THREAD`.
   > 
   > 
   > @tqchen @yidawang @vinx13 @ajtulloch Could you help to review it? Thanks.
   
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services