Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
5.5(EOL), 10.1(EOL), 10.2(EOL), 10.3(EOL), 10.4(EOL), 10.5
-
None
Description
MSVC massively scales down on optimization depending of the function size.
bison generated MySQLParse() is considered "huge" by the compiler . I verified this by adding /we4883 flag to compiler options. That makes making (usually inactive) warning "function size prevents optimization" an error.
There is a switch that allows optimizations also for such functions, /d2OptimizeHugeFunctions.
(docs https://support.microsoft.com/en-nz/help/3207317/visual-c-optimizer-fixes-for-visual-studio-2015-update-3)
MySQL 8.0 is using it, according to
https://dev.mysql.com/doc/relnotes/mysql/8.0/en/news-8-0-13.html