leezu commented on a change in pull request #17214: [tvmop] support cuda 
multi-arch compilation
URL: https://github.com/apache/incubator-mxnet/pull/17214#discussion_r363443020
 
 

 ##########
 File path: contrib/tvmop/compile.py
 ##########
 @@ -105,18 +105,13 @@ def get_cuda_arch(arch):
         return arch.split(';')
 
     # the arch string contains '-arch=sm_xx'
+    archs = []
     flags = arch.split()
     for flag in flags:
-        if flag.startswith('-arch='):
-            return flag[len('-arch='):]
+        if flag.startswith('-gencode') or flag.startswith('arch='):
 
 Review comment:
   L104 is added for the use-case that the `arch` parameter in 
`get_cuda_arch(arch)` is based on cmake's `CUDA_SELECT_NVCC_ARCH_FLAGS`. But 
that should always have a semicolon. Is the example input arch string based on 
the Makefile setup?

----------------------------------------------------------------
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:
[email protected]


With regards,
Apache Git Services

Reply via email to