areusch commented on a change in pull request #5417: URL: https://github.com/apache/incubator-tvm/pull/5417#discussion_r415947706
########## File path: python/tvm/micro/device/arm/stm32f746xx.py ########## @@ -36,23 +55,41 @@ def create_micro_lib(obj_path, src_path, lib_type, options=None): options : Optional[List[str]] additional options to pass to GCC + + lib_src_paths : Optional[List[str]] + TODO """ if options is None: options = [] + else: + options = list(options) + options += [ - "-mcpu=cortex-m7", - "-mlittle-endian", - "-mfloat-abi=hard", - "-mfpu=fpv5-sp-d16", - "-mthumb", - "-gdwarf-5", + # TODO(weberlo): make a debug flag + '-O2', + '-march=armv7e-m', + '-mcpu=cortex-m7', + '-mlittle-endian', + '-mfloat-abi=hard', + '-mfpu=fpv5-sp-d16', + '-mthumb', + '-ffast-math', + '-gdwarf-5', + '-DARM_MATH_CM7', + '-D__FPU_PRESENT=1U', + '-DARM_MATH_DSP', + '-Wno-unused-variable', Review comment: these are in the generated GEMM code. for example: `/var/folders/9y/3j808g591ln3kys4qpyl3qmc0000gn/T/tmpb4sk1ylf/temp.c:104:11: error: unused variable \'arg1_code\' [-Werror=unused-variable]` it would be nice if we did not need to include this, but i'm hoping we can merge this PR as-is and incrementally improve things like this (especially since I didn't author most of the code generation stuff and will need a bit of time to understand how to improve it to remove errors like this). the next PR will look at the generated code more in detail, so if it's a quick fix, I can fix it then. ---------------------------------------------------------------- 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: us...@infra.apache.org