dongshengyin0147 2017-10-19 20:24
浏览 69
已采纳

Gogland启动调试应用程序很慢

When I try to launch a Go Application in debug mode, Gogland takes a considerable amount of time to launch it. This can take several minutes, and happens on each launch even if there has been no code change.

  • 写回答

1条回答 默认 最新

  • doufuxi7093 2017-10-19 20:24
    关注

    The problem is that Gogland forces a rebuild on each debug invocation. So if you have a lot of dependencies, it will be very slow.

    The solution is to go in to Settings > Build, Execution, Deployment > Debugger and disable Rebuild transitive packages. This will speed up debug launches by 20x (90s vs 5s).

    You should create a Go Application target labeled "Complete rebuild" and set the Go Tool Arguments to be -i -a. This will force a debug rebuild and store the intermediate products to speed up future builds.

    However, this means your cached and optimized, thus without proper debugging information, packages can be used in the debugger which means that it will affect your debugging experience. If you have any issues with the debugger you will need to run with -a first and see if the problem happens again.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥20 测距传感器数据手册i2c
  • ¥15 RPA正常跑,cmd输入cookies跑不出来
  • ¥15 求帮我调试一下freefem代码
  • ¥15 matlab代码解决,怎么运行
  • ¥15 R语言Rstudio突然无法启动
  • ¥15 关于#matlab#的问题:提取2个图像的变量作为另外一个图像像元的移动量,计算新的位置创建新的图像并提取第二个图像的变量到新的图像
  • ¥15 改算法,照着压缩包里边,参考其他代码封装的格式 写到main函数里
  • ¥15 用windows做服务的同志有吗
  • ¥60 求一个简单的网页(标签-安全|关键词-上传)
  • ¥35 lstm时间序列共享单车预测,loss值优化,参数优化算法