https://github.com/otland/forgottenserver/wiki/Compiling
You can also compile with vcpkg.
https://github.com/otland/forgottenserver/wiki/Compiling-on-Windows-%28vcpkg%29
Check your lua calls usage lua.log.
You can also check the querrys calls in sql.log.
Check your cpp calls also in dispatcher.log.