Lchangliang opened a new issue, #8868: URL: https://github.com/apache/incubator-doris/issues/8868
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/incubator-doris/issues?q=is%3Aissue) and found no similar issues. ### Version dev-1.0.0 ### What's Wrong? BUILD_TYPE=tsan ./build.sh --be 使用clang,如上编译之后,启动的时候,会发生memcpy的递归调用,从而发生栈溢出。  原因: 在src/glibc-compatibility/memcpy/memcpy_x86_64.cpp中,自定义的memcpy调用了__builtin_memcpy,而__builtin_memcpy被编译器优化为memcpy,从而产生循环调用。  [stackoverflow相关问题](https://stackoverflow.com/questions/8503194/using-gccs-builtin-functions-in-arm) 该问题只在指定TSAN + -O0时出现,修改为-O1,__builtin_memcpy就不会优化成memcpy。 ### What You Expected? 使用TSAN + -O0进行编译,也可以顺利启动be。 ### How to Reproduce? _No response_ ### Anything Else? _No response_ ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct) -- 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. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
