Go 1.5 In Beta
Go 1.5 In Beta
Written by Alex Denham   
Tuesday, 21 July 2015

The second beta version of Go 1.5 has been released with the compiler and runtime written entirely in Go.

 

 

Go

 

The release has been moved from the usual six-month interval because of the need for more time to prepare this major release; and to shift the schedule thereafter to time the release dates more conveniently. Despite changes, the developers expect almost all Go programs to continue to compile and run as before, because the release still maintains the Go 1 promise of compatibility.

Under the covers, the main change to the implementation is the rewriting of the compiler and runtime entirely in Go (with a little assembler). C is no longer involved in the implementation, meaning that the C compiler that was until now necessary for building the distribution has been dropped. The release notes for the beta say that the only C source left in the tree is related to testing or to cgo.

In previous versions of the language a C compiler was used to build the runtime, meaning that a custom compiler was necessary in part to guarantee the C code would work with the stack management of goroutines. The compiler was actually moved by automatic translation of the C code into Go, making it in effect the same program in a different language. There’s an overview of the process involved in a presentation given by Google’s Rob Pike at Gopherfest in May.

Another major improvement is to the garbage collector. This is now concurrent and provides dramatically lower pause times by running, when possible, in parallel with other goroutines. The release notes say that expected latencies are much lower than with the collector in prior releases, through a combination of advanced algorithms, better scheduling of the collector, and running more of the collection in parallel with the user program. The "stop the world" phase of the collector will almost always be under 10 milliseconds and usually much less.

Overall changes to performance mainly come from the new garbage collector and the conversion of the runtime to Go, and on average the programs in the Go 1 benchmark suite run a few percent faster in Go 1.5 than they did in Go 1.4. The garbage collector's pauses are dramatically shorter, and almost always under 10 milliseconds. In addition, where you use the defaults, some programs should run faster because GOMAXPROCS is now set by default to the number of cores available; in prior releases it defaulted to 1.

Other improvements include support for internal packages for all repositories in addition to the Go core; experimental support for "vendoring" external dependencies by the go command; a new go tool trace command that supports fine-grained tracing of program execution; and a new go doc command (distinct from godoc) that is customized for command-line use.

The binary and source distributions are available on the Golang site.

 

 

goicon1

Banner


Augmented Reality - A Primer On Coursera
10/07/2018

A short course from Google on the Coursera platform introduces augmented reality (AR) and Google's ARCore. Available for free, it starts on July 16th and lasts four weeks.



Python Passion For Assignment Expressions - PEP 572
11/07/2018

You would think with a language as old as Python there wouldn't be much left to get excited about, but over the past few months PEP-572, a proposal to add a new feature, has been raising the bloo [ ... ]


More News

 

justjsquare

 



 

Comments




or email your comment to: comments@i-programmer.info

Last Updated ( Tuesday, 21 July 2015 )
 
 

   
Banner
RSS feed of news items only
I Programmer News
Copyright © 2018 i-programmer.info. All Rights Reserved.
Joomla! is Free Software released under the GNU/GPL License.