Does anyone use gccgo?

xuanbao · · 818 次点击    
这是一个分享于 的资源,其中的信息可能已经有所发展或是发生改变。
<p>I guess <em>someone</em>&#39;s using it since it&#39;s maintained, but in all my browsing go repos, I&#39;ve never seen it referenced. </p> <hr/>**评论:**<br/><br/>brokedown: <pre><p>I&#39;ve used it. It lags a bit behind the native compiler, but I&#39;ve used it to compile a few of my apps and they run just fine.</p> <p>I tend to not use cgo so there really isn&#39;t much advantage gained by using it oher than file sizes, gccgo compiled apps will dynamically link against glibc and knock about 5.5 megabytes off your executable.</p></pre>williewillus: <pre><p>Does the regular compiler not have something like LTO? Or is it the runtime itself that needs 5.5 MB of libc?</p></pre>brokedown: <pre><p>Go&#39;s compiler has to include the runtime plus any libraries you use. gccgo can provide the runtime and standard library externally.</p> <p>Also, gcc is a much more mature compiler and as such should be expected to compile &#34;better&#34; binaries. The expectation is that a gccgo binary would be smaller and faster, and be able to take advantage of more cpu features of the target.</p></pre>allowthere: <pre><blockquote> <p>The expectation is that a gccgo binary would be smaller and faster, and be able to take advantage of more cpu features of the target.</p> </blockquote> <p>Did you find that to be true (in real-life testing)?</p></pre>sh41: <pre><p>I’ve used it on some occasions to investigate or confirm bugs in gc compiler.</p></pre>

入群交流(和以上内容无关):加入Go大咖交流群,或添加微信:liuxiaoyan-s 备注:入群;或加QQ群:692541889

818 次点击  
加入收藏 微博
0 回复
暂无回复
添加一条新回复 (您需要 登录 后才能回复 没有账号 ?)
  • 请尽量让自己的回复能够对别人有帮助
  • 支持 Markdown 格式, **粗体**、~~删除线~~、`单行代码`
  • 支持 @ 本站用户;支持表情(输入 : 提示),见 Emoji cheat sheet
  • 图片支持拖拽、截图粘贴等方式上传