On Wed, Mar 12, 2014 at 8:31 PM, Ray Li <st.ray...@gmail.com> wrote: > > Hi, I'm a student interested in working on GCC and want to make a > proposal of GSoC 2014 on GCC Go escape analysis. > > I 've read code under /gcc/testsuit/go.* the some source code of > gofrontend, and realization of escape analysis and furthermore > optimization is needed. > > Right now I have come up with a small patch of escape test at the > beginning. My patch aims at test for whether escape analysis is > working. Then I want to start some small part of performance function > and write more tests for optimization. Am i on the right direction? > Thanks a lot if anyone can give me some advice.
Thanks for your interest. Yes, all of your examples look correct to me. There is a larger escape analysis test in libgo/go/fmt/fmt_test.go. That file is copied from the master repository, but in mallocTest the numbers are changed. Instead of 7 5's and a 20, it should be 0, 1, 1, 2, 1, 2, 0, 1. Ian