aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/go.test/test
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/go.test/test')
-rw-r--r--gcc/testsuite/go.test/test/235.go5
-rw-r--r--gcc/testsuite/go.test/test/64bit.go4
-rw-r--r--gcc/testsuite/go.test/test/alias.go7
-rw-r--r--gcc/testsuite/go.test/test/alias1.go6
-rw-r--r--gcc/testsuite/go.test/test/append.go19
-rw-r--r--gcc/testsuite/go.test/test/args.go5
-rw-r--r--gcc/testsuite/go.test/test/assign.go5
-rw-r--r--gcc/testsuite/go.test/test/assign1.go5
-rw-r--r--gcc/testsuite/go.test/test/bench/garbage/Makefile17
-rw-r--r--gcc/testsuite/go.test/test/bench/garbage/parser.go20
-rw-r--r--gcc/testsuite/go.test/test/bench/garbage/peano.go2
-rw-r--r--gcc/testsuite/go.test/test/bench/garbage/stats.go18
-rw-r--r--gcc/testsuite/go.test/test/bench/garbage/tree2.go23
-rw-r--r--gcc/testsuite/go.test/test/bench/go1/Makefile7
-rw-r--r--gcc/testsuite/go.test/test/bench/go1/_testmain.go40
-rw-r--r--gcc/testsuite/go.test/test/bench/go1/dummy.go3
-rw-r--r--gcc/testsuite/go.test/test/bench/go1/fasta_test.go17
-rw-r--r--gcc/testsuite/go.test/test/bench/go1/gob_test.go4
-rw-r--r--gcc/testsuite/go.test/test/bench/go1/gzip_test.go10
-rw-r--r--gcc/testsuite/go.test/test/bench/go1/json_test.go15
-rw-r--r--gcc/testsuite/go.test/test/bench/go1/mandel_test.go41
-rw-r--r--gcc/testsuite/go.test/test/bench/go1/parser_test.go43
-rw-r--r--gcc/testsuite/go.test/test/bench/go1/parserdata_test.go245
-rw-r--r--gcc/testsuite/go.test/test/bench/go1/revcomp_test.go6
-rw-r--r--gcc/testsuite/go.test/test/bench/shootout/Makefile14
-rw-r--r--gcc/testsuite/go.test/test/bench/shootout/binary-tree.c1
-rw-r--r--gcc/testsuite/go.test/test/bench/shootout/k-nucleotide.c2
-rw-r--r--gcc/testsuite/go.test/test/bench/shootout/mandelbrot.go16
-rw-r--r--gcc/testsuite/go.test/test/bench/shootout/threadring.c5
-rw-r--r--gcc/testsuite/go.test/test/bench/shootout/timing.log261
-rwxr-xr-xgcc/testsuite/go.test/test/bench/shootout/timing.sh14
-rw-r--r--gcc/testsuite/go.test/test/bigalg.go4
-rw-r--r--gcc/testsuite/go.test/test/bigmap.go107
-rw-r--r--gcc/testsuite/go.test/test/blank.go6
-rw-r--r--gcc/testsuite/go.test/test/blank1.go5
-rw-r--r--gcc/testsuite/go.test/test/bom.go26
-rw-r--r--gcc/testsuite/go.test/test/bombad.go18
-rw-r--r--gcc/testsuite/go.test/test/bounds.go270
-rw-r--r--gcc/testsuite/go.test/test/bugs/bug395.go3
-rw-r--r--gcc/testsuite/go.test/test/bugs/bug434.dir/one.go28
-rw-r--r--gcc/testsuite/go.test/test/bugs/bug434.dir/two.go22
-rw-r--r--gcc/testsuite/go.test/test/bugs/bug434.go10
-rw-r--r--gcc/testsuite/go.test/test/chan/doubleselect.go5
-rw-r--r--gcc/testsuite/go.test/test/chan/fifo.go4
-rw-r--r--gcc/testsuite/go.test/test/chan/goroutines.go6
-rw-r--r--gcc/testsuite/go.test/test/chan/nonblock.go6
-rw-r--r--gcc/testsuite/go.test/test/chan/perm.go6
-rw-r--r--gcc/testsuite/go.test/test/chan/powser1.go4
-rw-r--r--gcc/testsuite/go.test/test/chan/powser2.go11
-rw-r--r--gcc/testsuite/go.test/test/chan/select.go4
-rw-r--r--gcc/testsuite/go.test/test/chan/select2.go4
-rw-r--r--gcc/testsuite/go.test/test/chan/select3.go8
-rw-r--r--gcc/testsuite/go.test/test/chan/select4.go8
-rw-r--r--gcc/testsuite/go.test/test/chan/select5.go9
-rw-r--r--gcc/testsuite/go.test/test/chan/select6.go4
-rw-r--r--gcc/testsuite/go.test/test/chan/select7.go2
-rw-r--r--gcc/testsuite/go.test/test/chan/sendstmt.go2
-rw-r--r--gcc/testsuite/go.test/test/chan/sieve1.go4
-rw-r--r--gcc/testsuite/go.test/test/chan/sieve2.go4
-rw-r--r--gcc/testsuite/go.test/test/chan/zerosize.go4
-rw-r--r--gcc/testsuite/go.test/test/chancap.go4
-rw-r--r--gcc/testsuite/go.test/test/char_lit.go4
-rw-r--r--gcc/testsuite/go.test/test/char_lit1.go5
-rw-r--r--gcc/testsuite/go.test/test/closedchan.go2
-rw-r--r--gcc/testsuite/go.test/test/closure.go16
-rw-r--r--gcc/testsuite/go.test/test/cmp.go23
-rw-r--r--gcc/testsuite/go.test/test/cmp6.go10
-rw-r--r--gcc/testsuite/go.test/test/cmplx.go5
-rw-r--r--gcc/testsuite/go.test/test/cmplxdivide.c1
-rw-r--r--gcc/testsuite/go.test/test/cmplxdivide.go2
-rw-r--r--gcc/testsuite/go.test/test/cmplxdivide1.go1
-rw-r--r--gcc/testsuite/go.test/test/complit.go4
-rw-r--r--gcc/testsuite/go.test/test/complit1.go5
-rw-r--r--gcc/testsuite/go.test/test/compos.go4
-rw-r--r--gcc/testsuite/go.test/test/const.go4
-rw-r--r--gcc/testsuite/go.test/test/const1.go62
-rw-r--r--gcc/testsuite/go.test/test/const2.go11
-rw-r--r--gcc/testsuite/go.test/test/const3.go4
-rw-r--r--gcc/testsuite/go.test/test/const4.go77
-rw-r--r--gcc/testsuite/go.test/test/const5.go33
-rw-r--r--gcc/testsuite/go.test/test/convT2X.go195
-rw-r--r--gcc/testsuite/go.test/test/convert.go4
-rw-r--r--gcc/testsuite/go.test/test/convert1.go5
-rw-r--r--gcc/testsuite/go.test/test/convert3.go5
-rw-r--r--gcc/testsuite/go.test/test/convlit.go9
-rw-r--r--gcc/testsuite/go.test/test/convlit1.go5
-rw-r--r--gcc/testsuite/go.test/test/copy.go4
-rw-r--r--gcc/testsuite/go.test/test/crlf.go4
-rw-r--r--gcc/testsuite/go.test/test/ddd.go18
-rw-r--r--gcc/testsuite/go.test/test/ddd1.go15
-rw-r--r--gcc/testsuite/go.test/test/ddd2.go4
-rw-r--r--gcc/testsuite/go.test/test/ddd3.go5
-rw-r--r--gcc/testsuite/go.test/test/decl.go4
-rw-r--r--gcc/testsuite/go.test/test/declbad.go12
-rw-r--r--gcc/testsuite/go.test/test/defer.go4
-rw-r--r--gcc/testsuite/go.test/test/deferprint.go7
-rw-r--r--gcc/testsuite/go.test/test/divide.go4
-rw-r--r--gcc/testsuite/go.test/test/dwarf/linedirectives.go2
-rw-r--r--gcc/testsuite/go.test/test/dwarf/main.go3
-rw-r--r--gcc/testsuite/go.test/test/empty.go5
-rw-r--r--gcc/testsuite/go.test/test/env.go2
-rw-r--r--gcc/testsuite/go.test/test/eof.go5
-rw-r--r--gcc/testsuite/go.test/test/eof1.go7
-rw-r--r--gcc/testsuite/go.test/test/escape.go33
-rw-r--r--gcc/testsuite/go.test/test/escape2.go173
-rw-r--r--gcc/testsuite/go.test/test/escape3.go4
-rw-r--r--gcc/testsuite/go.test/test/escape4.go57
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug000.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug002.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug003.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug004.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug005.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug006.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug007.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug008.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug009.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug010.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug011.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug012.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug013.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug014.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug015.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug016.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug017.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug020.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug021.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug022.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug023.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug024.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug026.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug027.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug028.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug030.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug031.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug035.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug036.go13
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug037.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug038.go13
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug039.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug040.go6
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug045.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug046.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug047.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug048.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug049.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug050.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug051.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug052.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug053.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug054.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug055.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug056.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug057.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug058.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug059.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug060.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug061.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug062.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug063.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug064.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug065.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug066.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug067.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug068.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug069.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug070.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug071.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug072.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug073.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug074.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug075.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug076.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug077.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug078.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug080.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug081.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug082.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug083.go3
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug084.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug085.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug086.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug087.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug088.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug089.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug090.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug091.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug092.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug093.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug094.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug096.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug097.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug098.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug099.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug101.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug102.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug103.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug104.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug106.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug107.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug108.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug109.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug110.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug111.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug112.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug113.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug114.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug115.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug116.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug117.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug118.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug119.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug120.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug121.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug122.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug123.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug126.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug127.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug128.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug129.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug130.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug131.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug132.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug133.go3
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug135.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug136.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug137.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug139.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug140.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug141.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug142.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug143.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug144.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug145.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug146.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug147.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug148.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug149.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug150.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug151.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug1515.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug152.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug154.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug155.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug156.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug157.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug158.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug159.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug160.go3
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug161.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug163.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug164.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug165.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug167.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug168.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug169.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug170.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug171.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug172.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug173.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug174.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug175.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug176.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug177.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug178.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug179.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug180.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug181.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug182.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug183.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug184.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug185.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug186.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug187.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug188.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug189.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug190.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug191.go3
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug192.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug193.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug194.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug195.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug196.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug197.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug198.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug199.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug200.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug201.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug202.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug203.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug204.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug205.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug206.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug206.out2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug207.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug208.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug209.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug211.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug212.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug213.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug214.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug215.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug216.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug217.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug218.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug219.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug221.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug222.dir/chanbug.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug222.dir/chanbug2.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug222.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug223.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug224.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug225.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug227.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug228.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug229.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug230.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug231.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug232.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug233.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug234.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug235.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug236.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug237.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug238.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug239.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug240.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug241.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug242.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug243.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug244.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug245.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug246.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug247.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug248.dir/bug0.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug248.dir/bug1.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug248.dir/bug2.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug248.dir/bug3.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug248.go3
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug249.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug250.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug251.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug252.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug253.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug254.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug255.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug256.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug257.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug258.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug259.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug260.go6
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug261.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug262.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug263.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug264.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug265.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug266.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug267.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug269.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug271.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug272.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug273.go44
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug274.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug275.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug276.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug277.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug278.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug279.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug280.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug281.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug282.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug283.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug284.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug285.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug286.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug287.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug288.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug289.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug290.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug291.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug292.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug293.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug294.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug295.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug296.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug297.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug298.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug299.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug300.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug301.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug302.go5
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug303.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug304.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug305.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug306.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug307.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug308.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug309.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug311.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug312.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug313.go3
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug314.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug315.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug316.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug317.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug318.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug319.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug320.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug321.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug322.go3
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug323.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug324.go3
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug325.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug326.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug327.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug328.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug329.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug330.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug331.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug332.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug333.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug334.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug335.dir/a.go6
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug335.dir/b.go6
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug335.go5
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug336.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug337.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug338.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug339.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug340.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug341.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug342.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug343.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug344.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug345.go3
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug346.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug347.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug348.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug349.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug350.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug351.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug352.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug353.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug354.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug355.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug356.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug357.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug358.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug361.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug362.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug363.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug364.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug365.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug366.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug367.dir/main.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug367.dir/p.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug367.go3
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug368.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug369.go5
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug370.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug371.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug372.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug373.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug374.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug375.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug376.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug377.dir/one.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug377.dir/two.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug377.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug378.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug379.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug380.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug381.go19
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug382.go7
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug383.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug384.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug385_32.go5
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug385_64.go7
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug386.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug387.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug388.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug389.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug390.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug391.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug392.dir/one.go21
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug392.dir/pkg2.go (renamed from gcc/testsuite/go.test/test/fixedbugs/bug392.dir/two.go)7
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug392.dir/pkg3.go13
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug392.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug393.go4
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug394.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug396.dir/one.go1
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug396.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug397.go2
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug398.go24
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug399.go15
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug401.go46
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug402.go31
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug403.go23
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug404.dir/one.go19
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug404.dir/two.go12
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug404.go7
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug405.go24
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug406.go25
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug407.dir/one.go20
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug407.dir/two.go15
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug407.go7
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug409.go20
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug409.out1
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug410.go24
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug411.go19
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug412.go16
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug413.go11
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug414.dir/main.go18
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug414.dir/p1.go21
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug414.go10
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug415.dir/p.go14
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug415.dir/prog.go9
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug415.go9
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug416.go13
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug417.go32
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug418.go22
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug419.go17
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug420.go14
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug421.go17
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug422.go11
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug423.go277
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug424.dir/lib.go16
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug424.go102
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug425.go17
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug426.go15
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug427.go39
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug428.go19
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug429.go16
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug430.go22
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug431.go18
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug432.go13
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug433.go39
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug434.go32
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug435.go15
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug436.go32
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug437.dir/one.go18
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug437.dir/two.go11
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug437.go30
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug438.go16
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug439.go22
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug440_32.go21
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug440_64.go21
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug441.go36
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug442.go27
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug443.go17
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug444.go36
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug445.go14
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug446.go36
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug447.go105
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug448.dir/pkg1.go11
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug448.dir/pkg2.go14
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug448.go7
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug449.go69
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug450.go28
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug451.go11
-rw-r--r--gcc/testsuite/go.test/test/fixedbugs/bug452.go38
-rw-r--r--gcc/testsuite/go.test/test/float_lit.go4
-rw-r--r--gcc/testsuite/go.test/test/floatcmp.go4
-rw-r--r--gcc/testsuite/go.test/test/for.go4
-rw-r--r--gcc/testsuite/go.test/test/func.go3
-rw-r--r--gcc/testsuite/go.test/test/func1.go7
-rw-r--r--gcc/testsuite/go.test/test/func2.go5
-rw-r--r--gcc/testsuite/go.test/test/func3.go5
-rw-r--r--gcc/testsuite/go.test/test/func4.go5
-rw-r--r--gcc/testsuite/go.test/test/func5.go4
-rw-r--r--gcc/testsuite/go.test/test/func6.go4
-rw-r--r--gcc/testsuite/go.test/test/func7.go4
-rw-r--r--gcc/testsuite/go.test/test/func8.go49
-rw-r--r--gcc/testsuite/go.test/test/gc.go4
-rw-r--r--gcc/testsuite/go.test/test/gc1.go4
-rw-r--r--gcc/testsuite/go.test/test/gc2.go4
-rw-r--r--gcc/testsuite/go.test/test/golden.out9
-rw-r--r--gcc/testsuite/go.test/test/goprint.go4
-rw-r--r--gcc/testsuite/go.test/test/goto.go5
-rwxr-xr-xgcc/testsuite/go.test/test/hashmap.go181
-rw-r--r--gcc/testsuite/go.test/test/helloworld.go4
-rw-r--r--gcc/testsuite/go.test/test/if.go4
-rw-r--r--gcc/testsuite/go.test/test/import.go6
-rw-r--r--gcc/testsuite/go.test/test/import1.go5
-rw-r--r--gcc/testsuite/go.test/test/import2.go5
-rw-r--r--gcc/testsuite/go.test/test/import3.go5
-rw-r--r--gcc/testsuite/go.test/test/import4.go9
-rw-r--r--gcc/testsuite/go.test/test/import5.go55
-rw-r--r--gcc/testsuite/go.test/test/index.go77
-rw-r--r--gcc/testsuite/go.test/test/indirect.go4
-rw-r--r--gcc/testsuite/go.test/test/indirect1.go5
-rw-r--r--gcc/testsuite/go.test/test/init.go5
-rw-r--r--gcc/testsuite/go.test/test/init1.go16
-rw-r--r--gcc/testsuite/go.test/test/initcomma.go12
-rw-r--r--gcc/testsuite/go.test/test/initialize.go4
-rw-r--r--gcc/testsuite/go.test/test/initializerr.go5
-rw-r--r--gcc/testsuite/go.test/test/initsyscall.go26
-rw-r--r--gcc/testsuite/go.test/test/int_lit.go4
-rw-r--r--gcc/testsuite/go.test/test/intcvt.go4
-rw-r--r--gcc/testsuite/go.test/test/interface/bigdata.go5
-rw-r--r--gcc/testsuite/go.test/test/interface/convert.go5
-rw-r--r--gcc/testsuite/go.test/test/interface/convert1.go5
-rw-r--r--gcc/testsuite/go.test/test/interface/convert2.go5
-rw-r--r--gcc/testsuite/go.test/test/interface/embed.go4
-rw-r--r--gcc/testsuite/go.test/test/interface/embed0.go4
-rw-r--r--gcc/testsuite/go.test/test/interface/embed1.go5
-rw-r--r--gcc/testsuite/go.test/test/interface/embed2.go4
-rw-r--r--gcc/testsuite/go.test/test/interface/explicit.go13
-rw-r--r--gcc/testsuite/go.test/test/interface/fail.go4
-rw-r--r--gcc/testsuite/go.test/test/interface/fake.go4
-rw-r--r--gcc/testsuite/go.test/test/interface/noeq.go5
-rw-r--r--gcc/testsuite/go.test/test/interface/pointer.go5
-rw-r--r--gcc/testsuite/go.test/test/interface/private.go6
-rw-r--r--gcc/testsuite/go.test/test/interface/private1.go4
-rw-r--r--gcc/testsuite/go.test/test/interface/receiver.go6
-rw-r--r--gcc/testsuite/go.test/test/interface/receiver1.go5
-rw-r--r--gcc/testsuite/go.test/test/interface/recursive.go4
-rw-r--r--gcc/testsuite/go.test/test/interface/recursive1.go4
-rw-r--r--gcc/testsuite/go.test/test/interface/recursive2.go5
-rw-r--r--gcc/testsuite/go.test/test/interface/returntype.go4
-rw-r--r--gcc/testsuite/go.test/test/interface/struct.go4
-rw-r--r--gcc/testsuite/go.test/test/iota.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/array.go7
-rw-r--r--gcc/testsuite/go.test/test/ken/chan.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/chan1.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/complit.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/convert.go5
-rw-r--r--gcc/testsuite/go.test/test/ken/cplx0.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/cplx1.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/cplx2.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/cplx3.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/cplx4.go5
-rw-r--r--gcc/testsuite/go.test/test/ken/cplx5.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/divconst.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/divmod.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/embed.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/for.go3
-rw-r--r--gcc/testsuite/go.test/test/ken/interbasic.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/interfun.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/intervar.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/label.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/litfun.go3
-rw-r--r--gcc/testsuite/go.test/test/ken/mfunc.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/modconst.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/ptrfun.go3
-rw-r--r--gcc/testsuite/go.test/test/ken/ptrvar.go3
-rw-r--r--gcc/testsuite/go.test/test/ken/range.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/rob1.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/rob2.go5
-rw-r--r--gcc/testsuite/go.test/test/ken/robfor.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/robfunc.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/shift.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/simparray.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/simpbool.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/simpconv.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/simpfun.go3
-rw-r--r--gcc/testsuite/go.test/test/ken/simpswitch.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/simpvar.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/slicearray.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/sliceslice.go4
-rw-r--r--gcc/testsuite/go.test/test/ken/string.go3
-rw-r--r--gcc/testsuite/go.test/test/ken/strvar.go3
-rw-r--r--gcc/testsuite/go.test/test/label.go6
-rw-r--r--gcc/testsuite/go.test/test/label1.go7
-rw-r--r--gcc/testsuite/go.test/test/linkx.go20
-rw-r--r--gcc/testsuite/go.test/test/literal.go4
-rw-r--r--gcc/testsuite/go.test/test/mallocfin.go4
-rw-r--r--gcc/testsuite/go.test/test/map.go206
-rw-r--r--gcc/testsuite/go.test/test/map1.go23
-rw-r--r--gcc/testsuite/go.test/test/method.go137
-rw-r--r--gcc/testsuite/go.test/test/method1.go5
-rw-r--r--gcc/testsuite/go.test/test/method2.go5
-rw-r--r--gcc/testsuite/go.test/test/method3.go4
-rw-r--r--gcc/testsuite/go.test/test/method4.go109
-rw-r--r--gcc/testsuite/go.test/test/method4a.go40
-rw-r--r--gcc/testsuite/go.test/test/named.go2
-rw-r--r--gcc/testsuite/go.test/test/named1.go3
-rw-r--r--gcc/testsuite/go.test/test/nil.go4
-rw-r--r--gcc/testsuite/go.test/test/nilptr.go5
-rw-r--r--gcc/testsuite/go.test/test/nul1.go3
-rw-r--r--gcc/testsuite/go.test/test/parentype.go4
-rw-r--r--gcc/testsuite/go.test/test/peano.go5
-rw-r--r--gcc/testsuite/go.test/test/printbig.go4
-rw-r--r--gcc/testsuite/go.test/test/range.go15
-rw-r--r--gcc/testsuite/go.test/test/recover.go29
-rw-r--r--gcc/testsuite/go.test/test/recover1.go2
-rw-r--r--gcc/testsuite/go.test/test/recover2.go2
-rw-r--r--gcc/testsuite/go.test/test/recover3.go4
-rw-r--r--gcc/testsuite/go.test/test/rename.go112
-rw-r--r--gcc/testsuite/go.test/test/rename1.go72
-rw-r--r--gcc/testsuite/go.test/test/reorder.go13
-rw-r--r--gcc/testsuite/go.test/test/reorder2.go174
-rw-r--r--gcc/testsuite/go.test/test/rotate.go171
-rwxr-xr-xgcc/testsuite/go.test/test/run24
-rw-r--r--gcc/testsuite/go.test/test/run.go607
-rw-r--r--gcc/testsuite/go.test/test/rune.go7
-rw-r--r--gcc/testsuite/go.test/test/runtime.go7
-rw-r--r--gcc/testsuite/go.test/test/safe/main.go14
-rw-r--r--gcc/testsuite/go.test/test/safe/nousesafe.go8
-rw-r--r--gcc/testsuite/go.test/test/safe/pkg.go16
-rw-r--r--gcc/testsuite/go.test/test/safe/usesafe.go8
-rw-r--r--gcc/testsuite/go.test/test/shift1.go4
-rw-r--r--gcc/testsuite/go.test/test/shift2.go4
-rw-r--r--gcc/testsuite/go.test/test/sieve.go5
-rw-r--r--gcc/testsuite/go.test/test/sigchld.go5
-rw-r--r--gcc/testsuite/go.test/test/simassign.go4
-rw-r--r--gcc/testsuite/go.test/test/sinit.go6
-rw-r--r--gcc/testsuite/go.test/test/sizeof.go4
-rw-r--r--gcc/testsuite/go.test/test/solitaire.go6
-rw-r--r--gcc/testsuite/go.test/test/stack.go3
-rw-r--r--gcc/testsuite/go.test/test/string_lit.go28
-rw-r--r--gcc/testsuite/go.test/test/stringrange.go11
-rw-r--r--gcc/testsuite/go.test/test/struct0.go8
-rw-r--r--gcc/testsuite/go.test/test/switch.go58
-rw-r--r--gcc/testsuite/go.test/test/switch1.go20
-rw-r--r--gcc/testsuite/go.test/test/switch3.go16
-rw-r--r--gcc/testsuite/go.test/test/syntax/chan.go2
-rw-r--r--gcc/testsuite/go.test/test/syntax/chan1.go2
-rw-r--r--gcc/testsuite/go.test/test/syntax/composite.go11
-rw-r--r--gcc/testsuite/go.test/test/syntax/else.go2
-rw-r--r--gcc/testsuite/go.test/test/syntax/forvar.go2
-rw-r--r--gcc/testsuite/go.test/test/syntax/if.go2
-rw-r--r--gcc/testsuite/go.test/test/syntax/import.go2
-rw-r--r--gcc/testsuite/go.test/test/syntax/interface.go2
-rw-r--r--gcc/testsuite/go.test/test/syntax/semi1.go2
-rw-r--r--gcc/testsuite/go.test/test/syntax/semi2.go2
-rw-r--r--gcc/testsuite/go.test/test/syntax/semi3.go2
-rw-r--r--gcc/testsuite/go.test/test/syntax/semi4.go2
-rw-r--r--gcc/testsuite/go.test/test/syntax/semi5.go2
-rw-r--r--gcc/testsuite/go.test/test/syntax/semi6.go2
-rw-r--r--gcc/testsuite/go.test/test/syntax/semi7.go2
-rw-r--r--gcc/testsuite/go.test/test/syntax/topexpr.go2
-rw-r--r--gcc/testsuite/go.test/test/syntax/typesw.go2
-rw-r--r--gcc/testsuite/go.test/test/syntax/vareq.go2
-rw-r--r--gcc/testsuite/go.test/test/syntax/vareq1.go2
-rw-r--r--gcc/testsuite/go.test/test/test0.go92
-rw-r--r--gcc/testsuite/go.test/test/testlib61
-rw-r--r--gcc/testsuite/go.test/test/times.out632
-rw-r--r--gcc/testsuite/go.test/test/turing.go4
-rw-r--r--gcc/testsuite/go.test/test/typeswitch.go4
-rw-r--r--gcc/testsuite/go.test/test/typeswitch1.go4
-rw-r--r--gcc/testsuite/go.test/test/typeswitch2.go5
-rw-r--r--gcc/testsuite/go.test/test/typeswitch3.go37
-rw-r--r--gcc/testsuite/go.test/test/undef.go5
-rw-r--r--gcc/testsuite/go.test/test/utf.go4
-rw-r--r--gcc/testsuite/go.test/test/varerr.go5
-rw-r--r--gcc/testsuite/go.test/test/varinit.go4
-rw-r--r--gcc/testsuite/go.test/test/zerodivide.go4
747 files changed, 6976 insertions, 1999 deletions
diff --git a/gcc/testsuite/go.test/test/235.go b/gcc/testsuite/go.test/test/235.go
index 03143a60d..6745dde41 100644
--- a/gcc/testsuite/go.test/test/235.go
+++ b/gcc/testsuite/go.test/test/235.go
@@ -1,9 +1,12 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Solve the 2,3,5 problem (print all numbers with 2, 3, or 5 as factor) using channels.
+// Test the solution, silently.
+
package main
type T chan uint64
diff --git a/gcc/testsuite/go.test/test/64bit.go b/gcc/testsuite/go.test/test/64bit.go
index 9e91a97fd..7ad28ad4b 100644
--- a/gcc/testsuite/go.test/test/64bit.go
+++ b/gcc/testsuite/go.test/test/64bit.go
@@ -1,6 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out >tmp.go &&
-// $G tmp.go && $L tmp.$A && ./$A.out || echo BUG: 64bit
-// rm -f tmp.go
+// runoutput
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/alias.go b/gcc/testsuite/go.test/test/alias.go
index 639a9cabb..ec93a2d10 100644
--- a/gcc/testsuite/go.test/test/alias.go
+++ b/gcc/testsuite/go.test/test/alias.go
@@ -1,13 +1,14 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-package main
-
// Test that error messages say what the source file says
// (uint8 vs byte, int32 vs. rune).
+// Does not compile.
+
+package main
import (
"fmt"
diff --git a/gcc/testsuite/go.test/test/alias1.go b/gcc/testsuite/go.test/test/alias1.go
index e8ef8a23f..4219af8cd 100644
--- a/gcc/testsuite/go.test/test/alias1.go
+++ b/gcc/testsuite/go.test/test/alias1.go
@@ -1,14 +1,14 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-package main
-
// Test that dynamic interface checks treat byte=uint8
// and rune=int or rune=int32.
+package main
+
func main() {
var x interface{}
diff --git a/gcc/testsuite/go.test/test/append.go b/gcc/testsuite/go.test/test/append.go
index e178f4699..3f6251ee5 100644
--- a/gcc/testsuite/go.test/test/append.go
+++ b/gcc/testsuite/go.test/test/append.go
@@ -1,10 +1,10 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Semi-exhaustive test for append()
+// Semi-exhaustive test for the append predeclared function.
package main
@@ -27,6 +27,7 @@ func main() {
}
verifyStruct()
verifyInterface()
+ verifyType()
}
@@ -230,3 +231,17 @@ func verifyInterface() {
verify("interface l", append(s), s)
verify("interface m", append(s, e...), r)
}
+
+type T1 []int
+type T2 []int
+
+func verifyType() {
+ // The second argument to append has type []E where E is the
+ // element type of the first argument. Test that the compiler
+ // accepts two slice types that meet that requirement but are
+ // not assignment compatible. The return type of append is
+ // the type of the first argument.
+ t1 := T1{1}
+ t2 := T2{2}
+ verify("T1", append(t1, t2...), T1{1, 2})
+}
diff --git a/gcc/testsuite/go.test/test/args.go b/gcc/testsuite/go.test/test/args.go
index ba9a377a6..9cfddc338 100644
--- a/gcc/testsuite/go.test/test/args.go
+++ b/gcc/testsuite/go.test/test/args.go
@@ -1,9 +1,14 @@
// $G $F.go && $L $F.$A && ./$A.out arg1 arg2
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test os.Args.
+
package main
import "os"
diff --git a/gcc/testsuite/go.test/test/assign.go b/gcc/testsuite/go.test/test/assign.go
index 2192f9ede..da0192f83 100644
--- a/gcc/testsuite/go.test/test/assign.go
+++ b/gcc/testsuite/go.test/test/assign.go
@@ -1,9 +1,12 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify simple assignment errors are caught by the compiler.
+// Does not compile.
+
package main
import "sync"
diff --git a/gcc/testsuite/go.test/test/assign1.go b/gcc/testsuite/go.test/test/assign1.go
index 71e5b4064..b9e0325ce 100644
--- a/gcc/testsuite/go.test/test/assign1.go
+++ b/gcc/testsuite/go.test/test/assign1.go
@@ -1,9 +1,12 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify assignment rules are enforced by the compiler.
+// Does not compile.
+
package main
type (
diff --git a/gcc/testsuite/go.test/test/bench/garbage/Makefile b/gcc/testsuite/go.test/test/bench/garbage/Makefile
index 8002a2017..98838453a 100644
--- a/gcc/testsuite/go.test/test/bench/garbage/Makefile
+++ b/gcc/testsuite/go.test/test/bench/garbage/Makefile
@@ -2,27 +2,22 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include ../../../src/Make.inc
-
ALL=\
parser\
peano\
tree\
tree2\
-all: $(addsuffix .out, $(ALL))
-
-%.$O: %.go stats.go
- $(GC) $(GCFLAGS) $(GCIMPORTS) $*.go stats.go
+all: $(ALL)
-%.out: %.$O
- $(LD) -o $@ $*.$O
+%: %.go
+ go build $*.go stats.go
-%.bench: %.out
- time ./$*.out
+%.bench: %
+ time ./$*
bench: $(addsuffix .bench, $(ALL))
clean:
- rm -f *.[$(OS)] $(addsuffix .out, $(ALL))
+ rm -f $(ALL)
diff --git a/gcc/testsuite/go.test/test/bench/garbage/parser.go b/gcc/testsuite/go.test/test/bench/garbage/parser.go
index 9e15f6c0f..b91e0248f 100644
--- a/gcc/testsuite/go.test/test/bench/garbage/parser.go
+++ b/gcc/testsuite/go.test/test/bench/garbage/parser.go
@@ -73,7 +73,7 @@ func parseDir(dirpath string) map[string]*ast.Package {
}
func main() {
- st := &runtime.MemStats
+ st := new(runtime.MemStats)
packages = append(packages, packages...)
packages = append(packages, packages...)
n := flag.Int("n", 4, "iterations")
@@ -83,14 +83,17 @@ func main() {
var lastParsed []map[string]*ast.Package
var t0 time.Time
+ var numGC uint32
+ var pauseTotalNs uint64
pkgroot := runtime.GOROOT() + "/src/pkg/"
for pass := 0; pass < 2; pass++ {
// Once the heap is grown to full size, reset counters.
// This hides the start-up pauses, which are much smaller
// than the normal pauses and would otherwise make
// the average look much better than it actually is.
- st.NumGC = 0
- st.PauseTotalNs = 0
+ runtime.ReadMemStats(st)
+ numGC = st.NumGC
+ pauseTotalNs = st.PauseTotalNs
t0 = time.Now()
for i := 0; i < *n; i++ {
@@ -107,6 +110,9 @@ func main() {
}
t1 := time.Now()
+ runtime.ReadMemStats(st)
+ st.NumGC -= numGC
+ st.PauseTotalNs -= pauseTotalNs
fmt.Printf("Alloc=%d/%d Heap=%d Mallocs=%d PauseTime=%.3f/%d = %.3f\n",
st.Alloc, st.TotalAlloc,
st.Sys,
@@ -142,9 +148,7 @@ var packages = []string{
"container/list",
"container/ring",
"crypto/aes",
- "crypto/blowfish",
"crypto/hmac",
- "crypto/md4",
"crypto/md5",
"crypto/rand",
"crypto/rc4",
@@ -155,7 +159,6 @@ var packages = []string{
"crypto/subtle",
"crypto/tls",
"crypto/x509",
- "crypto/xtea",
"debug/dwarf",
"debug/macho",
"debug/elf",
@@ -164,7 +167,6 @@ var packages = []string{
"encoding/ascii85",
"encoding/base64",
"encoding/binary",
- "encoding/git85",
"encoding/hex",
"encoding/pem",
"os/exec",
@@ -193,8 +195,6 @@ var packages = []string{
"mime",
"net",
"os",
- "os/signal",
- "patch",
"path",
"math/rand",
"reflect",
@@ -214,11 +214,9 @@ var packages = []string{
"testing",
"testing/iotest",
"testing/quick",
- "testing/script",
"time",
"unicode",
"unicode/utf8",
"unicode/utf16",
- "websocket",
"encoding/xml",
}
diff --git a/gcc/testsuite/go.test/test/bench/garbage/peano.go b/gcc/testsuite/go.test/test/bench/garbage/peano.go
index f1ad6ed69..6c7e52314 100644
--- a/gcc/testsuite/go.test/test/bench/garbage/peano.go
+++ b/gcc/testsuite/go.test/test/bench/garbage/peano.go
@@ -1,4 +1,4 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/bench/garbage/stats.go b/gcc/testsuite/go.test/test/bench/garbage/stats.go
index 985e7eaf5..6dc0aeb23 100644
--- a/gcc/testsuite/go.test/test/bench/garbage/stats.go
+++ b/gcc/testsuite/go.test/test/bench/garbage/stats.go
@@ -12,17 +12,23 @@ import (
)
func gcstats(name string, n int, t time.Duration) {
- st := &runtime.MemStats
- fmt.Printf("garbage.%sMem Alloc=%d/%d Heap=%d NextGC=%d Mallocs=%d\n", name, st.Alloc, st.TotalAlloc, st.Sys, st.NextGC, st.Mallocs)
- fmt.Printf("garbage.%s %d %d ns/op\n", name, n, t.Nanoseconds()/int64(n))
- fmt.Printf("garbage.%sLastPause 1 %d ns/op\n", name, st.PauseNs[(st.NumGC-1)%uint32(len(st.PauseNs))])
- fmt.Printf("garbage.%sPause %d %d ns/op\n", name, st.NumGC, int64(st.PauseTotalNs)/int64(st.NumGC))
+ st := new(runtime.MemStats)
+ runtime.ReadMemStats(st)
+ nprocs := runtime.GOMAXPROCS(-1)
+ cpus := ""
+ if nprocs != 1 {
+ cpus = fmt.Sprintf("-%d", nprocs)
+ }
+ fmt.Printf("garbage.%sMem%s Alloc=%d/%d Heap=%d NextGC=%d Mallocs=%d\n", name, cpus, st.Alloc, st.TotalAlloc, st.Sys, st.NextGC, st.Mallocs)
+ fmt.Printf("garbage.%s%s %d %d ns/op\n", name, cpus, n, t.Nanoseconds()/int64(n))
+ fmt.Printf("garbage.%sLastPause%s 1 %d ns/op\n", name, cpus, st.PauseNs[(st.NumGC-1)%uint32(len(st.PauseNs))])
+ fmt.Printf("garbage.%sPause%s %d %d ns/op\n", name, cpus, st.NumGC, int64(st.PauseTotalNs)/int64(st.NumGC))
nn := int(st.NumGC)
if nn >= len(st.PauseNs) {
nn = len(st.PauseNs)
}
t1, t2, t3, t4, t5 := tukey5(st.PauseNs[0:nn])
- fmt.Printf("garbage.%sPause5: %d %d %d %d %d\n", name, t1, t2, t3, t4, t5)
+ fmt.Printf("garbage.%sPause5%s: %d %d %d %d %d\n", name, cpus, t1, t2, t3, t4, t5)
// fmt.Printf("garbage.%sScan: %v\n", name, st.ScanDist)
}
diff --git a/gcc/testsuite/go.test/test/bench/garbage/tree2.go b/gcc/testsuite/go.test/test/bench/garbage/tree2.go
index 6d78f72c5..a171c696b 100644
--- a/gcc/testsuite/go.test/test/bench/garbage/tree2.go
+++ b/gcc/testsuite/go.test/test/bench/garbage/tree2.go
@@ -11,6 +11,7 @@ import (
"os"
"runtime"
"runtime/pprof"
+ "time"
"unsafe"
)
@@ -30,6 +31,7 @@ var (
heap *Object
calls [20]int
numobjects int64
+ memstats runtime.MemStats
)
func buildHeap() {
@@ -55,10 +57,10 @@ func buildTree(objsize, size float64, depth int) (*Object, float64) {
func gc() {
runtime.GC()
- runtime.UpdateMemStats()
- pause := runtime.MemStats.PauseTotalNs
- inuse := runtime.MemStats.Alloc
- free := runtime.MemStats.TotalAlloc - inuse
+ runtime.ReadMemStats(&memstats)
+ pause := memstats.PauseTotalNs
+ inuse := memstats.Alloc
+ free := memstats.TotalAlloc - inuse
fmt.Printf("gc pause: %8.3f ms; collect: %8.0f MB; heapsize: %8.0f MB\n",
float64(pause-lastPauseNs)/1e6,
float64(free-lastFree)/1048576,
@@ -71,9 +73,9 @@ func main() {
flag.Parse()
buildHeap()
runtime.GOMAXPROCS(*cpus)
- runtime.UpdateMemStats()
- lastPauseNs = runtime.MemStats.PauseTotalNs
- lastFree = runtime.MemStats.TotalAlloc - runtime.MemStats.Alloc
+ runtime.ReadMemStats(&memstats)
+ lastPauseNs = memstats.PauseTotalNs
+ lastFree = memstats.TotalAlloc - memstats.Alloc
if *cpuprofile != "" {
f, err := os.Create(*cpuprofile)
if err != nil {
@@ -82,7 +84,12 @@ func main() {
pprof.StartCPUProfile(f)
defer pprof.StopCPUProfile()
}
- for i := 0; i < 10; i++ {
+ const N = 10
+ var t0 time.Time
+ for i := 0; i < N; i++ {
+ t0 = time.Now()
gc()
}
+ // Standard gotest benchmark output, collected by build dashboard.
+ gcstats("BenchmarkTree2", N, time.Now().Sub(t0))
}
diff --git a/gcc/testsuite/go.test/test/bench/go1/Makefile b/gcc/testsuite/go.test/test/bench/go1/Makefile
deleted file mode 100644
index 94847438f..000000000
--- a/gcc/testsuite/go.test/test/bench/go1/Makefile
+++ /dev/null
@@ -1,7 +0,0 @@
-include $(GOROOT)/src/Make.inc
-
-TARG=go1
-GOFILES=\
- dummy.go\
-
-include $(GOROOT)/src/Make.pkg
diff --git a/gcc/testsuite/go.test/test/bench/go1/_testmain.go b/gcc/testsuite/go.test/test/bench/go1/_testmain.go
deleted file mode 100644
index bedc373a5..000000000
--- a/gcc/testsuite/go.test/test/bench/go1/_testmain.go
+++ /dev/null
@@ -1,40 +0,0 @@
-package main
-
-import target "go1"
-import "testing"
-import "regexp"
-
-var tests = []testing.InternalTest{
-}
-
-var benchmarks = []testing.InternalBenchmark{
- {"go1.BenchmarkBinaryTree17", target.BenchmarkBinaryTree17},
- {"go1.BenchmarkFannkuch11", target.BenchmarkFannkuch11},
- {"go1.BenchmarkGobDecode", target.BenchmarkGobDecode},
- {"go1.BenchmarkGobEncode", target.BenchmarkGobEncode},
- {"go1.BenchmarkGzip", target.BenchmarkGzip},
- {"go1.BenchmarkGunzip", target.BenchmarkGunzip},
- {"go1.BenchmarkJSONEncode", target.BenchmarkJSONEncode},
- {"go1.BenchmarkJSONDecode", target.BenchmarkJSONDecode},
- {"go1.BenchmarkRevcomp25M", target.BenchmarkRevcomp25M},
- {"go1.BenchmarkTemplate", target.BenchmarkTemplate},
-}
-var examples = []testing.InternalExample{}
-
-var matchPat string
-var matchRe *regexp.Regexp
-
-func matchString(pat, str string) (result bool, err error) {
- if matchRe == nil || matchPat != pat {
- matchPat = pat
- matchRe, err = regexp.Compile(matchPat)
- if err != nil {
- return
- }
- }
- return matchRe.MatchString(str), nil
-}
-
-func main() {
- testing.Main(matchString, tests, benchmarks, examples)
-}
diff --git a/gcc/testsuite/go.test/test/bench/go1/dummy.go b/gcc/testsuite/go.test/test/bench/go1/dummy.go
deleted file mode 100644
index 4956bc7b7..000000000
--- a/gcc/testsuite/go.test/test/bench/go1/dummy.go
+++ /dev/null
@@ -1,3 +0,0 @@
-package go1
-
-// Nothing to see here: everything is in the _test files.
diff --git a/gcc/testsuite/go.test/test/bench/go1/fasta_test.go b/gcc/testsuite/go.test/test/bench/go1/fasta_test.go
index dcb2d1055..bff056fa9 100644
--- a/gcc/testsuite/go.test/test/bench/go1/fasta_test.go
+++ b/gcc/testsuite/go.test/test/bench/go1/fasta_test.go
@@ -4,9 +4,24 @@
package go1
+import "runtime"
+
// Not a benchmark; input for revcomp.
-var fasta25m = fasta(25e6)
+var fastabytes = makefasta()
+
+func makefasta() []byte {
+ var n int = 25e6
+ if runtime.GOARCH == "arm" {
+ // TODO(dfc) remove this limitation after precise gc.
+ // A value of 25e6 consumes 465mb of heap on 32bit
+ // platforms, which is too much for most ARM systems.
+ // A value of 25e5 produces a memory layout that
+ // confuses the gc on 32bit platforms. So 25e4 it is.
+ n = 25e4
+ }
+ return fasta(n)
+}
func fasta(n int) []byte {
out := make(fastaBuffer, 0, 11*n)
diff --git a/gcc/testsuite/go.test/test/bench/go1/gob_test.go b/gcc/testsuite/go.test/test/bench/go1/gob_test.go
index 00eeed57a..b172b805a 100644
--- a/gcc/testsuite/go.test/test/bench/go1/gob_test.go
+++ b/gcc/testsuite/go.test/test/bench/go1/gob_test.go
@@ -21,9 +21,7 @@ var (
gobdata *JSONResponse
)
-func gobinit() {
- // gobinit is called after json's init,
- // because it uses jsondata.
+func init() {
gobdata = gobResponse(&jsondata)
var buf bytes.Buffer
diff --git a/gcc/testsuite/go.test/test/bench/go1/gzip_test.go b/gcc/testsuite/go.test/test/bench/go1/gzip_test.go
index c9eeb175f..fe4c480eb 100644
--- a/gcc/testsuite/go.test/test/bench/go1/gzip_test.go
+++ b/gcc/testsuite/go.test/test/bench/go1/gzip_test.go
@@ -21,20 +21,14 @@ var (
func init() {
var buf bytes.Buffer
- c, err := gz.NewWriter(&buf)
- if err != nil {
- panic(err)
- }
+ c := gz.NewWriter(&buf)
c.Write(jsongunz)
c.Close()
jsongz = buf.Bytes()
}
func gzip() {
- c, err := gz.NewWriter(ioutil.Discard)
- if err != nil {
- panic(err)
- }
+ c := gz.NewWriter(ioutil.Discard)
if _, err := c.Write(jsongunz); err != nil {
panic(err)
}
diff --git a/gcc/testsuite/go.test/test/bench/go1/json_test.go b/gcc/testsuite/go.test/test/bench/go1/json_test.go
index 5a3012167..614e24a81 100644
--- a/gcc/testsuite/go.test/test/bench/go1/json_test.go
+++ b/gcc/testsuite/go.test/test/bench/go1/json_test.go
@@ -17,11 +17,11 @@ import (
)
var (
- jsonbytes []byte
- jsondata JSONResponse
+ jsonbytes = makeJsonBytes()
+ jsondata = makeJsonData()
)
-func init() {
+func makeJsonBytes() []byte {
var r io.Reader
r = strings.NewReader(jsonbz2_base64)
r = base64.NewDecoder(base64.StdEncoding, r)
@@ -30,12 +30,15 @@ func init() {
if err != nil {
panic(err)
}
- jsonbytes = b
+ return b
+}
- if err := json.Unmarshal(jsonbytes, &jsondata); err != nil {
+func makeJsonData() JSONResponse {
+ var v JSONResponse
+ if err := json.Unmarshal(jsonbytes, &v); err != nil {
panic(err)
}
- gobinit()
+ return v
}
type JSONResponse struct {
diff --git a/gcc/testsuite/go.test/test/bench/go1/mandel_test.go b/gcc/testsuite/go.test/test/bench/go1/mandel_test.go
new file mode 100644
index 000000000..888c5e4ea
--- /dev/null
+++ b/gcc/testsuite/go.test/test/bench/go1/mandel_test.go
@@ -0,0 +1,41 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// This benchmark, taken from the shootuot, tests floating point performance.
+
+package go1
+
+import "testing"
+
+func mandelbrot(n int) int {
+ const Iter = 50
+ const Zero float64 = 0
+ const Limit = 2.0
+ ok := 0
+ for y := 0; y < n; y++ {
+ for x := 0; x < n; x++ {
+ Zr, Zi, Tr, Ti := Zero, Zero, Zero, Zero
+ Cr := (2*float64(x)/float64(n) - 1.5)
+ Ci := (2*float64(y)/float64(n) - 1.0)
+
+ for i := 0; i < Iter && (Tr+Ti <= Limit*Limit); i++ {
+ Zi = 2*Zr*Zi + Ci
+ Zr = Tr - Ti + Cr
+ Tr = Zr * Zr
+ Ti = Zi * Zi
+ }
+
+ if Tr+Ti <= Limit*Limit {
+ ok++
+ }
+ }
+ }
+ return ok
+}
+
+func BenchmarkMandelbrot200(b *testing.B) {
+ for i := 0; i < b.N; i++ {
+ mandelbrot(200)
+ }
+}
diff --git a/gcc/testsuite/go.test/test/bench/go1/parser_test.go b/gcc/testsuite/go.test/test/bench/go1/parser_test.go
new file mode 100644
index 000000000..26580b887
--- /dev/null
+++ b/gcc/testsuite/go.test/test/bench/go1/parser_test.go
@@ -0,0 +1,43 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package go1
+
+// go parser benchmark based on go/parser/performance_test.go
+
+import (
+ "compress/bzip2"
+ "encoding/base64"
+ "go/parser"
+ "go/token"
+ "io"
+ "io/ioutil"
+ "strings"
+ "testing"
+)
+
+var (
+ parserbytes = makeParserBytes()
+)
+
+func makeParserBytes() []byte {
+ var r io.Reader
+ r = strings.NewReader(parserbz2_base64)
+ r = base64.NewDecoder(base64.StdEncoding, r)
+ r = bzip2.NewReader(r)
+ b, err := ioutil.ReadAll(r)
+ if err != nil {
+ panic(err)
+ }
+ return b
+}
+
+func BenchmarkParse(b *testing.B) {
+ b.SetBytes(int64(len(parserbytes)))
+ for i := 0; i < b.N; i++ {
+ if _, err := parser.ParseFile(token.NewFileSet(), "", parserbytes, parser.ParseComments); err != nil {
+ b.Fatalf("benchmark failed due to parse error: %s", err)
+ }
+ }
+}
diff --git a/gcc/testsuite/go.test/test/bench/go1/parserdata_test.go b/gcc/testsuite/go.test/test/bench/go1/parserdata_test.go
new file mode 100644
index 000000000..113e5e3e3
--- /dev/null
+++ b/gcc/testsuite/go.test/test/bench/go1/parserdata_test.go
@@ -0,0 +1,245 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Input for parser benchmark.
+// This was generated by starting with a the contents of
+// src/pkg/go/parser/parser.go at rev 9b455eb64690, then
+// compressing with bzip2 -9, then encoding to base64.
+// We compile the data into the binary so that the benchmark is
+// a stand-alone binary that can be copied easily from machine to
+// machine. parser_test.go decodes this during init.
+
+package go1
+
+var parserbz2_base64 = "QlpoOTFBWSZTWd3QmOEAIYdfgHwwf//6P7/v/+/////+YEhcAAAB7hwvVWWaZT1X0dt999296z5B" +
+ "3mcQqlBVVVB7hnASWJoFGq9jlHvZHRbdfIB0Hz6fW+jrz4dueD73be6c33tG7la1O9d154ntzzk7" +
+ "jnU+O50zayubCulvgBm7rou5jleOe730dzX2sUbWj1u215X2PBXY17GB3Y3NznVW7ubOuu5a5wHc" +
+ "d9h69Xtatru8+D21uj7bM3lBKdRzPul3bt3GUtvN7z1PfCU0QIAmppkxQYg0Ap5NQZTxR6myJp6m" +
+ "T1D1NMgYSmgQggmiajIZKep5R6mh6jyh6RoA0BoGmg9RoCTSREEEAnqnpqbKp+alNk0ajR+qeiNB" +
+ "k9TanpMhtQDQBJ6pSkSTyPVPU/VP1PShkepoaGTTDSBoaAAyANDQMIkRE0lPTaZBTyYlRp/ok1Pa" +
+ "Rkm09Gk1PaptQAaDR6gPUESRAmQQ0Cnqm9NNBNMlPyj0iPQyQaBp6gAaaB8HrtSFgsiaNsTLSbZS" +
+ "paVaq+DW1qDTQ1FEYixSRiwlmJFRJrBmbIYoNEYoylREClbZLFikJKNRBFApgUQ1GShKjaSyRCCG" +
+ "UixqTabS2lLZiEgaKDZLMoxFY1o2LULILGDEJsWwMhbMzWlpbZm0bCaSS0NlmDGZIiRWIoxorEiG" +
+ "IxTJIyIGU22xsKzSqlMUUmjYE0bTGWaalWxLIlMQqECLEliKYskmLSSjKTKRYGRZmUZpARUKYttm" +
+ "ajIMrKGY0UUglEiWbM0tJsbGyzIk2myi0ZVYlsNRhGlFhJVKmwxloaVklNFBtDIZTQkyhowI0Qxp" +
+ "JTJsyVRUijUs1e9rpIS0kNLGYkko0WswwxrCAwJFBiLERYpFI14/l8d//VUo/f2Ofl/4/PMmROiP" +
+ "+X86qHV/m2eKhwgQcW/w+YWCErVRZu5/WnEVaZnt7Tfo5OP8TQ/6bme17VqPoaBMhDbuEqkuzjiW" +
+ "z4vygpH+2bkcU5nBikvEzgwxXZ804V1e1KpfovBAJKnhrcaHdoN4aEJHqHLUlmyGcSUjUdCvTYRP" +
+ "65aIz4POFpBLH+m+1Lbs7kPa+GjGbi6lF6kRnzeuKKJqJcsR2+EnuemMS9kr4tXWry3r+bgQMkhI" +
+ "ZkgILVvncoXREIltDqJkTlIBmQtrNEYdUFfdE6C6Uevosypd0519H9t17FtHW8FHImhH595l8V5y" +
+ "Dy7pYjFXqJ5ud+fYaJuGUNoK/3zpKZs3XTCeRxe50nakx0WoD9OZ5fgiko2ifKT2JRWE470vIn9q" +
+ "YqZeDApYKszMZ8Mp+S+W5s96YNXPi2dlO/D+1qHRSrLkH4VE7L5oPiWGXTwos+dnwniXQoVKJu+K" +
+ "Y9bmXzt/02qIskOq0b5TG05twenXqbgV7hVAkTElgmqsqORvcte/dakNMsd39HphWvVaeJ3rcihv" +
+ "cJ044ShoPW1kUxBbyYXSVcHhwcPSlRcSVjjMnnOumoi8tmS0XNbV8t7YwYi/pxq8j4IDzF6Gjjac" +
+ "8IstxcUEu4RJ7FipOLfio4rt9s7lfyvvwluT97uTcrpUBmf+k4nmsClh3fSIXpUhCQj0vMkt3PMf" +
+ "iudzHKBAPMXLy7ghISaEuIIZU7ueq2srC6YYkS+GIpVA78WOscuCQLNvB3uP5O/z7mxPA5zkIjIv" +
+ "KdUOFSCIx8N/Dub3Ur4WwQSti9vd16B9/Bzk1g28aiXYmRHTrN0J4cW8xmekkkaIMQXypKnBPZeW" +
+ "OTnpXqdzrz3NXv88RyB3SuMMy9e+YJ0LfvtfRletL4X4fU0YyG2EurWAFBlGvZ9Lzc161b0vZR3B" +
+ "lL54b52XxrzvXeyu0qCh3+Nv1LgzQhtksL1Oay/Q6uVSRCofJ3ZjFUiG7BtUBQ3ZQrIHZJxdYAou" +
+ "EFtGQkRJCQq1JlE0w7e/NTTmJ5ifsE62XbIaTAca2fb4+p0d8L19KX8vFwTin/n8OvB6c+3w6PlS" +
+ "2goNsUIjAKysBZEGKrGSj9cuNPj5nrOYVHPsxLdGaeVHWXgKPR3anI5fKwnR8SM4fFetyzwPhxw0" +
+ "0lGM5Y02qqy7YY3+xFTHU9QtR7daZLEhpvsY3iDlipq2XAQehwfn9cm34kA9P19rUJ+RB7funX6O" +
+ "rB5/xJ4dxpknnVZFXSwLq0tDC4Oze4TN2dOHZ+HL8OJ6n/L8WuPeXeMpMQqItn4ZQfO+L6Ptnu6u" +
+ "udDLKkBnS6yOVFVGKAsixPT+D24mcn109jn27PhPK6x803RI7pvAz3Q/nYYY74mSvWccNSVVSvyz" +
+ "c5IPV1UejZKjmnB3wuXPfG8LTTGrMkIz6mh9EbgSSBOQqmfzXu/57PRZlKcl6buNSiCdgf939gq+" +
+ "zhn356ZdFGoGUfVHCdBp4HXcfZpWfVbdNxh1rxI/RvAK/e4fAR+AkS75mGZTvK5T2ob4g+HlN+LU" +
+ "ednbpvXKTzu+BgxnhWG7i9otZECZps3pIIspDTLQ0P+o0Ryw/UOpt+F7zIKwg3cxA7UQX8rxDUxI" +
+ "Ub/+uw6Qh0xwieVzEaeQKh8s5uI1o+buyWpo8kZVwjBN8JdsHV4lj5tdUIiOuIqskenyFpkcNGgK" +
+ "cV1ohgEbXdcF1bm2LHZwKinccZZqRh4EXGbbqNuTSUTM06DGbwI3IfZcrrVlRlyGvUPnKeM2tG+p" +
+ "U5Nk1fWcKXovwi7Bpm85156nFylux70tJGHWaxNqGt02UGzMM04bJc6GHl57m9PfjBeQ+vlgtDBA" +
+ "KJkoKJEjXjnqvAmY6RkaCUoeo1mVlVA+uUmbbBqU8dYZIxiwRH3Pxc3bOD9uB5Jlka6An6c9B9km" +
+ "OnDL+FHQTYNwgH8mavZz0iOu+Ut8/J5ZwyoIamzhyxBs8262E1X8Xfhle9iE4rVPPFLG0iTioWAU" +
+ "d3xVBGn0oRJqbxtUaxhpdln5NtolGMj59U8pg0/RSY4z7US2Ms+4/ppi54Z8T9x34FrNnEaNTupy" +
+ "0wwbD4jnv7F8vm1WllYykpcbxM8YVxcrK1o0GGUBvVUGqDpjwLUr17oxmaKusyyrqV4yu76rlNga" +
+ "TtCAVGwYMvm+SLMenn6P375gmvYRlpqskpNDxFJcfbkZ8bux2QkkYKLPJlJSlbCOPNDfSULNSdHM" +
+ "12MvGjz5tYTNEbhq9fk6J0QCf04np5cuTvdC7SzdPmMDWTDxiD5exXpVi41UM6eV+926tnWjqo1q" +
+ "KZvLp3rjuvrmxbB648TaJlIjEgjUx2qKW6HRaInEGHsXUxFRTPPAsGXwgtoi1905O44+FkV9ctb8" +
+ "7pZtlllncqNGbJqP2LVNqa9WBOlqMdkm1w8mO+Ln3BLUvtWWl/CjfABpSq7mjGtMdPHs3a9OeOVw" +
+ "FHvW2fQeG243Jl69jvgx4jbSeVZ39VcNZNO5EiPRfOTlBHsZXX27TyO0b+abrFZ3Bwdx+c+uRVo/" +
+ "TEFzLJ4uXS1FoXdJblwzfjW0rcGlZ5Jqs3Gb4iESyfmdVpU6i2DtBPBtsn+nlb95Y0pWMDBM3ZBZ" +
+ "pyIEncddO3bafpssEObXLaLNvraGuJMzgiNF3+t2uZC633wwUji1sLoiU6X4kuZkEjKHnqmi1zXF" +
+ "+dM6MTtO9N5yDve47yIt/CkoVoTbWfc9E1Gs8e19PLxPS0i18ldi6xjw2bsWfjR9Dp21w5ImY6xr" +
+ "3J+BF35JgmZMT8PbEXlDThrTfEMkkrCcD1u+XbyIkkjGCc6Vc2Vr5X53XPuwfOuM31yem0tXg9uZ" +
+ "1kj2P4Hx03wa13qdX0xDFNlPCYxkY+xVhq2lCzma5tkZ/FD3755LyZbdshsWTGsbInzJ39+zd/Ly" +
+ "PMkJ079dteGN01Roys7oKtfDIa/N26YWY4Poq35WHTCM1DF7S5me2r5ahhiLl0ch545YQ+r57a4+" +
+ "Ls9VjY5Pswwk2x9S45uMQ770ssfjbRB1U2hF/DV8nak751LqONvJs28E0JmDcmEwIr4sB1uClx2b" +
+ "PpWuRnAWq7oEmSBKbowbbW2lGqi1nh35psMxUZ4d+FxK4uHVZNA7vU5qm0rUs1IoT9jPLkrzJ83e" +
+ "t1ZM+BwItwHrFPb5jtL228eV0ZUpLZphfFKj2DCkzbKiv1ODiobghZh44PzyoxgKV5SnP3VUGTRN" +
+ "h9Nr5MyMQvBNTHpiwN1N4241qJaQRhUVtKiMhjJjCNoYkMErArCTYOiM3SF88PVh9B9XSdDzTkqF" +
+ "hbUSnyoH1EwYMUaOhcqJmWVqsWHxhPCckWK3GaoqMmowMyzTBWal1P5eL2sVtZ+drjsx40brxVOg" +
+ "xhzdgFm5kg3UcZubj4zvW6QQgvvcd3x612pOT21AWT5bhwppdXYsSL7GRd0DB39io1hcZp98dpdP" +
+ "I7tjczPaDZBPL3EuO1nUrIw7csHF06ZNzmmUd+3TFNPvpr63hVjYTlSF4RbMRaymDlUJwWzYoxO+" +
+ "Ig6OY5Pjo2li+/s0+z4u+7OhBI5khOnopHj9a8efW8cp+r7kZeu8s3bbvYS+DWbWy1roJ0p1AeY2" +
+ "X+fziwq7PTod5KluzFOwS5vjjtukunB1xtG3rkji+868nZBbnTAgkLNN9Ezlg98Zlxha5827EPn0" +
+ "5OW6tutYMa9O+U5TiKz0ggzo3G2J1u6vrY40j3UfBNuDg2ONsRwUmNyZMREtEUZK8Ifne0GcxmXx" +
+ "L3F7fRIQk3RU2t4jbit2VdddKuMkXMTSERChLhN68Hj0bbJ7JYxZ8evJ8+Y5Lg119jsTYSQ6dxXs" +
+ "VKvg4DSyNLKMC2MsbYLARKFWKlCw5wzKlkQYWgttGacw160+Qze+GHCZbC2hGlGVjaX3h5YYzj3f" +
+ "DFYvzyl4YkBZrrrZtfQbVtkyqYQ+rtBBDGBnuPOcHrLOPXfllLstfKRrywI0ctF5F0qltBsNN9Rh" +
+ "msY8es8xjHtcrxnobZe4k3Nuc51d2e2RHRpNSdoNbT25KkUrQtDy69Wxwnnyc1tdraRFtHagZVH9" +
+ "q2swXNQyLCahLQC4szGKaGZKqLSiD3FjPm/7PL5ZHq/XmHmEJ77utU9tZ2zp/ODPCfhI7MvpP+fy" +
+ "16rtvaad6gz2zk1d2YaqMavtFjzK6opMh34RTf/flWMJ0d7tOtpgM0vJ8dPn/rfB5LrZc+fPfnI5" +
+ "rc/tsb5rm3jyV0qOxk6ObY8ZOaTIvk1eLm6lLtZNvtx1laKDXauwgE+92StvSXJZab2zM2l3uYmi" +
+ "IVzSVvVOIE4TEEKad3HGSKygKpCaSo7ct+/dUzPu1tE3+lX/Z7WAD7kwJdnl+r5V6jq7Plwv+rjb" +
+ "GTGL+z9mNjB3cVT+p/DcR60xRs/IsnzfdPSZMlJLJOVkTvp0jO+LfL4X27EcdvPDw3v6OjWSz+TJ" +
+ "Z5l8HIoiquZXPPLqmEUOm39RGa3IwsOfguiZmZqIF2DsDpJJiTapSFYKFGDTr79fD/h/Z/kw1/A/" +
+ "zxQAZAP48GZxmZj/BHm7jPl4tco2zu/RSCM1VNCZI5cwWyltz3GeHlL+w1PK7o8fDTfJUfwq7AqK" +
+ "ElR/1UhrVBdYNUW0LBlGoIo+JbBiaGwNIKCvd/VrVuIOVY+HGZJzZzhRE6ckuA8ticpZOPpOuuXa" +
+ "KImu3UyMxO1amcSxC8mbshm5/lIYjo5kHcND4/kn8sbsRwh++dFinScFgHcTjpweH3aAkjJ7NZJh" +
+ "ddL2dOl6oL1jLNaYM1MgGs52V9cDhBLMwwtZ5YpSzsDNuTpQts24pU5iwhxqgIHKpU1yJCBXnBEJ" +
+ "mSqlV5u7exQh/p1mcnW7JmCri2y1MbKmcokR2TAXipUQkC6CwwQ12Gjnm44X1tVZUp3wlIdJOO5m" +
+ "wrczzu+aFaUilZUS7dnOxbWfWcQeSZ0hL7XHvhkbDzwo37Y5ckj7LmXmHin4QLlw9Ec5/JGyztRG" +
+ "X77Pgow2DsQ6pFw8CK6PUTSTZrWK6ms1J4xnhI0q8I+Ssvmmx/P/r7qE2bRAJB9mf25A5z30NtnL" +
+ "6Pmqft54xt9X3KrN/NSEF1a4R938Ou1vHaOqTRyvO2h+ZZqd1LGaryhzy460Fwfoi7DtiepNdA+V" +
+ "zXPjwfHd+wQOyGMkj0raTGF7VnkvOqpmpZThtUdNn0VJPsKqbdOUAo16juWVKpvxIwUefdTGVI2W" +
+ "xt5rY2t2viki9JK9xd3SJIkOhySAxWJLCGZb4LrTCT3qPu7MoTJE10zkYWgeyawo1blLhbkKGHiZ" +
+ "SLONHph0Zmnz1cYA3RqHbyrB/NqTf4rxWClAjux9sybomMloiRMm9QlnP6Jj5HvtjsYF7il7l0jX" +
+ "MtL9sUMBEpx91hbl+/jW3jqZXfdEZMIOccK6re+rHGqfbGxjYnnDOe8T4OziLqEn8cDo8U3uZNI9" +
+ "+rZY/1+m9aZrGv2EaunZM0m5cU7X1POp5guRbRg2tot/g+/jYyTAipiYd30IhHmjxz8Zc2rQjdcb" +
+ "5CZdXH3fH4T9H42O/j68ZVXgty63afB3lwUIheY9TdWksCKNItEw8L7kwgGaLvc85h6mRaQPm7YI" +
+ "mYnovikrbjd2eGmWNRN588bS0s7T3WjL59IZlW4eJhSFGPW6EDovZLjfDVL74o92s5lyAyQ4INyq" +
+ "gVzWv/j4aw+H6buyxIjRdfRDyZb+NHWrsD23UhRwlyzY42awYWc6lfzag5F55eStTf9rRhuzVROE" +
+ "jAmYZ2bWlICbSehLazA+NNsC7SnKNbXXUMrObZXU0bFu+phdvVja6/DNCQkzS4XqDWlrDytvLVIO" +
+ "fd2Xj0O24X1z453ylFk/j9ve4lz+B8utfOXokeilpTm1L/zvXc5+pNcY/uLmvZPpsezuc4Z+g7I8" +
+ "lVPy/Et9eH+Y3vZIZe+aB/CTMODCDJOMeDdsmKt29WEjDc9AfZ4u1pPukz03zhZ+vzRdmsXjjreU" +
+ "wgzctKJSRVDe5xLLIZmbgWLsFfHqm+F1I9+nyKo9edkYW3R9Ipo983Z02KIfdeHBkMHHn8DW4nz1" +
+ "+5mgdApk5IURBIgEE7boPGAFYAPquEaBic/Rwmnq20EA1FiEVQjBjJBIBfYUfkDwGbkAZUUtZlor" +
+ "CGHFFIkqUrRhxgMJB68bJedguTa7L1cmjNiwpEjFYmlAFEANGhRu+FBdJgUlb+itYpLhS9e+sqou" +
+ "8GwAGRQBD6gRE4/rD9x71IXGomMpBwzAxWCKQqUBQqNKgqXLiV3bppW8JdCriy8WRjlL/y1ldMRN" +
+ "K2pRQFbRHHIpqmjKgqoiL/dcyukplgqt/fhMTEmmVy2jHGg399Na2lx0mApifu28Z7LB3WyX7mAd" +
+ "D99Hq/Cj0hGInwCg7T8PY/TDUMet3DA3yc4aFiKkE/pSz+ovbPD+L8fxI+cfp22n9HmdfqF67pXR" +
+ "+uPpkTj7JuUM554R0uKFZo0uwL/244GOE/tg+zWdJ3fbGmaQg1dnHTLH4+KPnFDj9Vq1ZNL/eozL" +
+ "Oipce/ukJE/6vGGCvqFnbZvqQ34x9B/Cr02eF0o6TvQP8Djg+slju2sLO0IOiOv32aRo+4034LLE" +
+ "svPHM1XAdlzu7umNN0T+MWQPqHjxOSv6tjrUsed7MxDZ6lscn38Yw1ZDHN27SuxtezttN+ryiaRO" +
+ "XO4cZxK4nG9Sxll+s7P2/WoC06HgAniO1M0rO00euOEpcOtyWHtwG/d+iPxcl+LSkORcLIsRkQRY" +
+ "xZkpLTK1Uf7q5MMuiLCRIiIxg39+YMUrdMoqnzK8S9SZNNjS6vRlVG0vLrmmBkmElFkgUhqSZUoy" +
+ "UmokxRtubunYNSN3r7eVeSuxCvS8sVJUbTZpialZgpN5eSOUARUHSKXmk/EfaD1QAkB/R97g+n6D" +
+ "26vxDEMzIsfuDQBwA+SQf6mQD7t/2mqYNm7/n+41MP0TCXIP/o8z8QRjGRgqxFWaMY9g2K3/ibbn" +
+ "CVQUGLt/a2uMYK9wdkaT/RV/f+lsNgbDUGDIrtjJIGxuLmjHdRBiSlIeBRA55x/gJCZKPkGhb5gI" +
+ "JJWoXgE/xQxRGsG8zgwNRkv6s1qmrMuJy7kvcz9XJcvrH/OQ/BrAHAYpIjVX6fsgUoh9SE5Nnd3g" +
+ "zZ5U311/Jt21rX2reXWLDTZ/Plt2iTpC7o2wIXi1ZXpMuC6o8jl5NNK1ufiCI4QYZ8zRkXIHc+o2" +
+ "dz09LIeRrw6SiggEnXNekIZCX/GNh80mkAv64zdnUUYI0HBAe+mYJ+Nr1mrcgsto/JjUU7aG0HJw" +
+ "+mYzx3Gbozde2ufknoISciz5pzjP/aWwB0x5a9CZA/D50hrXtw0a0Z74AjpLgzVltLPpLeL6iG0q" +
+ "eT0iGQ45tex4C64YGHHmL7H5CevzIRfV6WbHr9aOqNxCD9C+CUGRTi4P7HgYpJAYcQYpUDlYDyTZ" +
+ "uEAOmsMCvAloH931YhIqh4pM4neZHlDC7ge0QXGq3/NLHebo/hoKeLx0j4W6vYfxgmqONk1Z7due" +
+ "evpJXmdZdgqUfrP4SJAw0cwobQOPhxgmZKfQ6vLuWksVK01CgzfuOkOo9dB+BxE22TtpuR0dZtWx" +
+ "5D1mSnijyQwYG81v3lFp1zqdJyCT3oUR+eWUtlMov3JgIyU0IgUjij0OEElhAMjJ+KcAgKEwiian" +
+ "dEBke53FPGUpTUCivh9BPQ6TeB4ItgkHv95D5ja/YbE5Kcso/Ah83Gd1SfgrmWZa+wPapwe4uj0T" +
+ "jpLP0z5aD7gqh2N4eknQHYyEYxifBLfE73Xh6/iQvh0EgZswbko0hjTQy+okSCPz/dRWAhP5wpqw" +
+ "140Z3KDUno9Mj1DVf4gJcEhAuAxueaRvE3g3ECbMUAsVZTVzNPYDHEzgiCIDpOcyoJLlCUYWcet4" +
+ "7ePfQZgnwEPNsoYMlyTqz+j5vpktwW0r+fzEMVLJS375MNcESaVLotl3VcK3PHTjsVVFJ3ImDNmM" +
+ "xZAMde2fScG8uc8ZcMpgfnzNJbcHJ2tm5zhDJDGicfN9dMfMjVUO1RR+3bf0eOIquh8+LnG2HusW" +
+ "sWYE+LoxjDBuDur0G2LibFPEDPZ4d2LsHxCzY+kya2SyDctcxxMbhDQmjhzXanEHsHH8Xxb+M/5d" +
+ "lqVPIKkHerSdSSUu9nMGRBMD0tkxGAww5uHB3dbnIY8H4jKEJt549/JdtanPlOc7z8dWrmousQIS" +
+ "QPL3dohW47oSBtCNlmbWOTkS4SZCy3G4kR8IhnaNmh5eqaUO9Tu3ljXXoe56jpfcnek/iH+H1vTx" +
+ "ToHonOg8Gwcx7QnNg24NQkJjgF94VHeqSTLUDqap8BMXW7Rgihk0fA15wQ+fmff999UT+MVilpVv" +
+ "9/P9iHQYfglcQJx1eTrPcf1s/YP0/8f1/u/caT99S5oXWNyhVBcMwDsM/jFSrOPBDwI70ki97A8P" +
+ "h7POfVftueN7/4bc3zV3EfGmj4EVKYLiCEiDYLHGYX9qm0SEAiRIEDuA8Z+YiYA/PUEkFF+MAKiR" +
+ "P2QpOQQdhjIkDIH1yFmsx7DTsealkpikVJonTCoxIp16sK8zzCRJJCfB+vkaptsMEMjbzVE6/9CC" +
+ "XslEEkDiZnPqb7xvvLWb6EBuGSpbCWJbOzPPIekhGTrDqCgCRGXg7wE/WCI+xZbbCVCIkySVhDU6" +
+ "iSHwoqKSnM9om4Z+VKwjShuINg52K8xiMgTwcy+gB5aaaOlIdh6ltZRzk3GM2E1j3QVv0JgtFBEi" +
+ "B9KFkiEEIztjqiVuhtcVgDgDMCQEiQclOBoAb8j0kNzmZqMgqIQiZyBxTqm6JIyIan6NinYhxYSG" +
+ "JyxBA7ymhR8re9Z0wbHbWDFwvUz+H2n2RjBgBMwyhQIayPV9Z14rzyRErRFjaGPLy67W6iyXl3Bi" +
+ "baZCCO67rXs83l5nOutKxBdZDJhhgR1o0apYxhmB4jBgRjEkIT4M9v1zp/I+fbCK8HnO575lkn/x" +
+ "DEhI1lUimGCeYmY5MEkeC/y8HN0fCoDIwZ9/3pzHcanVKpKQPfBNYgf8IpQ06r+VWJIT5W9+InZH" +
+ "GBcbENwEEToXgsIRM0+tLJYkbNix6sWTPLym4icYJ6NsCHrhCHEKRg49maIIwxhSFlsVLRgmJqBb" +
+ "AumFgMpAs0VWMksRvTYghmJ9oesSkwRgrCKDMOdW2onug6Y0rN142vIQBbkKICtRkQq6UsiWaIXf" +
+ "c4N2bAwue2bqKYCGpIiOjrJ9ILIqidEw1MsBF6lIgwsIUJQClSjJAxAJoD8OKwGYB+kzQbYCMTnC" +
+ "nptKOOJa5ZHsK0mYAYNjHHrhFUh+gdf22ft4lhwoht/4iB7pvf74yUstSpWW2BpaTEzMUNDT3+Xx" +
+ "tPZn5va3v7uWsyKsGANWqXAuyIX15bBzAkZcp8ThuDWjZkp7muszHKImsbggb0fmTRp3aoY0BZww" +
+ "qBtlHwvDMYcNnFUOcLBBiqRETh5a8C65MWUeQ3hMEGJA4axRgXCw3LeXMtTZrYS7gOPxqwk/9yho" +
+ "kEN2xaGzpqw0Sx7DP2Rx5OAjGC2nhkCp8eZ7Pcl6KjB7Y1OtCDUXvxr/fIo5Y61MRMo4QBdOORqc" +
+ "H7TSFEUZGRhWkgiiS2Vg2yEsAtkkoqEBBMU6tPGHlxJyOznTetzfbDkQQst0/e/824wA3uKb+eks" +
+ "8KhidRlsSMJBJEDAGfzk7/5Zwkpr3THH5M4PBEx5n17Ub0qggdJM6LfZGplTeD7d7M4RbsaW+zIh" +
+ "bbHrVtBWQYhgTBtzG8s+zmYYfbLM0FtOXg3zdMTnLhLwVII2G07inYX08zDn46f98SfttMDc7tdq" +
+ "tR1vJxHXPFvm56Di3fbb7CB5oO2a2Qkju78J+mXaTrL884tikdO2h9ScaToWOhUMzwO0W+zHSZ3r" +
+ "gy5mzHTPHYxsYRs8BGEQ+z4iyuKoWDUuxuuUwlwHdjD1w7IqRDSnYXEtsIFvacd43TY41gWmzczS" +
+ "imfZnvZw6hxrbbgziJaIZmveTeQXOoZsrON81oli52q8qR91ydprp136HHBswDP06BnoTlbpY3Bp" +
+ "hxKurWoC0sheZ0mG1NnXPK+WlJUMluUhjBkEb5UN5eLeEtxZkYYDTjx3XXn15raUWGBjKdQ2iYzq" +
+ "u80wb8DmFyWsdxFmhLGIyYgd3WU0Pd8HW9zvOpFDiJdh5QzUuMvN1MXW8Xc3O0TnOCSjDNYZY0OO" +
+ "1l7JZqnMMugzQwuoDOzTRBiDjHcGRGNUQQ2DOnKqECwRXKd7FCkOgWFiBxOkpCHZANAzRcxiCQYb" +
+ "TJBF6CLIoRQDtP4fLn9Peg4WBtZDpZ5UAwYLAEQURCfyfn6S47noxNAXMzYSQFhCCyECABAmB0Kz" +
+ "sw98wXf6rwgt4pBiQBukIhpoDiPT1PZtXMNxjvUQ4/qymZQ5rMw2BooMJn8SQkzvzpPgv1xtKu2M" +
+ "bMMfIRhYQNysAjqwTTY7i2ZqmOtw3gIc0oq6OqHWU39P0my8MNYbESokIP1kAOhFL2GQCw5GcPsj" +
+ "5BJdoBvGEeRzM8J2Jyx6nk5l6oJCrEGKvhCHMTXB1hYG1fP3a1n2ZA7vGrcbs+3KApFTBlZS2mMh" +
+ "JDECQxtcC34jSXUwOnsNeEHhiI8GWOiMInnEM6+bYdZ4z4ezEWCLEioyDEjAFmk+g8b2NRvRdMbj" +
+ "ZSNjM2KKmb6Ha6hS2zWlBqPh9L2eW2vVXy+veMsGVCKUsUCSoPWmmGMsjWUJLl8YlplnIPSBobnz" +
+ "ppHclkdYC2eWr5gqG0KcDtgoe2Bm1EVjFJ0rBCCqWhOGR00mSNBFDeJuA8I+jSGykN9il6Shmj1k" +
+ "D88BYgyLCe6lM1XjJDIY5DwVNmny26pmRqq5hxN0770E37hPulwMJkrjLS3TImIOLamTjAFEyWKm" +
+ "xQFKMhxOvYsr5MAgQ3/OJ4QOYm5WQP0hXg5AA5xQYME7fFCoBIJEOPM32CAfqQ2oO5cPfF8JERhB" +
+ "SU0J+SCWAXFy9RupRaY/bh9QdwQP3sZJHx6EPIQ+J8mOUvp8vfAfZP4sJgRGLbKMUgxAKRkKrCEi" +
+ "viWV+jrJIglYLIRqj0ko6QxcWWHtEoXyCSQbiZMgAicn6GG+0YcTCSFz0sVIOk4Sfnequ1CyymVQ" +
+ "LQ3mt2q9FRkJa3zVEkFgJjEzOjuygElBVCB2m2ZUnPzGrmfRqfDs8KSCiCMVjGD5EPW8dBEnA/dZ" +
+ "26RHQB3mI9AGQ0dG8Yez3OW9Uo2lBBthKkbYWuYUzxyEODR/OB+Mw09HWNPsDiBdsvpDYtitRVJQ" +
+ "bURSAxT1TiElh9RIO5SqWwOMh79GtpJXuRhkfidxAn0IIP0sULRYwRhbbbZVw8w3Dx69lZ8oQtn+" +
+ "wP+h0JOY/eeT4y/Y+mynVjc5IYJQb0t3QkHIPqgQ4JxJmb5W/6+t16TV6Q+by3Xlmv0stEbJZYrP" +
+ "3Vpoa9J+LBhGBGAPEoVOegvTxtQgwZRI2goEUkkG2VKwlJ0nh0HWKmRzfwpOI/YkTF/JwVzgiceK" +
+ "QIjIE8TnxOv173TUwNt4te2B1fU15wGEE6oPpez8o+JryMT3HvDXaF3ii9ywJEDh29LbRHw35sTZ" +
+ "HTbm0Dz3w6O+XOshot1XKs5Lyq9XgmgGRMLOl2h0wOL4dK8nS97r4YhKE+/uuOPkGz7ENQzrDqaK" +
+ "eCCxggisgKqJQkgGoosJGYdV6vjqW6etE4h8zj2jpuIA8yMkgoSDUix+cZAYrLAfWAwz41REqpH0" +
+ "nyD7fFGk2pLUWmZq0jVTaV87gpTimFoMk6CG0MKU9N2JZqGZMCzUFNQKXCFie2Bk6NFkN2iahqd0" +
+ "TUL0PoBd0Z290I/cUoEZ4MYRRbKLTp6ZNhloaSFsqo0paokUEGQjIQIiRYC/pNEC6IqiF8Dkeyqn" +
+ "JJo/j+AEzeusxpCBHZbt3Z3nEOiGpTDhSLd02YNlpvN3JN2biuIUTWVJkqlpZm2SadzIymtOoIwm" +
+ "9Cm4MSGFJl3fXvWwqG8TZUw4NAZGMJrJOfufKAya+i0Gw7zE2PDQVPZippYfkBJIblusI7LkQF4w" +
+ "TieqM1Q391XtVi1ECRGwuacU3RoM+hiBIFBRIZW/vXKsjEOMVmhRmGZaE7y9THsnwzG4vjKAkhGc" +
+ "wJ1qQdFgniU0EqNFctIja5vRKLqjOiKgxZIk7lAoBg22zgmZRQssDPaAyL90EObLBA6eghCMQhdt" +
+ "CL5/ses39Q/Kjqia4HvV7wOFvEaShymnHiMeJQ0SYBGE8aFnxalICkMPOw0qOUl3Nwgckkj8w0L4" +
+ "9fVrVNZNOPnwdJycD9FNJ9886azUp5tqGY+EAYeKTfvgnWyMDoYgZGLDNSmJnCqaAMIBkGdDc8rR" +
+ "RIpCpUktoRdFzBodMKjG1K865pNFr0q+DTbT9cKuI6noLmhbcIUQFHS5v377BVJTsRM38/k7bjVQ" +
+ "/QsGFAWOwy4omnhwaQ4dir9UBWLBQtxIJqOc0kd+1gLNFJRamnepDQhCb0D22mGERkybwyhxbkvG" +
+ "DfXrYw0hu4GOIYTDa3IR130b1DVq4FlBjTdyZZILa5cMBJorNMsfJKzYbIZibbkDp9eD+qcSCJ+Z" +
+ "Aw6J6JiTwaKiMsCRrPJo/VKomqUUaNX77+KQwCQBk8d+WuyGzDeB+XezzxcuJGLIhkMpMD6P173X" +
+ "LtobHIhvI8zl/jzAYzfP15Vtfno0bRSr3OiMZIyCc76lEhkyY6kJdFFExO7MSLFNET9zDMoTSfEm" +
+ "FECcF1Y5N4ToR0aUA3GSzFkiICKKM2wagnNB58ypLSPqzEaq0TxVGQloCZoMHKnM4RsYCB3sjADF" +
+ "0ulOqQx3OhD3kXkllMGDo+iI0e2gNQihIWnefq7k8HyQBTwO6HqOTDBbhLDMeBmE3d2ry1uaxUlV" +
+ "9WZLWNc18Mua2SNpqTx2umteedVqW9zIWW4rAboajE0SBhAcQLS6xZdoLE5myiDDRCnAer5IeqVC" +
+ "p4fZ8tnsnIL0sMgb0WgFSV2D9yOEDOg9ScQ8SeBT9Fu13qH0Ia/TilDH0r7/kCRPayBFqjiF41Pn" +
+ "B+IRYJBzdlB68ANn839DLohhGQB64qMgHpYhQyLpQVEYEQUCwmtEiprwfikV8whevoRXFAgbsEuM" +
+ "IAGJosjS1IzJmtC2QVIJ85D3MhplhRsD2JLlKgZlCBGRTx7OIFoaJDWV1p6ZY2MA3mTkVuTCLvkY" +
+ "B9GQuA5JGEEkAIzNyD7XtQedjp3G16IAZoIFHukAm/wpuNsrbW9+RESIe+yorMlloVIl62QMxK0l" +
+ "JIsGBZaSASHuIqUkoOtNsqdiQ01oDA3qvbA9AFEWBFXviyRgWqSxkWs2irRtSWyo4XBSwbCYjsF0" +
+ "JyEDqA876sc4VAoO4NNd5wAlkHoPthseqcSMzdXvnnuMNy9LCQ76CTonH2SJtAO7mFUwWlkEafWW" +
+ "UJgaipGBIwwcBTZozNJTWvxlhY6P1jTHN1r7qs+a63NG80pJo1FGpCgpWmW9G07U7LmClLJRMtIH" +
+ "+XRZByw0WARSKtIlpEEa++lAsGIXNYJSOdY0GZbMFERKblrWECLFCWULJbSgFSpXyNoOytD3YL90" +
+ "xYSQhlD1QLJLQI0He9BzCEnVUSqicw+8My4R9hISYkJGYIxj8ruAhMajQwXdcJGBSBFRYiEzLDQs" +
+ "CajBMxmCr9tr+pNttLXxe3r5N7djRszWjJLEZs1mapMmmTJTQTNpSqUZsNU0JRlqNljWTbV+p7df" +
+ "Lo0rUkVjdV+CKMDKORHjOxLhIwk9G21jFEYFD4XjWjw8wvyPogFPIeTDwiBloHASYHMk8xALgXwl" +
+ "ATRqLTEQYWQsVkWQUKaMBwo7AQKQfAF3fSVyBBLobqUc9N30Yhd9lPGGxI9LQNomLwZp5ZZsMZkl" +
+ "oF2Byvel2w26lwkZCYQKHFs8KDgeFO2+29nFIKMOG7yWYijLbKDKNtLaksQtZVRtZBGNkVAxCiCA" +
+ "Y0LYLJWyyolpYoiIlGrAkS1LLY5k3YQxlKvO3TdNkNSU2Rdd21cyEIcUog9BsnPOQYJDHgyjFjMY" +
+ "rbgvBfJuwtEhGMMokttuSiYYRmQzSrobTNZGFRBRJ0D9I/mJERaCCLCgGiqRrIBlFPnSl5lPE51v" +
+ "mPyjjESFnwAxWlkO96k1MjkQjxldSypErtlBcLC2xJa5YIMOc9hTxTkPSHujC48AnAicrbndNoPO" +
+ "N74pxoN1p5k0VDQyShtPkmhEPSBIBwWmSBAhFI4ntAwUbinCB4hQIFQWEEWCWrvE3qfzQrTTT7si" +
+ "6zQ8MvTyensgBuMEix6adydCOBCBUjFYG+R5YCfYgcfe3KBA528A6ViECYJgPJNB3nSTyDyPKUoB" +
+ "/mQIKxFDYbNYIYrQNbnFO2rWmvkt5vFGebcxXGlIkCiBwVLS2QolREpXmBd2Q8XDpAVtaSkE0BTO" +
+ "nujaCkO9awitnCKKcMnFFHh6fqiPxztdZntuRCeDzyIgwh826nhMzIM2TOwEXW01STLWw5saZe6L" +
+ "ZJoHfoIya3HY79edGjjYfToLT9W+yIpw8X2hhlKhzNjppSbn3t5mBXnyGl+qT7uQbI5+TV6rtb5z" +
+ "y+41+l5LWFxPpRlQGUYQndmJEQkgvWI4R/1s40rG2dyJDQtbruUVR5sPluFVcb5o5DQrT35OfHg6" +
+ "nXsdDhJ4Nkg6D223DHsUoizm1yj4XOdaoIMlVhMBJZJmCIHqgC0gfgz7LGB9HflZG54HCcBh4375" +
+ "6X1dGN+X5axnNu8vqiV7DyNFDXakMyESZcSBwet+6o/TaDQ2yz52GvPcN8lqBxN23CHsR/XQBTJC" +
+ "lBxVhYJyjcQgQvEU1rk+6HSk9vKX+aSBPeAzRGEsBBisD2+XwrWjbRJaEliHqYvlo00yzvSnv9dM" +
+ "IE4khSVKE0W3I2lkgwSAHIhNIEKQQELu+sjBqOm7Ur2wecZHEVHbQYRG+frxWHNZz8VZk4Em5sHZ" +
+ "45CsKUcCifEbXdlIxssZqYYyRUVA+UgcJuAeJwptCkVnJypDkksFFCXJaUuMU2A9AwjZg0nU3GQF" +
+ "qrx3zaKJS3bl733s0xg0apuNuDStMwxlcQVMQQKVQSCZvRLTcU76R4xLMmc45p69aBkD9poNHIAd" +
+ "IFnQkWRDo32AsplDEwLMsMJsGweqY8JPrmunefNpeK8/dLFIqiYhNYz0QzOmhJGEB4LqASPQy9S8" +
+ "obyytQSt66RgQTZZrWZKxiBqQEicBaQPIO6uPfxPFVgzwxzWUbAkltjaNVbTLUj8W+oEtzaWw8tn" +
+ "JhMw+KeonmDEPs9ppd82wYnDsFIVXJTYejCLMRdxe17QzSmWWQ5F4rbErEQhMxuQb6n4lrW+BF4V" +
+ "MbVfZ4moMOjGHVTmNx+DkrbHWs9JZwe2dbvDNDJnT1xJDMtVDIDNVn28eMDhnCKVCs4SsDGI3JRC" +
+ "4FRQycOmGmzVtDCswMNYHQutmo1uWyqAiLp4YmEIKcdLMpQRYzDRcy/Gryi4zHhmO2DrMlwtiFxs" +
+ "y2URYJEW2gl9WQpkJcLLPWevecJ17XXby7blWRRB4c6cgYhEYsM8wsNyABYwJtUgZTpNybGcdonJ" +
+ "jJYb3nicBcbBxDZzEMgiSIY4IkvGEhqJZLjBsFwzJlyJGR+DaLlt2SkuN17TCLhcW8YTBMwUziQJ" +
+ "n52sYOp21W0RM8UC+fKzk0bnoqBHWMxnAW7wCKc/x7rcjpmWhpRANpXlDKoBjEXS35bNSwzddkdA" +
+ "OajcSPD5WSQxnM63z99hzqciJVGxghWs2lipUVyOSjj0zMZ8aVDnmx9pb2tWoKtfFa3u2xrTKS1N" +
+ "7OFeumgtBKKaR+2UJzieUMYBjAIR0WTWmbctjckr7N3VPOru7XMVNk3dt2WIqK02ZudmLFCQkCqp" +
+ "qCyBjGVEdTfF1r7+h+B4O7cou29BYbMh0BFODClliYY5AfJs4+D71Yp7UjPhZjgi333MsPyptUte" +
+ "pFqLJSVa3K525vVziUCCba1HiWF6EI0alvjIt9W7XktfUWvmlum4Kk1aPtoT6dBkB9UaFZ5QZbHG" +
+ "W9Hx/keXtc/nnahU1Y7RoJIXYWFhEDWKe07iby+65oodgnCkf5NWkMTu19eoiz4tB2FkEbAkZFkC" +
+ "QJE2Av9uxj+i4HbYr0Tvi1I5100j8WCciL7h7fGgQTpfTgkJBFPsDsIMZBj5Wy+oD9j+QeOzkqpU" +
+ "q/oD+P02H4E8UHwsrFH7aSsGVsBMw62mEXoSkQ84lgDk6QPTQSKJ6IDuMet75Q5MuoXGTnYascmB" +
+ "kZYOrLA4yQwFTEheZ+Y+BIKiIshoD3MOAx7LfBLUJvRj7KCQhCEoyU2M7LULDIge6lGgjgY1GgVP" +
+ "1KiERIjIAqighIyEC+Xs59Werg1dzsxTVbdmPUHCsMCzELDJzLSojrMVCiDFw8Wmp7p8Vfz5LJrI" +
+ "SQcTIJk0em8ShhFjDJtzeGIl0lZ35N7yVChV+qBCJAjIDCMsy22FjGaitTTZRNUXvy4bk3m7YZ2P" +
+ "WRoBNMYUgOEQMeLhWFF1FeiKoHKwXDHI4GF4EzoogSYlFYVPFwyzgyUiM/HtTQzSwY3/935P/pVS" +
+ "I5ztPxjuSv4UbQOH7cbKdMD1cq9uVWjVUZovZM7cZLxSrw2eWrDGsDgVWAPhYSdXl3xfH0oaTwfb" +
+ "21zqsFhC8NIHdIQSGZveMwM7oSy4ZzP7nD3WnjXGmq73mP93ldP8PvgOpMwbfV1RvR+V/DOnF9rK" +
+ "v9hdyRThQkN3QmOE"
diff --git a/gcc/testsuite/go.test/test/bench/go1/revcomp_test.go b/gcc/testsuite/go.test/test/bench/go1/revcomp_test.go
index 9256164d7..6b6c1e577 100644
--- a/gcc/testsuite/go.test/test/bench/go1/revcomp_test.go
+++ b/gcc/testsuite/go.test/test/bench/go1/revcomp_test.go
@@ -77,9 +77,9 @@ func revcomp(data []byte) {
}
}
-func BenchmarkRevcomp25M(b *testing.B) {
- b.SetBytes(int64(len(fasta25m)))
+func BenchmarkRevcomp(b *testing.B) {
+ b.SetBytes(int64(len(fastabytes)))
for i := 0; i < b.N; i++ {
- revcomp(fasta25m)
+ revcomp(fastabytes)
}
}
diff --git a/gcc/testsuite/go.test/test/bench/shootout/Makefile b/gcc/testsuite/go.test/test/bench/shootout/Makefile
deleted file mode 100644
index e1c9b7b80..000000000
--- a/gcc/testsuite/go.test/test/bench/shootout/Makefile
+++ /dev/null
@@ -1,14 +0,0 @@
-# Copyright 2011 The Go Authors. All rights reserved.
-# Use of this source code is governed by a BSD-style
-# license that can be found in the LICENSE file.
-
-include ../../../src/Make.inc
-
-all:
- @echo "make clean or timing"
-
-timing:
- ./timing.sh
-
-clean:
- rm -f [568].out *.[568]
diff --git a/gcc/testsuite/go.test/test/bench/shootout/binary-tree.c b/gcc/testsuite/go.test/test/bench/shootout/binary-tree.c
index 1b4070406..9c35ac52a 100644
--- a/gcc/testsuite/go.test/test/bench/shootout/binary-tree.c
+++ b/gcc/testsuite/go.test/test/bench/shootout/binary-tree.c
@@ -36,7 +36,6 @@ POSSIBILITY OF SUCH DAMAGE.
icc -O3 -ip -unroll -static binary-trees.c -lm
*/
-#include <malloc.h>
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
diff --git a/gcc/testsuite/go.test/test/bench/shootout/k-nucleotide.c b/gcc/testsuite/go.test/test/bench/shootout/k-nucleotide.c
index 3bace391c..9c3062020 100644
--- a/gcc/testsuite/go.test/test/bench/shootout/k-nucleotide.c
+++ b/gcc/testsuite/go.test/test/bench/shootout/k-nucleotide.c
@@ -221,7 +221,7 @@ main ()
free(s);
- g_ptr_array_foreach(roots, free, NULL);
+ g_ptr_array_foreach(roots, (GFunc)free, NULL);
g_ptr_array_free(roots, TRUE);
return 0;
diff --git a/gcc/testsuite/go.test/test/bench/shootout/mandelbrot.go b/gcc/testsuite/go.test/test/bench/shootout/mandelbrot.go
index 1f9fbfd3d..df60343c2 100644
--- a/gcc/testsuite/go.test/test/bench/shootout/mandelbrot.go
+++ b/gcc/testsuite/go.test/test/bench/shootout/mandelbrot.go
@@ -50,21 +50,21 @@ func main() {
out := bufio.NewWriter(os.Stdout)
defer out.Flush()
- w := *n
- h := *n
+ w := float64(*n)
+ h := float64(*n)
bit_num := 0
byte_acc := byte(0)
const Iter = 50
const Zero float64 = 0
const Limit = 2.0
- fmt.Fprintf(out, "P4\n%d %d\n", w, h)
+ fmt.Fprintf(out, "P4\n%d %d\n", *n, *n)
- for y := 0; y < h; y++ {
- for x := 0; x < w; x++ {
+ for y := 0.0; y < h; y++ {
+ for x := 0.0; x < w; x++ {
Zr, Zi, Tr, Ti := Zero, Zero, Zero, Zero
- Cr := (2*float64(x)/float64(w) - 1.5)
- Ci := (2*float64(y)/float64(h) - 1.0)
+ Cr := (2*x/w - 1.5)
+ Ci := (2*y/h - 1.0)
for i := 0; i < Iter && (Tr+Ti <= Limit*Limit); i++ {
Zi = 2*Zr*Zi + Ci
@@ -85,7 +85,7 @@ func main() {
byte_acc = 0
bit_num = 0
} else if x == w-1 {
- byte_acc <<= uint(8 - w%8)
+ byte_acc <<= uint(8 - uint(*n)%8)
out.WriteByte(byte_acc)
byte_acc = 0
bit_num = 0
diff --git a/gcc/testsuite/go.test/test/bench/shootout/threadring.c b/gcc/testsuite/go.test/test/bench/shootout/threadring.c
index 2c4fb7751..a518134ba 100644
--- a/gcc/testsuite/go.test/test/bench/shootout/threadring.c
+++ b/gcc/testsuite/go.test/test/bench/shootout/threadring.c
@@ -34,6 +34,7 @@ POSSIBILITY OF SUCH DAMAGE.
* contributed by Premysl Hruby
*/
+#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <pthread.h>
@@ -57,7 +58,7 @@ static struct stack stacks[THREADS];
static void* thread(void *num)
{
- int l = (int)num;
+ int l = (int)(uintptr_t)num;
int r = (l+1) % THREADS;
int token;
@@ -94,7 +95,7 @@ int main(int argc, char **argv)
pthread_mutex_lock(mutex + i);
pthread_attr_setstack(&stack_attr, &stacks[i], sizeof(struct stack));
- pthread_create(&cthread, &stack_attr, thread, (void*)i);
+ pthread_create(&cthread, &stack_attr, thread, (void*)(uintptr_t)i);
}
pthread_mutex_unlock(mutex + 0);
diff --git a/gcc/testsuite/go.test/test/bench/shootout/timing.log b/gcc/testsuite/go.test/test/bench/shootout/timing.log
index 2541a766b..ee1f889b4 100644
--- a/gcc/testsuite/go.test/test/bench/shootout/timing.log
+++ b/gcc/testsuite/go.test/test/bench/shootout/timing.log
@@ -900,3 +900,264 @@ threadring 50000000
chameneos 6000000
gc chameneosredux 7.41u 0.00s 7.42r # -3%
+
+# A complete run at the Go 1 release.
+# Significant changes:
+# - gccgo is now enabled for all tests (goroutines are cheap enough)
+# - threadring and chameneos are 14% faster, probably due to runtime changes
+# - regex-dna 36% faster
+# - fannkuch-parallel (only) slowed down 40%
+# - gccgo on binary-tree-freelist is still optimized to nothing
+# Other changes are modest.
+
+fasta -n 25000000
+ gcc -O2 fasta.c 1.45u 0.02s 1.48r
+ gccgo -O2 fasta.go 1.46u 0.00s 1.47r
+ gc fasta 1.99u 0.01s 2.00r
+ gc_B fasta 1.99u 0.01s 2.01r
+
+reverse-complement < output-of-fasta-25000000
+ gcc -O2 reverse-complement.c 0.95u 0.48s 4.99r
+ gccgo -O2 reverse-complement.go 0.93u 0.16s 1.09r
+ gc reverse-complement 1.20u 0.19s 1.39r
+ gc_B reverse-complement 1.04u 0.16s 1.20r
+
+nbody -n 50000000
+ gcc -O2 -lm nbody.c 13.02u 0.00s 13.05r
+ gccgo -O2 nbody.go 14.46u 0.00s 14.49r
+ gc nbody 21.79u 0.00s 21.84r
+ gc_B nbody 21.74u 0.00s 21.79r
+
+binary-tree 15 # too slow to use 20
+ gcc -O2 binary-tree.c -lm 0.60u 0.01s 0.61r
+ gccgo -O2 binary-tree.go 1.30u 0.01s 1.32r
+ gccgo -O2 binary-tree-freelist.go 0.00u 0.00s 0.00r
+ gc binary-tree 1.84u 0.01s 1.86r
+ gc binary-tree-freelist 0.33u 0.00s 0.33r
+
+fannkuch 12
+ gcc -O2 fannkuch.c 45.24u 0.00s 45.34r
+ gccgo -O2 fannkuch.go 59.76u 0.01s 59.90r
+ gccgo -O2 fannkuch-parallel.go 218.20u 0.01s 61.60r
+ gc fannkuch 103.92u 0.00s 104.16r
+ gc fannkuch-parallel 221.61u 0.00s 60.49r
+ gc_B fannkuch 53.17u 0.00s 53.30r
+
+regex-dna 100000
+ gcc -O2 regex-dna.c -lpcre 0.47u 0.00s 0.48r
+ gccgo -O2 regex-dna.go 6.52u 0.00s 6.54r
+ gccgo -O2 regex-dna-parallel.go 14.40u 0.73s 4.35r
+ gc regex-dna 2.63u 0.02s 2.66r # -36%
+ gc regex-dna-parallel 2.87u 0.01s 1.11r
+ gc_B regex-dna 2.65u 0.00s 2.66r
+
+spectral-norm 5500
+ gcc -O2 spectral-norm.c -lm 15.78u 0.00s 15.82r
+ gccgo -O2 spectral-norm.go 15.79u 0.00s 15.83r
+ gc spectral-norm 19.76u 0.00s 19.80r
+ gc_B spectral-norm 19.73u 0.01s 19.78r
+
+k-nucleotide 1000000
+ gcc -O2 k-nucleotide.c 5.59u 0.03s 5.63r
+ gccgo -O2 k-nucleotide.go 4.09u 0.03s 4.13r
+ gccgo -O2 k-nucleotide-parallel.go 4.50u 0.06s 1.63r
+ gc k-nucleotide 9.23u 0.02s 9.27r
+ gc k-nucleotide-parallel 9.87u 0.03s 3.55r
+ gc_B k-nucleotide 9.20u 0.00s 9.22r
+
+mandelbrot 16000
+ gcc -O2 mandelbrot.c 36.09u 0.00s 36.18r
+ gccgo -O2 mandelbrot.go 41.69u 0.01s 41.80r
+ gc mandelbrot 60.91u 0.02s 61.07r
+ gc_B mandelbrot 60.90u 0.00s 61.04r
+
+meteor 2098
+ gcc -O2 meteor-contest.c 0.09u 0.00s 0.09r
+ gccgo -O2 meteor-contest.go 0.09u 0.00s 0.09r
+ gc meteor-contest 0.14u 0.00s 0.15r
+ gc_B meteor-contest 0.14u 0.00s 0.14r
+
+pidigits 10000
+ gcc -O2 pidigits.c -lgmp 2.27u 0.00s 2.27r
+ gccgo -O2 pidigits.go 8.65u 0.00s 8.67r
+ gc pidigits 3.70u 0.04s 3.75r
+ gc_B pidigits 3.72u 0.02s 3.75r
+
+threadring 50000000
+ gcc -O2 threadring.c 40.91u 369.85s 323.31r
+ gccgo -O2 threadring.go 26.97u 30.82s 57.93r
+ gc threadring 12.81u 0.01s 12.85r # -13%
+
+chameneos 6000000
+ gcc -O2 chameneosredux.c -lpthread 9.44u 72.90s 12.65r
+ gccgo -O2 chameneosredux.go 7.73u 7.53s 15.30r
+ gc chameneosredux 6.51u 0.00s 6.53r # - 14%
+
+# After http://codereview.appspot.com/6248049, moving panicindex
+# calls out of line (putting the likely code into a single path and shortening
+# loops). Significant changes since the last run (note: some are slower for
+# unrelated and as yet undiagnosed reasons):
+
+nbody -n 50000000
+ gc nbody 19.10u 0.01s 19.19r # -12%
+ gc_B nbody 19.19u 0.00s 19.23r # -12%
+
+binary-tree 15 # too slow to use 20
+ gc binary-tree 1.49u 0.01s 1.51r # -19%
+
+fannkuch 12
+ gc fannkuch 60.79u 0.00s 60.92r # -41%
+ gc fannkuch-parallel 183.51u 0.01s 51.75r # -14%
+ gc_B fannkuch 51.68u 0.00s 51.79r # -3%
+
+k-nucleotide 1000000
+ gc k-nucleotide 9.74u 0.04s 9.80r # +6%
+ gc k-nucleotide-parallel 9.89u 0.05s 3.59r # +1%
+ gc_B k-nucleotide 9.39u 0.02s 9.43r # +2%
+
+mandelbrot (much slower, due to unrelated http://codereview.appspot.com/6209077)
+ gc mandelbrot 100.98u 0.00s 101.20r # +65%
+ gc_B mandelbrot 100.90u 0.01s 101.17r # +65%
+
+meteor 2098
+ gc meteor-contest 0.13u 0.00s 0.13r # -13%
+ gc_B meteor-contest 0.13u 0.00s 0.13r # -7%
+
+# May 30, 2012.
+# After http://codereview.appspot.com/6261051, restoring old code generated
+# for floating-point constants. Mandelbrot is back to its previous numbers.
+
+mandelbrot 16000
+ gcc -O2 mandelbrot.c 36.07u 0.00s 36.16r
+ gccgo -O2 mandelbrot.go 41.72u 0.01s 41.90r
+ gc mandelbrot 60.62u 0.00s 60.76r
+ gc_B mandelbrot 60.68u 0.00s 60.82r
+
+# May 30, 2012.
+# After http://codereview.appspot.com/6248068, better FP code
+# by avoiding MOVSD between registers.
+# Plus some other timing changes that have crept in from other speedups,
+# from garbage collection to Printf.
+
+fasta -n 25000000
+ gc fasta 1.76u 0.00s 1.76r # -12%
+ gc_B fasta 1.71u 0.00s 1.72r # -12%
+
+nbody -n 50000000
+ gc nbody 17.56u 0.00s 17.60r # -8%
+ gc_B nbody 17.30u 0.00s 17.34r # -10%
+
+fannkuch 12
+ gc fannkuch-parallel 155.92u 0.01s 44.05r # -15%
+
+k-nucleotide 1000000
+ gc k-nucleotide 9.22u 0.01s 9.26r # -5%
+ gc k-nucleotide-parallel 9.23u 0.03s 3.26r # -9%
+ gc_B k-nucleotide 9.22u 0.03s 9.28r # -2%
+
+mandelbrot 16000
+ gc mandelbrot 44.80u 0.00s 44.90r # -27%
+ gc_B mandelbrot 44.81u 0.00s 44.92r # -26%
+
+pidigits 10000
+ gc pidigits 3.51u 0.00s 3.52r # -6%
+ gc_B pidigits 3.51u 0.00s 3.52r # -6%
+
+# Aug 28, 2012
+# After some assembler work in package big.
+pidigits 10000
+ gc pidigits 2.85u 0.02s 2.88r # -22%
+ gc_B pidigits 2.88u 0.01s 2.90r # -21%
+
+# Sep 26, 2012
+# 64-bit ints, plus significantly better floating-point code.
+# Interesting details:
+# Generally something in the 0-10% slower range, some (binary tree) more
+# Floating-point noticeably faster:
+# nbody -25%
+# mandelbrot -37% relative to Go 1.
+# Other:
+# regex-dna +47%
+fasta -n 25000000
+ gcc -O2 fasta.c 1.43u 0.03s 1.46r
+ gccgo -O2 fasta.go 1.47u 0.00s 1.47r
+ gc fasta 1.78u 0.01s 1.80r
+ gc_B fasta 1.76u 0.00s 1.76r
+
+reverse-complement < output-of-fasta-25000000
+ gcc -O2 reverse-complement.c 1.14u 0.39s 11.19r
+ gccgo -O2 reverse-complement.go 0.91u 0.17s 1.09r
+ gc reverse-complement 1.12u 0.18s 1.31r
+ gc_B reverse-complement 1.12u 0.15s 1.28r
+
+nbody -n 50000000
+ gcc -O2 nbody.c -lm 13.02u 0.00s 13.05r
+ gccgo -O2 nbody.go 13.90u 0.00s 13.93r
+ gc nbody 17.05u 0.00s 17.09r
+ gc_B nbody 16.30u 0.00s 16.34r
+
+binary-tree 15 # too slow to use 20
+ gcc -O2 binary-tree.c -lm 0.61u 0.00s 0.61r
+ gccgo -O2 binary-tree.go 1.24u 0.04s 1.29r
+ gccgo -O2 binary-tree-freelist.go 0.21u 0.01s 0.22r
+ gc binary-tree 1.93u 0.02s 1.96r
+ gc binary-tree-freelist 0.32u 0.00s 0.33r
+
+fannkuch 12
+ gcc -O2 fannkuch.c 45.19u 0.00s 45.29r
+ gccgo -O2 fannkuch.go 60.32u 0.00s 60.45r
+ gccgo -O2 fannkuch-parallel.go 185.59u 0.00s 59.49r
+ gc fannkuch 72.14u 0.00s 72.30r
+ gc fannkuch-parallel 172.54u 0.00s 43.59r
+ gc_B fannkuch 53.55u 0.00s 53.67r
+
+regex-dna 100000
+ gcc -O2 regex-dna.c -lpcre 0.47u 0.00s 0.47r
+ gccgo -O2 regex-dna.go 6.49u 0.05s 6.56r
+ gccgo -O2 regex-dna-parallel.go 14.60u 0.67s 4.42r
+ gc regex-dna 3.91u 0.00s 3.92r
+ gc regex-dna-parallel 4.01u 0.03s 1.56r
+ gc_B regex-dna 3.91u 0.00s 3.92r
+
+spectral-norm 5500
+ gcc -O2 spectral-norm.c -lm 15.85u 0.00s 15.89r
+ gccgo -O2 spectral-norm.go 15.86u 0.00s 15.89r
+ gc spectral-norm 19.72u 0.00s 19.76r
+ gc_B spectral-norm 19.68u 0.01s 19.74r
+
+k-nucleotide 1000000
+ gcc -O2 k-nucleotide.c -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -lglib-2.0 4.90u 0.01s 4.93r
+ gccgo -O2 k-nucleotide.go 4.78u 0.01s 4.80r
+ gccgo -O2 k-nucleotide-parallel.go 6.49u 0.02s 2.18r
+ gc k-nucleotide 9.05u 0.02s 9.09r
+ gc k-nucleotide-parallel 9.27u 0.01s 3.29r
+ gc_B k-nucleotide 8.95u 0.03s 9.00r
+
+mandelbrot 16000
+ gcc -O2 mandelbrot.c 36.11u 0.00s 36.19r
+ gccgo -O2 mandelbrot.go 43.67u 0.00s 43.77r
+ gc mandelbrot 38.57u 0.00s 38.66r
+ gc_B mandelbrot 38.59u 0.00s 38.68r
+
+meteor 2098
+ gcc -O2 meteor-contest.c 0.09u 0.00s 0.09r
+ gccgo -O2 meteor-contest.go 0.09u 0.00s 0.09r
+ gc meteor-contest 0.13u 0.00s 0.14r
+ gc_B meteor-contest 0.12u 0.00s 0.13r
+
+pidigits 10000
+ gcc -O2 pidigits.c -lgmp 2.26u 0.00s 2.27r
+ gccgo -O2 pidigits.go 9.05u 0.00s 9.07r
+ gc pidigits 2.88u 0.02s 2.90r
+ gc_B pidigits 2.89u 0.00s 2.90r
+
+threadring 50000000
+ gcc -O2 threadring.c -lpthread 37.30u 327.81s 289.28r
+ gccgo -O2 threadring.go 42.83u 26.15s 69.14r
+ gc threadring 13.00u 0.00s 13.03r
+
+chameneos 6000000
+ gcc -O2 chameneosredux.c -lpthread 8.80u 71.67s 12.19r
+ gccgo -O2 chameneosredux.go 11.28u 6.68s 18.00r
+ gc chameneosredux 6.94u 0.00s 6.96r
+
diff --git a/gcc/testsuite/go.test/test/bench/shootout/timing.sh b/gcc/testsuite/go.test/test/bench/shootout/timing.sh
index 3e190e15c..d269b8756 100755
--- a/gcc/testsuite/go.test/test/bench/shootout/timing.sh
+++ b/gcc/testsuite/go.test/test/bench/shootout/timing.sh
@@ -5,7 +5,11 @@
set -e
-eval $(gomake --no-print-directory -f ../../../src/Make.inc go-env)
+eval $(go tool dist env)
+O=$GOCHAR
+GC="go tool ${O}g"
+LD="go tool ${O}l"
+
PATH=.:$PATH
havegccgo=false
@@ -93,7 +97,7 @@ revcomp() {
nbody() {
runonly echo 'nbody -n 50000000'
- run 'gcc -O2 -lm nbody.c' a.out 50000000
+ run 'gcc -O2 nbody.c -lm' a.out 50000000
run 'gccgo -O2 nbody.go' a.out -n 50000000
run 'gc nbody' $O.out -n 50000000
run 'gc_B nbody' $O.out -n 50000000
@@ -103,7 +107,7 @@ binarytree() {
runonly echo 'binary-tree 15 # too slow to use 20'
run 'gcc -O2 binary-tree.c -lm' a.out 15
run 'gccgo -O2 binary-tree.go' a.out -n 15
- run 'gccgo -O2 binary-tree-freelist.go' $O.out -n 15
+ run 'gccgo -O2 binary-tree-freelist.go' a.out -n 15
run 'gc binary-tree' $O.out -n 15
run 'gc binary-tree-freelist' $O.out -n 15
}
@@ -143,7 +147,9 @@ knucleotide() {
runonly gcc -O2 fasta.c
runonly a.out 1000000 > x # should be using 25000000
runonly echo 'k-nucleotide 1000000'
- run 'gcc -O2 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include k-nucleotide.c -lglib-2.0' a.out <x
+ if [ $mode = run ]; then
+ run "gcc -O2 k-nucleotide.c $(pkg-config glib-2.0 --cflags --libs)" a.out <x
+ fi
run 'gccgo -O2 k-nucleotide.go' a.out <x
run 'gccgo -O2 k-nucleotide-parallel.go' a.out <x
run 'gc k-nucleotide' $O.out <x
diff --git a/gcc/testsuite/go.test/test/bigalg.go b/gcc/testsuite/go.test/test/bigalg.go
index 902ba8410..55a15c30a 100644
--- a/gcc/testsuite/go.test/test/bigalg.go
+++ b/gcc/testsuite/go.test/test/bigalg.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test the internal "algorithms" for objects larger than a word: hashing, equality etc.
+
package main
type T struct {
diff --git a/gcc/testsuite/go.test/test/bigmap.go b/gcc/testsuite/go.test/test/bigmap.go
index 843a15174..c5e4f91e1 100644
--- a/gcc/testsuite/go.test/test/bigmap.go
+++ b/gcc/testsuite/go.test/test/bigmap.go
@@ -1,9 +1,13 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Internally a map holds elements in up to 255 bytes of key+value.
+// When key or value or both are too large, it uses pointers to key+value
+// instead. Test all the combinations.
+
package main
func seq(x, y int) [1000]byte {
@@ -31,4 +35,105 @@ func main() {
cmp(m[1], seq(11, 13))
cmp(m[2], seq(2, 9))
cmp(m[3], seq(3, 17))
+
+
+ {
+ type T [1]byte
+ type V [1]byte
+ m := make(map[T]V)
+ m[T{}] = V{1}
+ m[T{1}] = V{2}
+ if x, y := m[T{}][0], m[T{1}][0]; x != 1 || y != 2 {
+ println(x, y)
+ panic("bad map")
+ }
+ }
+ {
+ type T [100]byte
+ type V [1]byte
+ m := make(map[T]V)
+ m[T{}] = V{1}
+ m[T{1}] = V{2}
+ if x, y := m[T{}][0], m[T{1}][0]; x != 1 || y != 2 {
+ println(x, y)
+ panic("bad map")
+ }
+ }
+ {
+ type T [1]byte
+ type V [100]byte
+ m := make(map[T]V)
+ m[T{}] = V{1}
+ m[T{1}] = V{2}
+ if x, y := m[T{}][0], m[T{1}][0]; x != 1 || y != 2 {
+ println(x, y)
+ panic("bad map")
+ }
+ }
+ {
+ type T [1000]byte
+ type V [1]byte
+ m := make(map[T]V)
+ m[T{}] = V{1}
+ m[T{1}] = V{2}
+ if x, y := m[T{}][0], m[T{1}][0]; x != 1 || y != 2 {
+ println(x, y)
+ panic("bad map")
+ }
+ }
+ {
+ type T [1]byte
+ type V [1000]byte
+ m := make(map[T]V)
+ m[T{}] = V{1}
+ m[T{1}] = V{2}
+ if x, y := m[T{}][0], m[T{1}][0]; x != 1 || y != 2 {
+ println(x, y)
+ panic("bad map")
+ }
+ }
+ {
+ type T [1000]byte
+ type V [1000]byte
+ m := make(map[T]V)
+ m[T{}] = V{1}
+ m[T{1}] = V{2}
+ if x, y := m[T{}][0], m[T{1}][0]; x != 1 || y != 2 {
+ println(x, y)
+ panic("bad map")
+ }
+ }
+ {
+ type T [200]byte
+ type V [1]byte
+ m := make(map[T]V)
+ m[T{}] = V{1}
+ m[T{1}] = V{2}
+ if x, y := m[T{}][0], m[T{1}][0]; x != 1 || y != 2 {
+ println(x, y)
+ panic("bad map")
+ }
+ }
+ {
+ type T [1]byte
+ type V [200]byte
+ m := make(map[T]V)
+ m[T{}] = V{1}
+ m[T{1}] = V{2}
+ if x, y := m[T{}][0], m[T{1}][0]; x != 1 || y != 2 {
+ println(x, y)
+ panic("bad map")
+ }
+ }
+ {
+ type T [200]byte
+ type V [200]byte
+ m := make(map[T]V)
+ m[T{}] = V{1}
+ m[T{1}] = V{2}
+ if x, y := m[T{}][0], m[T{1}][0]; x != 1 || y != 2 {
+ println(x, y)
+ panic("bad map")
+ }
+ }
}
diff --git a/gcc/testsuite/go.test/test/blank.go b/gcc/testsuite/go.test/test/blank.go
index d6c9e79c6..ee618b148 100644
--- a/gcc/testsuite/go.test/test/blank.go
+++ b/gcc/testsuite/go.test/test/blank.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test behavior of the blank identifier (_).
+
package main
import _ "fmt"
@@ -111,7 +113,7 @@ type I interface {
type TI struct{}
-func (TI) M(x int, y int) {
+func (_ TI) M(x int, y int) {
if x != y {
println("invalid M call:", x, y)
panic("bad M")
diff --git a/gcc/testsuite/go.test/test/blank1.go b/gcc/testsuite/go.test/test/blank1.go
index bcc78466d..c6e038a0d 100644
--- a/gcc/testsuite/go.test/test/blank1.go
+++ b/gcc/testsuite/go.test/test/blank1.go
@@ -1,9 +1,12 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test that incorrect uses of the blank identifer are caught.
+// Does not compile.
+
package _ // ERROR "invalid package name _"
func main() {
diff --git a/gcc/testsuite/go.test/test/bom.go b/gcc/testsuite/go.test/test/bom.go
new file mode 100644
index 000000000..37f73bc5d
--- /dev/null
+++ b/gcc/testsuite/go.test/test/bom.go
@@ -0,0 +1,26 @@
+// runoutput
+
+// Copyright 2011 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Test source file beginning with a byte order mark.
+
+package main
+
+import (
+ "fmt"
+ "strings"
+)
+
+func main() {
+ prog = strings.Replace(prog, "BOM", "\uFEFF", -1)
+ fmt.Print(prog)
+}
+
+var prog = `BOM
+package main
+
+func main() {
+}
+`
diff --git a/gcc/testsuite/go.test/test/bombad.go b/gcc/testsuite/go.test/test/bombad.go
new file mode 100644
index 000000000..b894d9ba9
--- /dev/null
+++ b/gcc/testsuite/go.test/test/bombad.go
@@ -0,0 +1,18 @@
+// errorcheck
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Here for reference, but hard to test automatically
+// because the BOM muddles the
+// processing done by ../run.
+
+package main
+
+func main() {
+ // There's a bom here. // ERROR "BOM"
+ // And here. // ERROR "BOM"
+ /* And here.*/ // ERROR "BOM"
+ println("hi there") // and here // ERROR "BOM"
+}
diff --git a/gcc/testsuite/go.test/test/bounds.go b/gcc/testsuite/go.test/test/bounds.go
new file mode 100644
index 000000000..50f7ad741
--- /dev/null
+++ b/gcc/testsuite/go.test/test/bounds.go
@@ -0,0 +1,270 @@
+// errorcheck -0 -m -l
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Test, using compiler diagnostic flags, that bounds check elimination
+// is eliminating the correct checks.
+
+package foo
+
+var (
+ s []int
+
+ a1 [1]int
+ a1k [1000]int
+ a100k [100000]int
+
+ p1 *[1]int
+ p1k *[1000]int
+ p100k *[100000]int
+
+ i int
+ ui uint
+ i8 int8
+ ui8 uint8
+ i16 int16
+ ui16 uint16
+ i32 int32
+ ui32 uint32
+ i64 int64
+ ui64 uint64
+)
+
+func main() {
+ // Most things need checks.
+ use(s[i])
+ use(a1[i])
+ use(a1k[i])
+ use(a100k[i])
+ use(p1[i])
+ use(p1k[i])
+ use(p100k[i])
+
+ use(s[ui])
+ use(a1[ui])
+ use(a1k[ui])
+ use(a100k[ui])
+ use(p1[ui])
+ use(p1k[ui])
+ use(p100k[ui])
+
+ use(s[i8])
+ use(a1[i8])
+ use(a1k[i8])
+ use(a100k[i8])
+ use(p1[i8])
+ use(p1k[i8])
+ use(p100k[i8])
+
+ // Unsigned 8-bit numbers don't need checks for len >= 2⁸.
+ use(s[ui8])
+ use(a1[ui8])
+ use(a1k[ui8]) // ERROR "index bounds check elided"
+ use(a100k[ui8]) // ERROR "index bounds check elided"
+ use(p1[ui8])
+ use(p1k[ui8]) // ERROR "index bounds check elided"
+ use(p100k[ui8]) // ERROR "index bounds check elided"
+
+ use(s[i16])
+ use(a1[i16])
+ use(a1k[i16])
+ use(a100k[i16])
+ use(p1[i16])
+ use(p1k[i16])
+ use(p100k[i16])
+
+ // Unsigned 16-bit numbers don't need checks for len >= 2¹⁶.
+ use(s[ui16])
+ use(a1[ui16])
+ use(a1k[ui16])
+ use(a100k[ui16]) // ERROR "index bounds check elided"
+ use(p1[ui16])
+ use(p1k[ui16])
+ use(p100k[ui16]) // ERROR "index bounds check elided"
+
+ use(s[i32])
+ use(a1[i32])
+ use(a1k[i32])
+ use(a100k[i32])
+ use(p1[i32])
+ use(p1k[i32])
+ use(p100k[i32])
+
+ use(s[ui32])
+ use(a1[ui32])
+ use(a1k[ui32])
+ use(a100k[ui32])
+ use(p1[ui32])
+ use(p1k[ui32])
+ use(p100k[ui32])
+
+ use(s[i64])
+ use(a1[i64])
+ use(a1k[i64])
+ use(a100k[i64])
+ use(p1[i64])
+ use(p1k[i64])
+ use(p100k[i64])
+
+ use(s[ui64])
+ use(a1[ui64])
+ use(a1k[ui64])
+ use(a100k[ui64])
+ use(p1[ui64])
+ use(p1k[ui64])
+ use(p100k[ui64])
+
+ // Mod truncates the maximum value to one less than the argument,
+ // but signed mod can be negative, so only unsigned mod counts.
+ use(s[i%999])
+ use(a1[i%999])
+ use(a1k[i%999])
+ use(a100k[i%999])
+ use(p1[i%999])
+ use(p1k[i%999])
+ use(p100k[i%999])
+
+ use(s[ui%999])
+ use(a1[ui%999])
+ use(a1k[ui%999]) // ERROR "index bounds check elided"
+ use(a100k[ui%999]) // ERROR "index bounds check elided"
+ use(p1[ui%999])
+ use(p1k[ui%999]) // ERROR "index bounds check elided"
+ use(p100k[ui%999]) // ERROR "index bounds check elided"
+
+ use(s[i%1000])
+ use(a1[i%1000])
+ use(a1k[i%1000])
+ use(a100k[i%1000])
+ use(p1[i%1000])
+ use(p1k[i%1000])
+ use(p100k[i%1000])
+
+ use(s[ui%1000])
+ use(a1[ui%1000])
+ use(a1k[ui%1000]) // ERROR "index bounds check elided"
+ use(a100k[ui%1000]) // ERROR "index bounds check elided"
+ use(p1[ui%1000])
+ use(p1k[ui%1000]) // ERROR "index bounds check elided"
+ use(p100k[ui%1000]) // ERROR "index bounds check elided"
+
+ use(s[i%1001])
+ use(a1[i%1001])
+ use(a1k[i%1001])
+ use(a100k[i%1001])
+ use(p1[i%1001])
+ use(p1k[i%1001])
+ use(p100k[i%1001])
+
+ use(s[ui%1001])
+ use(a1[ui%1001])
+ use(a1k[ui%1001])
+ use(a100k[ui%1001]) // ERROR "index bounds check elided"
+ use(p1[ui%1001])
+ use(p1k[ui%1001])
+ use(p100k[ui%1001]) // ERROR "index bounds check elided"
+
+ // Bitwise and truncates the maximum value to the mask value.
+ // The result (for a positive mask) cannot be negative, so elision
+ // applies to both signed and unsigned indexes.
+ use(s[i&999])
+ use(a1[i&999])
+ use(a1k[i&999]) // ERROR "index bounds check elided"
+ use(a100k[i&999]) // ERROR "index bounds check elided"
+ use(p1[i&999])
+ use(p1k[i&999]) // ERROR "index bounds check elided"
+ use(p100k[i&999]) // ERROR "index bounds check elided"
+
+ use(s[ui&999])
+ use(a1[ui&999])
+ use(a1k[ui&999]) // ERROR "index bounds check elided"
+ use(a100k[ui&999]) // ERROR "index bounds check elided"
+ use(p1[ui&999])
+ use(p1k[ui&999]) // ERROR "index bounds check elided"
+ use(p100k[ui&999]) // ERROR "index bounds check elided"
+
+ use(s[i&1000])
+ use(a1[i&1000])
+ use(a1k[i&1000])
+ use(a100k[i&1000]) // ERROR "index bounds check elided"
+ use(p1[i&1000])
+ use(p1k[i&1000])
+ use(p100k[i&1000]) // ERROR "index bounds check elided"
+
+ use(s[ui&1000])
+ use(a1[ui&1000])
+ use(a1k[ui&1000])
+ use(a100k[ui&1000]) // ERROR "index bounds check elided"
+ use(p1[ui&1000])
+ use(p1k[ui&1000])
+ use(p100k[ui&1000]) // ERROR "index bounds check elided"
+
+ // Right shift cuts the effective number of bits in the index,
+ // but only for unsigned (signed stays negative).
+ use(s[i32>>22])
+ use(a1[i32>>22])
+ use(a1k[i32>>22])
+ use(a100k[i32>>22])
+ use(p1[i32>>22])
+ use(p1k[i32>>22])
+ use(p100k[i32>>22])
+
+ use(s[ui32>>22])
+ use(a1[ui32>>22])
+ use(a1k[ui32>>22])
+ use(a100k[ui32>>22]) // ERROR "index bounds check elided"
+ use(p1[ui32>>22])
+ use(p1k[ui32>>22])
+ use(p100k[ui32>>22]) // ERROR "index bounds check elided"
+
+ use(s[i32>>23])
+ use(a1[i32>>23])
+ use(a1k[i32>>23])
+ use(a100k[i32>>23])
+ use(p1[i32>>23])
+ use(p1k[i32>>23])
+ use(p100k[i32>>23])
+
+ use(s[ui32>>23])
+ use(a1[ui32>>23])
+ use(a1k[ui32>>23]) // ERROR "index bounds check elided"
+ use(a100k[ui32>>23]) // ERROR "index bounds check elided"
+ use(p1[ui32>>23])
+ use(p1k[ui32>>23]) // ERROR "index bounds check elided"
+ use(p100k[ui32>>23]) // ERROR "index bounds check elided"
+
+ // Division cuts the range like right shift does.
+ use(s[i/1e6])
+ use(a1[i/1e6])
+ use(a1k[i/1e6])
+ use(a100k[i/1e6])
+ use(p1[i/1e6])
+ use(p1k[i/1e6])
+ use(p100k[i/1e6])
+
+ use(s[ui/1e6])
+ use(a1[ui/1e6])
+ use(a1k[ui/1e6])
+ use(p1[ui/1e6])
+ use(p1k[ui/1e6])
+
+ use(s[i/1e7])
+ use(a1[i/1e7])
+ use(a1k[i/1e7])
+ use(a100k[i/1e7])
+ use(p1[i/1e7])
+ use(p1k[i/1e7])
+ use(p100k[i/1e7])
+
+ use(s[ui/1e7])
+ use(a1[ui/1e7])
+ use(p1[ui/1e7])
+}
+
+var sum int
+
+func use(x int) {
+ sum += x
+}
diff --git a/gcc/testsuite/go.test/test/bugs/bug395.go b/gcc/testsuite/go.test/test/bugs/bug395.go
index adf74497c..4632dcd0f 100644
--- a/gcc/testsuite/go.test/test/bugs/bug395.go
+++ b/gcc/testsuite/go.test/test/bugs/bug395.go
@@ -1,6 +1,9 @@
// echo bug395 is broken # takes 90+ seconds to break
// # $G $D/$F.go || echo bug395
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
diff --git a/gcc/testsuite/go.test/test/bugs/bug434.dir/one.go b/gcc/testsuite/go.test/test/bugs/bug434.dir/one.go
new file mode 100644
index 000000000..491ada1d9
--- /dev/null
+++ b/gcc/testsuite/go.test/test/bugs/bug434.dir/one.go
@@ -0,0 +1,28 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package one
+
+// Issue 3552
+
+type T struct { int }
+
+func (t T) F() int { return t.int }
+
+type U struct { int int }
+
+func (u U) F() int { return u.int }
+
+type lint int
+
+type V struct { lint }
+
+func (v V) F() int { return int(v.lint) }
+
+type W struct { lint lint }
+
+func (w W) F() int { return int(w.lint) }
+
+
+
diff --git a/gcc/testsuite/go.test/test/bugs/bug434.dir/two.go b/gcc/testsuite/go.test/test/bugs/bug434.dir/two.go
new file mode 100644
index 000000000..1366d244d
--- /dev/null
+++ b/gcc/testsuite/go.test/test/bugs/bug434.dir/two.go
@@ -0,0 +1,22 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Use the functions in one.go so that the inlined
+// forms get type-checked.
+
+package two
+
+import "./one"
+
+func use() {
+ var t one.T
+ var u one.U
+ var v one.V
+ var w one.W
+
+ _ = t.F()
+ _ = u.F()
+ _ = v.F()
+ _ = w.F()
+}
diff --git a/gcc/testsuite/go.test/test/bugs/bug434.go b/gcc/testsuite/go.test/test/bugs/bug434.go
new file mode 100644
index 000000000..5eec7a577
--- /dev/null
+++ b/gcc/testsuite/go.test/test/bugs/bug434.go
@@ -0,0 +1,10 @@
+// $G $D/$F.dir/one.go && $G $D/$F.dir/two.go || echo BUG:bug434
+
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
+// Copyright 2011 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package ignored
diff --git a/gcc/testsuite/go.test/test/chan/doubleselect.go b/gcc/testsuite/go.test/test/chan/doubleselect.go
index f8d50c90c..ac559302d 100644
--- a/gcc/testsuite/go.test/test/chan/doubleselect.go
+++ b/gcc/testsuite/go.test/test/chan/doubleselect.go
@@ -1,11 +1,12 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// This test is designed to flush out the case where two cases of a select can
+// Test the situation in which two cases of a select can
// both end up running. See http://codereview.appspot.com/180068.
+
package main
import (
diff --git a/gcc/testsuite/go.test/test/chan/fifo.go b/gcc/testsuite/go.test/test/chan/fifo.go
index 0dddfcaa0..70d20b31f 100644
--- a/gcc/testsuite/go.test/test/chan/fifo.go
+++ b/gcc/testsuite/go.test/test/chan/fifo.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Verify that unbuffered channels act as pure fifos.
+// Test that unbuffered channels act as pure fifos.
package main
diff --git a/gcc/testsuite/go.test/test/chan/goroutines.go b/gcc/testsuite/go.test/test/chan/goroutines.go
index 371a17387..6ffae7df6 100644
--- a/gcc/testsuite/go.test/test/chan/goroutines.go
+++ b/gcc/testsuite/go.test/test/chan/goroutines.go
@@ -1,11 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// make a lot of goroutines, threaded together.
-// tear them down cleanly.
+// Torture test for goroutines.
+// Make a lot of goroutines, threaded together, and tear them down cleanly.
package main
diff --git a/gcc/testsuite/go.test/test/chan/nonblock.go b/gcc/testsuite/go.test/test/chan/nonblock.go
index 9addf12e9..7e3c0c74d 100644
--- a/gcc/testsuite/go.test/test/chan/nonblock.go
+++ b/gcc/testsuite/go.test/test/chan/nonblock.go
@@ -1,11 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Verify channel operations that test for blocking
-// Use several sizes and types of operands
+// Test channel operations that test for blocking.
+// Use several sizes and types of operands.
package main
diff --git a/gcc/testsuite/go.test/test/chan/perm.go b/gcc/testsuite/go.test/test/chan/perm.go
index a43df1982..7e152c5eb 100644
--- a/gcc/testsuite/go.test/test/chan/perm.go
+++ b/gcc/testsuite/go.test/test/chan/perm.go
@@ -1,9 +1,13 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test various correct and incorrect permutations of send-only,
+// receive-only, and bidirectional channels.
+// Does not compile.
+
package main
var (
diff --git a/gcc/testsuite/go.test/test/chan/powser1.go b/gcc/testsuite/go.test/test/chan/powser1.go
index dc4ff5325..6bf2a9111 100644
--- a/gcc/testsuite/go.test/test/chan/powser1.go
+++ b/gcc/testsuite/go.test/test/chan/powser1.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test concurrency primitives: power series.
+
// Power series package
// A power series is a channel, along which flow rational
// coefficients. A denominator of zero signifies the end.
diff --git a/gcc/testsuite/go.test/test/chan/powser2.go b/gcc/testsuite/go.test/test/chan/powser2.go
index bc329270d..33abd5c53 100644
--- a/gcc/testsuite/go.test/test/chan/powser2.go
+++ b/gcc/testsuite/go.test/test/chan/powser2.go
@@ -1,18 +1,21 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test concurrency primitives: power series.
+
+// Like powser1.go but uses channels of interfaces.
+// Has not been cleaned up as much as powser1.go, to keep
+// it distinct and therefore a different test.
+
// Power series package
// A power series is a channel, along which flow rational
// coefficients. A denominator of zero signifies the end.
// Original code in Newsqueak by Doug McIlroy.
// See Squinting at Power Series by Doug McIlroy,
// http://www.cs.bell-labs.com/who/rsc/thread/squint.pdf
-// Like powser1.go but uses channels of interfaces.
-// Has not been cleaned up as much as powser1.go, to keep
-// it distinct and therefore a different test.
package main
diff --git a/gcc/testsuite/go.test/test/chan/select.go b/gcc/testsuite/go.test/test/chan/select.go
index be4eb3f42..38fa7e1e3 100644
--- a/gcc/testsuite/go.test/test/chan/select.go
+++ b/gcc/testsuite/go.test/test/chan/select.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test simple select.
+
package main
var counter uint
diff --git a/gcc/testsuite/go.test/test/chan/select2.go b/gcc/testsuite/go.test/test/chan/select2.go
index 2cbb86ec6..40bc357b5 100644
--- a/gcc/testsuite/go.test/test/chan/select2.go
+++ b/gcc/testsuite/go.test/test/chan/select2.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test that selects do not consume undue memory.
+
package main
import "runtime"
diff --git a/gcc/testsuite/go.test/test/chan/select3.go b/gcc/testsuite/go.test/test/chan/select3.go
index d919de3e0..847d8ed37 100644
--- a/gcc/testsuite/go.test/test/chan/select3.go
+++ b/gcc/testsuite/go.test/test/chan/select3.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Tests verifying the semantics of the select statement
+// Test the semantics of the select statement
// for basic empty/non-empty cases.
package main
@@ -197,13 +197,13 @@ func main() {
})
testBlock(never, func() {
select {
- case x := <-closedch:
+ case x := (<-closedch):
_ = x
}
})
testBlock(never, func() {
select {
- case x, ok := <-closedch:
+ case x, ok := (<-closedch):
_, _ = x, ok
}
})
diff --git a/gcc/testsuite/go.test/test/chan/select4.go b/gcc/testsuite/go.test/test/chan/select4.go
index 46618ac88..500364038 100644
--- a/gcc/testsuite/go.test/test/chan/select4.go
+++ b/gcc/testsuite/go.test/test/chan/select4.go
@@ -1,4 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
+
+// Copyright 2010 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file
+
+// Test that a select statement proceeds when a value is ready.
package main
diff --git a/gcc/testsuite/go.test/test/chan/select5.go b/gcc/testsuite/go.test/test/chan/select5.go
index cc2cc7100..f72cfe4b4 100644
--- a/gcc/testsuite/go.test/test/chan/select5.go
+++ b/gcc/testsuite/go.test/test/chan/select5.go
@@ -1,13 +1,14 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out >tmp.go &&
-// $G tmp.go && $L tmp.$A && ./$A.out || echo BUG: select5
-// rm -f tmp.go
+// runoutput
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
// Generate test of channel operations and simple selects.
-// Only doing one real send or receive at a time, but phrased
+// The output of this program is compiled and run to do the
+// actual test.
+
+// Each test does only one real send or receive at a time, but phrased
// in various ways that the compiler may or may not rewrite
// into simpler expressions.
diff --git a/gcc/testsuite/go.test/test/chan/select6.go b/gcc/testsuite/go.test/test/chan/select6.go
index 2ba6810ac..af470a0d0 100644
--- a/gcc/testsuite/go.test/test/chan/select6.go
+++ b/gcc/testsuite/go.test/test/chan/select6.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Issue 2075
+// Test for select: Issue 2075
// A bug in select corrupts channel queues of failed cases
// if there are multiple waiters on those channels and the
// select is the last in the queue. If further waits are made
diff --git a/gcc/testsuite/go.test/test/chan/select7.go b/gcc/testsuite/go.test/test/chan/select7.go
index 5fed6cbd4..20456a9d6 100644
--- a/gcc/testsuite/go.test/test/chan/select7.go
+++ b/gcc/testsuite/go.test/test/chan/select7.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/chan/sendstmt.go b/gcc/testsuite/go.test/test/chan/sendstmt.go
index ee6f765cf..a92c4f63a 100644
--- a/gcc/testsuite/go.test/test/chan/sendstmt.go
+++ b/gcc/testsuite/go.test/test/chan/sendstmt.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/chan/sieve1.go b/gcc/testsuite/go.test/test/chan/sieve1.go
index 55076c925..acc310f6c 100644
--- a/gcc/testsuite/go.test/test/chan/sieve1.go
+++ b/gcc/testsuite/go.test/test/chan/sieve1.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test concurrency primitives: classical inefficient concurrent prime sieve.
+
// Generate primes up to 100 using channels, checking the results.
// This sieve consists of a linear chain of divisibility filters,
// equivalent to trial-dividing each n by all primes p ≤ n.
diff --git a/gcc/testsuite/go.test/test/chan/sieve2.go b/gcc/testsuite/go.test/test/chan/sieve2.go
index 9a7ab1540..09e5c527b 100644
--- a/gcc/testsuite/go.test/test/chan/sieve2.go
+++ b/gcc/testsuite/go.test/test/chan/sieve2.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test concurrency primitives: prime sieve of Eratosthenes.
+
// Generate primes up to 100 using channels, checking the results.
// This sieve is Eratosthenesque and only considers odd candidates.
// See discussion at <http://blog.onideas.ws/eratosthenes.go>.
diff --git a/gcc/testsuite/go.test/test/chan/zerosize.go b/gcc/testsuite/go.test/test/chan/zerosize.go
index 617c9dab3..50aca857c 100644
--- a/gcc/testsuite/go.test/test/chan/zerosize.go
+++ b/gcc/testsuite/go.test/test/chan/zerosize.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Making channels of a zero-sized type should not panic.
+// Test making channels of a zero-sized type.
package main
diff --git a/gcc/testsuite/go.test/test/chancap.go b/gcc/testsuite/go.test/test/chancap.go
index 3f3789fbc..b3e40233f 100644
--- a/gcc/testsuite/go.test/test/chancap.go
+++ b/gcc/testsuite/go.test/test/chancap.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test the cap predeclared function applied to channels.
+
package main
func main() {
diff --git a/gcc/testsuite/go.test/test/char_lit.go b/gcc/testsuite/go.test/test/char_lit.go
index 99be77a57..836c3c1a2 100644
--- a/gcc/testsuite/go.test/test/char_lit.go
+++ b/gcc/testsuite/go.test/test/char_lit.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A &&./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test character literal syntax.
+
package main
import "os"
diff --git a/gcc/testsuite/go.test/test/char_lit1.go b/gcc/testsuite/go.test/test/char_lit1.go
index dc5385291..489744b6e 100644
--- a/gcc/testsuite/go.test/test/char_lit1.go
+++ b/gcc/testsuite/go.test/test/char_lit1.go
@@ -1,9 +1,12 @@
-// errchk $G -e $F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that illegal character literals are detected.
+// Does not compile.
+
package main
const (
diff --git a/gcc/testsuite/go.test/test/closedchan.go b/gcc/testsuite/go.test/test/closedchan.go
index c2bbec59d..043a92d38 100644
--- a/gcc/testsuite/go.test/test/closedchan.go
+++ b/gcc/testsuite/go.test/test/closedchan.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/closure.go b/gcc/testsuite/go.test/test/closure.go
index 97da1dd23..c4a312464 100644
--- a/gcc/testsuite/go.test/test/closure.go
+++ b/gcc/testsuite/go.test/test/closure.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test the behavior of closures.
+
package main
import "runtime"
@@ -79,6 +81,7 @@ func h() {
func newfunc() func(int) int { return func(x int) int { return x } }
func main() {
+ runtime.GOMAXPROCS(1)
var fail bool
go f()
@@ -92,8 +95,9 @@ func main() {
go h()
check([]int{100, 200, 101, 201, 500, 101, 201, 500})
- runtime.UpdateMemStats()
- n0 := runtime.MemStats.Mallocs
+ memstats := new(runtime.MemStats)
+ runtime.ReadMemStats(memstats)
+ n0 := memstats.Mallocs
x, y := newfunc(), newfunc()
if x(1) != 1 || y(2) != 2 {
@@ -101,8 +105,8 @@ func main() {
fail = true
}
- runtime.UpdateMemStats()
- if n0 != runtime.MemStats.Mallocs {
+ runtime.ReadMemStats(memstats)
+ if n0 != memstats.Mallocs {
println("newfunc allocated unexpectedly")
fail = true
}
@@ -110,7 +114,7 @@ func main() {
ff(1)
if fail {
- panic("fail")
+ panic("fail")
}
}
diff --git a/gcc/testsuite/go.test/test/cmp.go b/gcc/testsuite/go.test/test/cmp.go
index d51a11aa2..a56ca6ead 100644
--- a/gcc/testsuite/go.test/test/cmp.go
+++ b/gcc/testsuite/go.test/test/cmp.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test equality and inequality operations.
+
package main
import "unsafe"
@@ -281,6 +283,25 @@ func main() {
isfalse(ix != z)
isfalse(iz != x)
}
+
+ // structs with _ fields
+ {
+ var x = struct {
+ x int
+ _ []int
+ y float64
+ _ float64
+ z int
+ }{
+ x: 1, y: 2, z: 3,
+ }
+ var ix interface{} = x
+
+ istrue(x == x)
+ istrue(x == ix)
+ istrue(ix == x)
+ istrue(ix == ix)
+ }
// arrays
{
diff --git a/gcc/testsuite/go.test/test/cmp6.go b/gcc/testsuite/go.test/test/cmp6.go
index 0113a69dd..7d99aae18 100644
--- a/gcc/testsuite/go.test/test/cmp6.go
+++ b/gcc/testsuite/go.test/test/cmp6.go
@@ -1,9 +1,12 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that incorrect comparisons are detected.
+// Does not compile.
+
package main
func use(bool) {}
@@ -15,6 +18,10 @@ type T3 struct{ z []int }
var t3 T3
+type T4 struct { _ []int; a float64 }
+
+var t4 T4
+
func main() {
// Arguments to comparison must be
// assignable one to the other (or vice versa)
@@ -46,6 +53,7 @@ func main() {
// Comparison of structs should have a good message
use(t3 == t3) // ERROR "struct|expected"
+ use(t4 == t4) // ok; the []int is a blank field
// Slices, functions, and maps too.
var x []int
diff --git a/gcc/testsuite/go.test/test/cmplx.go b/gcc/testsuite/go.test/test/cmplx.go
index d5a77d684..248672e7d 100644
--- a/gcc/testsuite/go.test/test/cmplx.go
+++ b/gcc/testsuite/go.test/test/cmplx.go
@@ -1,9 +1,12 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that incorrect invocations of the complex predeclared function are detected.
+// Does not compile.
+
package main
var (
diff --git a/gcc/testsuite/go.test/test/cmplxdivide.c b/gcc/testsuite/go.test/test/cmplxdivide.c
index b340f04d8..12dc4f1c0 100644
--- a/gcc/testsuite/go.test/test/cmplxdivide.c
+++ b/gcc/testsuite/go.test/test/cmplxdivide.c
@@ -51,6 +51,7 @@ main(void)
int i, j, k, l;
double complex n, d, q;
+ printf("// skip\n");
printf("// # generated by cmplxdivide.c\n");
printf("\n");
printf("package main\n");
diff --git a/gcc/testsuite/go.test/test/cmplxdivide.go b/gcc/testsuite/go.test/test/cmplxdivide.go
index 461ee9796..92a98356d 100644
--- a/gcc/testsuite/go.test/test/cmplxdivide.go
+++ b/gcc/testsuite/go.test/test/cmplxdivide.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go $D/cmplxdivide1.go && $L $D/$F.$A && ./$A.out
+// run cmplxdivide1.go
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/cmplxdivide1.go b/gcc/testsuite/go.test/test/cmplxdivide1.go
index 6a1dee9fe..e9031dd15 100644
--- a/gcc/testsuite/go.test/test/cmplxdivide1.go
+++ b/gcc/testsuite/go.test/test/cmplxdivide1.go
@@ -1,3 +1,4 @@
+// skip
// # generated by cmplxdivide.c
package main
diff --git a/gcc/testsuite/go.test/test/complit.go b/gcc/testsuite/go.test/test/complit.go
index 8dfc71dcb..649be6d4d 100644
--- a/gcc/testsuite/go.test/test/complit.go
+++ b/gcc/testsuite/go.test/test/complit.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test composite literals.
+
package main
type T struct {
diff --git a/gcc/testsuite/go.test/test/complit1.go b/gcc/testsuite/go.test/test/complit1.go
index cd543930e..521401d73 100644
--- a/gcc/testsuite/go.test/test/complit1.go
+++ b/gcc/testsuite/go.test/test/complit1.go
@@ -1,9 +1,12 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that illegal composite literals are detected.
+// Does not compile.
+
package main
var m map[int][3]int
diff --git a/gcc/testsuite/go.test/test/compos.go b/gcc/testsuite/go.test/test/compos.go
index 70f90f379..de688b39b 100644
--- a/gcc/testsuite/go.test/test/compos.go
+++ b/gcc/testsuite/go.test/test/compos.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: compos
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test that returning &T{} from a function causes an allocation.
+
package main
type T struct {
diff --git a/gcc/testsuite/go.test/test/const.go b/gcc/testsuite/go.test/test/const.go
index a55e13a40..80fbfaf3e 100644
--- a/gcc/testsuite/go.test/test/const.go
+++ b/gcc/testsuite/go.test/test/const.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test simple boolean and numeric constants.
+
package main
const (
diff --git a/gcc/testsuite/go.test/test/const1.go b/gcc/testsuite/go.test/test/const1.go
index 67f36e4fd..1580b76c6 100644
--- a/gcc/testsuite/go.test/test/const1.go
+++ b/gcc/testsuite/go.test/test/const1.go
@@ -1,9 +1,12 @@
-// errchk $G -e $F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify overflow is detected when using numeric constants.
+// Does not compile.
+
package main
type I interface{}
@@ -13,11 +16,11 @@ const (
Int8 int8 = 101
Minus1 int8 = -1
Uint8 uint8 = 102
- Const = 103
+ Const = 103
Float32 float32 = 104.5
Float64 float64 = 105.5
- ConstFloat = 106.5
+ ConstFloat = 106.5
Big float64 = 1e300
String = "abc"
@@ -35,32 +38,35 @@ var (
a8 = Int8 * Const / 100 // ERROR "overflow"
a9 = Int8 * (Const / 100) // OK
- b1 = Uint8 * Uint8 // ERROR "overflow"
- b2 = Uint8 * -1 // ERROR "overflow"
- b3 = Uint8 - Uint8 // OK
- b4 = Uint8 - Uint8 - Uint8 // ERROR "overflow"
- b5 = uint8(^0) // ERROR "overflow"
- b6 = ^uint8(0) // OK
- b7 = uint8(Minus1) // ERROR "overflow"
- b8 = uint8(int8(-1)) // ERROR "overflow"
- b8a = uint8(-1) // ERROR "overflow"
- b9 byte = (1 << 10) >> 8 // OK
- b10 byte = (1 << 10) // ERROR "overflow"
- b11 byte = (byte(1) << 10) >> 8 // ERROR "overflow"
- b12 byte = 1000 // ERROR "overflow"
- b13 byte = byte(1000) // ERROR "overflow"
- b14 byte = byte(100) * byte(100) // ERROR "overflow"
- b15 byte = byte(100) * 100 // ERROR "overflow"
- b16 byte = byte(0) * 1000 // ERROR "overflow"
- b16a byte = 0 * 1000 // OK
- b17 byte = byte(0) * byte(1000) // ERROR "overflow"
- b18 byte = Uint8 / 0 // ERROR "division by zero"
+ b1 = Uint8 * Uint8 // ERROR "overflow"
+ b2 = Uint8 * -1 // ERROR "overflow"
+ b3 = Uint8 - Uint8 // OK
+ b4 = Uint8 - Uint8 - Uint8 // ERROR "overflow"
+ b5 = uint8(^0) // ERROR "overflow"
+ b5a = int64(^0) // OK
+ b6 = ^uint8(0) // OK
+ b6a = ^int64(0) // OK
+ b7 = uint8(Minus1) // ERROR "overflow"
+ b8 = uint8(int8(-1)) // ERROR "overflow"
+ b8a = uint8(-1) // ERROR "overflow"
+ b9 byte = (1 << 10) >> 8 // OK
+ b10 byte = (1 << 10) // ERROR "overflow"
+ b11 byte = (byte(1) << 10) >> 8 // ERROR "overflow"
+ b12 byte = 1000 // ERROR "overflow"
+ b13 byte = byte(1000) // ERROR "overflow"
+ b14 byte = byte(100) * byte(100) // ERROR "overflow"
+ b15 byte = byte(100) * 100 // ERROR "overflow"
+ b16 byte = byte(0) * 1000 // ERROR "overflow"
+ b16a byte = 0 * 1000 // OK
+ b17 byte = byte(0) * byte(1000) // ERROR "overflow"
+ b18 byte = Uint8 / 0 // ERROR "division by zero"
- c1 float64 = Big
- c2 float64 = Big * Big // ERROR "overflow"
- c3 float64 = float64(Big) * Big // ERROR "overflow"
- c4 = Big * Big // ERROR "overflow"
- c5 = Big / 0 // ERROR "division by zero"
+ c1 float64 = Big
+ c2 float64 = Big * Big // ERROR "overflow"
+ c3 float64 = float64(Big) * Big // ERROR "overflow"
+ c4 = Big * Big // ERROR "overflow"
+ c5 = Big / 0 // ERROR "division by zero"
+ c6 = 1000 % 1e3 // ERROR "floating-point % operation|expected integer type"
)
func f(int)
diff --git a/gcc/testsuite/go.test/test/const2.go b/gcc/testsuite/go.test/test/const2.go
index bea1b9912..048d0cb9f 100644
--- a/gcc/testsuite/go.test/test/const2.go
+++ b/gcc/testsuite/go.test/test/const2.go
@@ -1,12 +1,21 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that large integer constant expressions cause overflow.
+// Does not compile.
+
package main
const (
A int = 1
B byte; // ERROR "type without expr|expected .=."
)
+
+const LargeA = 1000000000000000000
+const LargeB = LargeA * LargeA * LargeA
+const LargeC = LargeB * LargeB * LargeB // GC_ERROR "constant multiplication overflow"
+
+const AlsoLargeA = LargeA << 400 << 400 >> 400 >> 400 // GC_ERROR "constant shift overflow"
diff --git a/gcc/testsuite/go.test/test/const3.go b/gcc/testsuite/go.test/test/const3.go
index 9bba6ced0..3f4e3d1ae 100644
--- a/gcc/testsuite/go.test/test/const3.go
+++ b/gcc/testsuite/go.test/test/const3.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test typed integer constants.
+
package main
import "fmt"
diff --git a/gcc/testsuite/go.test/test/const4.go b/gcc/testsuite/go.test/test/const4.go
new file mode 100644
index 000000000..677fcefa7
--- /dev/null
+++ b/gcc/testsuite/go.test/test/const4.go
@@ -0,0 +1,77 @@
+// run
+
+// Copyright 2011 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Test len constants and non-constants, http://golang.org/issue/3244.
+
+package main
+
+var b struct {
+ a[10]int
+}
+
+var m map[string][20]int
+
+var s [][30]int
+
+const (
+ n1 = len(b.a)
+ n2 = len(m[""])
+ n3 = len(s[10])
+)
+
+// Non-constants (see also const5.go).
+var (
+ n4 = len(f())
+ n5 = len(<-c)
+ n6 = cap(g())
+ n7 = cap(<-c1)
+)
+
+var calledF = false
+
+func f() *[40]int {
+ calledF = true
+ return nil
+}
+
+var c = func() chan *[50]int {
+ c := make(chan *[50]int, 2)
+ c <- nil
+ c <- new([50]int)
+ return c
+}()
+
+var calledG = false
+
+func g() *[60]int {
+ calledG = true
+ return nil
+}
+
+var c1 = func() chan *[70]int {
+ c := make(chan *[70]int, 2)
+ c <- nil
+ c <- new([70]int)
+ return c
+}()
+
+func main() {
+ if n1 != 10 || n2 != 20 || n3 != 30 || n4 != 40 || n5 != 50 || n6 != 60 || n7 != 70 {
+ println("BUG:", n1, n2, n3, n4, n5, n6, n7)
+ }
+ if !calledF {
+ println("BUG: did not call f")
+ }
+ if <-c == nil {
+ println("BUG: did not receive from c")
+ }
+ if !calledG {
+ println("BUG: did not call g")
+ }
+ if <-c1 == nil {
+ println("BUG: did not receive from c1")
+ }
+}
diff --git a/gcc/testsuite/go.test/test/const5.go b/gcc/testsuite/go.test/test/const5.go
new file mode 100644
index 000000000..d0eed137d
--- /dev/null
+++ b/gcc/testsuite/go.test/test/const5.go
@@ -0,0 +1,33 @@
+// errorcheck
+
+// Copyright 2011 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Test that len non-constants are not constants, http://golang.org/issue/3244.
+
+package p
+
+var b struct {
+ a[10]int
+}
+
+var m map[string][20]int
+
+var s [][30]int
+
+func f() *[40]int
+var c chan *[50]int
+
+const (
+ n1 = len(b.a)
+ n2 = len(m[""])
+ n3 = len(s[10])
+
+ n4 = len(f()) // ERROR "must be constant|is not constant"
+ n5 = len(<-c) // ERROR "must be constant|is not constant"
+
+ n6 = cap(f()) // ERROR "must be constant|is not constant"
+ n7 = cap(<-c) // ERROR "must be constant|is not constant"
+)
+
diff --git a/gcc/testsuite/go.test/test/convT2X.go b/gcc/testsuite/go.test/test/convT2X.go
new file mode 100644
index 000000000..7e27f06b0
--- /dev/null
+++ b/gcc/testsuite/go.test/test/convT2X.go
@@ -0,0 +1,195 @@
+// run
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Test conversion from non-interface types to the empty interface.
+
+package main
+
+type J interface {
+ Method()
+}
+
+type (
+ U16 uint16
+ U32 uint32
+ U64 uint64
+ U128 [2]uint64
+ F32 float32
+ F64 float64
+ C128 complex128
+ S string
+ B []byte
+ M map[int]int
+ C chan int
+ Z struct{}
+)
+
+func (U16) Method() {}
+func (U32) Method() {}
+func (U64) Method() {}
+func (U128) Method() {}
+func (F32) Method() {}
+func (F64) Method() {}
+func (C128) Method() {}
+func (S) Method() {}
+func (B) Method() {}
+func (M) Method() {}
+func (C) Method() {}
+func (Z) Method() {}
+
+var (
+ u16 = U16(1)
+ u32 = U32(2)
+ u64 = U64(3)
+ u128 = U128{4, 5}
+ f32 = F32(6)
+ f64 = F64(7)
+ c128 = C128(8 + 9i)
+ s = S("10")
+ b = B("11")
+ m = M{12: 13}
+ c = make(C, 14)
+ z = Z{}
+ p = &z
+ pp = &p
+)
+
+var (
+ iu16 interface{} = u16
+ iu32 interface{} = u32
+ iu64 interface{} = u64
+ iu128 interface{} = u128
+ if32 interface{} = f32
+ if64 interface{} = f64
+ ic128 interface{} = c128
+ is interface{} = s
+ ib interface{} = b
+ im interface{} = m
+ ic interface{} = c
+ iz interface{} = z
+ ip interface{} = p
+ ipp interface{} = pp
+
+ ju16 J = u16
+ ju32 J = u32
+ ju64 J = u64
+ ju128 J = u128
+ jf32 J = f32
+ jf64 J = f64
+ jc128 J = c128
+ js J = s
+ jb J = b
+ jm J = m
+ jc J = c
+ jz J = z
+ jp J = p // The method set for *T contains the methods for T.
+ // pp does not implement error.
+)
+
+func second(a ...interface{}) interface{} {
+ return a[1]
+}
+
+func main() {
+ // Test equality.
+ if u16 != iu16 {
+ panic("u16 != iu16")
+ }
+ if u16 != ju16 {
+ panic("u16 != ju16")
+ }
+ if u32 != iu32 {
+ panic("u32 != iu32")
+ }
+ if u32 != ju32 {
+ panic("u32 != ju32")
+ }
+ if u64 != iu64 {
+ panic("u64 != iu64")
+ }
+ if u64 != ju64 {
+ panic("u64 != ju64")
+ }
+ if u128 != iu128 {
+ panic("u128 != iu128")
+ }
+ if u128 != ju128 {
+ panic("u128 != ju128")
+ }
+ if f32 != if32 {
+ panic("f32 != if32")
+ }
+ if f32 != jf32 {
+ panic("f32 != jf32")
+ }
+ if f64 != if64 {
+ panic("f64 != if64")
+ }
+ if f64 != jf64 {
+ panic("f64 != jf64")
+ }
+ if c128 != ic128 {
+ panic("c128 != ic128")
+ }
+ if c128 != jc128 {
+ panic("c128 != jc128")
+ }
+ if s != is {
+ panic("s != is")
+ }
+ if s != js {
+ panic("s != js")
+ }
+ if c != ic {
+ panic("c != ic")
+ }
+ if c != jc {
+ panic("c != jc")
+ }
+ // There are no tests for b and m, as slices and maps are not comparable by ==.
+ if z != iz {
+ panic("z != iz")
+ }
+ if z != jz {
+ panic("z != jz")
+ }
+ if p != ip {
+ panic("p != ip")
+ }
+ if p != jp {
+ panic("p != jp")
+ }
+ if pp != ipp {
+ panic("pp != ipp")
+ }
+ // pp does not implement J.
+
+ // Test that non-interface types can be used as ...interface{} arguments.
+ if got := second(z, p, pp, u16, u32, u64, u128, f32, f64, c128, s, b, m, c); got != ip {
+ println("second: got", got, "want", ip)
+ panic("fail")
+ }
+
+ // Test that non-interface types can be sent on a chan interface{}.
+ const n = 100
+ uc := make(chan interface{})
+ go func() {
+ for i := 0; i < n; i++ {
+ select {
+ case uc <- nil:
+ case uc <- u32:
+ case uc <- u64:
+ case uc <- u128:
+ }
+ }
+ }()
+ for i := 0; i < n; i++ {
+ if got := <-uc; got != nil && got != u32 && got != u64 && got != u128 {
+ println("recv: i", i, "got", got)
+ panic("fail")
+ }
+ }
+}
diff --git a/gcc/testsuite/go.test/test/convert.go b/gcc/testsuite/go.test/test/convert.go
index 0a75663d0..7280edf33 100644
--- a/gcc/testsuite/go.test/test/convert.go
+++ b/gcc/testsuite/go.test/test/convert.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test types of constant expressions, using reflect.
+
package main
import "reflect"
diff --git a/gcc/testsuite/go.test/test/convert1.go b/gcc/testsuite/go.test/test/convert1.go
index bbd0c5f2b..0f417a338 100644
--- a/gcc/testsuite/go.test/test/convert1.go
+++ b/gcc/testsuite/go.test/test/convert1.go
@@ -1,9 +1,12 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that illegal conversions involving strings are detected.
+// Does not compile.
+
package main
type Tbyte []byte
diff --git a/gcc/testsuite/go.test/test/convert3.go b/gcc/testsuite/go.test/test/convert3.go
index be68c95b3..143aff04f 100644
--- a/gcc/testsuite/go.test/test/convert3.go
+++ b/gcc/testsuite/go.test/test/convert3.go
@@ -1,9 +1,12 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify allowed and disallowed conversions.
+// Does not compile.
+
package main
// everything here is legal except the ERROR line
diff --git a/gcc/testsuite/go.test/test/convlit.go b/gcc/testsuite/go.test/test/convlit.go
index 1e82d1f2f..8a6145d2a 100644
--- a/gcc/testsuite/go.test/test/convlit.go
+++ b/gcc/testsuite/go.test/test/convlit.go
@@ -1,14 +1,15 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that illegal assignments with both explicit and implicit conversions of literals are detected.
+// Does not compile.
+
package main
-// explicit conversion of constants is work in progress.
-// the ERRORs in this block are debatable, but they're what
-// the language spec says for now.
+// explicit conversion of constants
var x1 = string(1)
var x2 string = string(1)
var x3 = int(1.5) // ERROR "convert|truncate"
diff --git a/gcc/testsuite/go.test/test/convlit1.go b/gcc/testsuite/go.test/test/convlit1.go
index 1e6673cb6..c06bd7443 100644
--- a/gcc/testsuite/go.test/test/convlit1.go
+++ b/gcc/testsuite/go.test/test/convlit1.go
@@ -1,9 +1,12 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that illegal uses of composite literals are detected.
+// Does not compile.
+
package main
var a = []int { "a" }; // ERROR "conver|incompatible|cannot"
diff --git a/gcc/testsuite/go.test/test/copy.go b/gcc/testsuite/go.test/test/copy.go
index 0b5bddbed..65ffb6ff8 100644
--- a/gcc/testsuite/go.test/test/copy.go
+++ b/gcc/testsuite/go.test/test/copy.go
@@ -1,10 +1,10 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Semi-exhaustive test for copy()
+// Semi-exhaustive test for the copy predeclared function.
package main
diff --git a/gcc/testsuite/go.test/test/crlf.go b/gcc/testsuite/go.test/test/crlf.go
index 292b63bf4..2d56889b0 100644
--- a/gcc/testsuite/go.test/test/crlf.go
+++ b/gcc/testsuite/go.test/test/crlf.go
@@ -1,6 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out >tmp.go &&
-// $G tmp.go && $L tmp.$A && ./$A.out
-// rm -f tmp.go
+// runoutput
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/ddd.go b/gcc/testsuite/go.test/test/ddd.go
index b95d6e883..01768b89f 100644
--- a/gcc/testsuite/go.test/test/ddd.go
+++ b/gcc/testsuite/go.test/test/ddd.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test variadic functions and calls (dot-dot-dot).
+
package main
func sum(args ...int) int {
@@ -58,6 +60,10 @@ type U struct {
*T
}
+type I interface {
+ Sum(...int) int
+}
+
func main() {
if x := sum(1, 2, 3); x != 6 {
println("sum 6", x)
@@ -205,7 +211,14 @@ func main() {
println("i(=u).Sum", x)
panic("fail")
}
- /* TODO(rsc): Enable once nested method expressions work.
+ var s struct {
+ I
+ }
+ s.I = &u
+ if x := s.Sum(2, 3, 5, 8); x != 18 {
+ println("s{&u}.Sum", x)
+ panic("fail")
+ }
if x := (*U).Sum(&U{}, 1, 3, 5, 2); x != 11 {
println("(*U).Sum", x)
panic("fail")
@@ -214,5 +227,4 @@ func main() {
println("U.Sum", x)
panic("fail")
}
- */
}
diff --git a/gcc/testsuite/go.test/test/ddd1.go b/gcc/testsuite/go.test/test/ddd1.go
index 6d84248e5..07981af12 100644
--- a/gcc/testsuite/go.test/test/ddd1.go
+++ b/gcc/testsuite/go.test/test/ddd1.go
@@ -1,9 +1,12 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that illegal uses of ... are detected.
+// Does not compile.
+
package main
import "unsafe"
@@ -19,6 +22,16 @@ var (
_ = sum([]int{1}) // ERROR "\[\]int literal.*as type int|incompatible"
)
+func sum3(int, int, int) int { return 0 }
+func tuple() (int, int, int) { return 1, 2, 3 }
+
+var (
+ _ = sum(tuple())
+ _ = sum(tuple()...) // ERROR "multiple-value|[.][.][.]"
+ _ = sum3(tuple())
+ _ = sum3(tuple()...) // ERROR "multiple-value|[.][.][.]" "not enough"
+)
+
type T []T
func funny(args ...T) int { return 0 }
diff --git a/gcc/testsuite/go.test/test/ddd2.go b/gcc/testsuite/go.test/test/ddd2.go
index a06af0c06..a141a39c7 100644
--- a/gcc/testsuite/go.test/test/ddd2.go
+++ b/gcc/testsuite/go.test/test/ddd2.go
@@ -1,9 +1,11 @@
-// true
+// skip
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// This file is compiled and then imported by ddd3.go.
+
package ddd
func Sum(args ...int) int {
diff --git a/gcc/testsuite/go.test/test/ddd3.go b/gcc/testsuite/go.test/test/ddd3.go
index 5d5ebdf0f..d8de0a77e 100644
--- a/gcc/testsuite/go.test/test/ddd3.go
+++ b/gcc/testsuite/go.test/test/ddd3.go
@@ -1,9 +1,14 @@
// $G $D/ddd2.go && $G $D/$F.go && $L $F.$A && ./$A.out
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test that variadic functions work across package boundaries.
+
package main
import "./ddd2"
diff --git a/gcc/testsuite/go.test/test/decl.go b/gcc/testsuite/go.test/test/decl.go
index 95b6346c3..6f84245f1 100644
--- a/gcc/testsuite/go.test/test/decl.go
+++ b/gcc/testsuite/go.test/test/decl.go
@@ -1,10 +1,10 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Correct short declarations and redeclarations.
+// Test correct short declarations and redeclarations.
package main
diff --git a/gcc/testsuite/go.test/test/declbad.go b/gcc/testsuite/go.test/test/declbad.go
index 09f1dfb57..ff53ab0d7 100644
--- a/gcc/testsuite/go.test/test/declbad.go
+++ b/gcc/testsuite/go.test/test/declbad.go
@@ -1,10 +1,11 @@
-// errchk $G -e $F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Incorrect short declarations and redeclarations.
+// Test that incorrect short declarations and redeclarations are detected.
+// Does not compile.
package main
@@ -38,6 +39,13 @@ func main() {
_, _, _ = i, f, s
}
{
+ // multiline no new variables
+ i := f1
+ i := func() { // ERROR "redeclared|no new|incompatible"
+ }
+ _ = i
+ }
+ {
// single redeclaration
i, f, s := f3()
i := 1 // ERROR "redeclared|no new|incompatible"
diff --git a/gcc/testsuite/go.test/test/defer.go b/gcc/testsuite/go.test/test/defer.go
index bef8fbe26..2f67d3560 100644
--- a/gcc/testsuite/go.test/test/defer.go
+++ b/gcc/testsuite/go.test/test/defer.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test defer.
+
package main
import "fmt"
diff --git a/gcc/testsuite/go.test/test/deferprint.go b/gcc/testsuite/go.test/test/deferprint.go
index 0e0c61821..72c98b19f 100644
--- a/gcc/testsuite/go.test/test/deferprint.go
+++ b/gcc/testsuite/go.test/test/deferprint.go
@@ -1,14 +1,17 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out 2>&1 | cmp - $D/$F.out
+// cmpout
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test that we can defer the predeclared functions print and println.
+
package main
func main() {
defer println(42, true, false, true, 1.5, "world", (chan int)(nil), []int(nil), (map[string]int)(nil), (func())(nil), byte(255))
defer println(1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20)
-// defer panic("dead")
+ // Disabled so the test doesn't crash but left here for reference.
+ // defer panic("dead")
defer print("printing: ")
}
diff --git a/gcc/testsuite/go.test/test/divide.go b/gcc/testsuite/go.test/test/divide.go
index 5c0f45059..c91a33e9d 100644
--- a/gcc/testsuite/go.test/test/divide.go
+++ b/gcc/testsuite/go.test/test/divide.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// divide corner cases
+// Test divide corner cases.
package main
diff --git a/gcc/testsuite/go.test/test/dwarf/linedirectives.go b/gcc/testsuite/go.test/test/dwarf/linedirectives.go
index 68434f0ab..cc4ffb000 100644
--- a/gcc/testsuite/go.test/test/dwarf/linedirectives.go
+++ b/gcc/testsuite/go.test/test/dwarf/linedirectives.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/dwarf/main.go b/gcc/testsuite/go.test/test/dwarf/main.go
index 7f2ec4c00..175a09c77 100644
--- a/gcc/testsuite/go.test/test/dwarf/main.go
+++ b/gcc/testsuite/go.test/test/dwarf/main.go
@@ -1,5 +1,8 @@
// $G $D/$F.go $D/z*.go && $L $F.$A && ./$A.out
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
diff --git a/gcc/testsuite/go.test/test/empty.go b/gcc/testsuite/go.test/test/empty.go
index fa10d6931..92a79a4e0 100644
--- a/gcc/testsuite/go.test/test/empty.go
+++ b/gcc/testsuite/go.test/test/empty.go
@@ -1,9 +1,12 @@
-// $G $D/$F.go
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test that top-level parenthesized declarations can be empty.
+// Compiles but does not run.
+
package P
import ( )
diff --git a/gcc/testsuite/go.test/test/env.go b/gcc/testsuite/go.test/test/env.go
index 3c8e42328..972374679 100644
--- a/gcc/testsuite/go.test/test/env.go
+++ b/gcc/testsuite/go.test/test/env.go
@@ -1,4 +1,4 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/eof.go b/gcc/testsuite/go.test/test/eof.go
index 81f9fd028..06c779046 100644
--- a/gcc/testsuite/go.test/test/eof.go
+++ b/gcc/testsuite/go.test/test/eof.go
@@ -1,9 +1,12 @@
-// $G $D/$F.go
+// compile
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test a source file does not need a final newline.
+// Compiles but does not run.
+
// No newline at the end of this file.
package main \ No newline at end of file
diff --git a/gcc/testsuite/go.test/test/eof1.go b/gcc/testsuite/go.test/test/eof1.go
index c39a3cfdb..2105b8908 100644
--- a/gcc/testsuite/go.test/test/eof1.go
+++ b/gcc/testsuite/go.test/test/eof1.go
@@ -1,9 +1,12 @@
-// $G $D/$F.go
+// compile
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-package main
+// Test that a comment ending a source file does not need a final newline.
+// Compiles but does not run.
+
+package eof1
// No newline at the end of this comment. \ No newline at end of file
diff --git a/gcc/testsuite/go.test/test/escape.go b/gcc/testsuite/go.test/test/escape.go
index d4d844704..e8ede5276 100644
--- a/gcc/testsuite/go.test/test/escape.go
+++ b/gcc/testsuite/go.test/test/escape.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
@@ -6,8 +6,8 @@
package main
-// check for correct heap-moving of escaped variables.
-// it is hard to check for the allocations, but it is easy
+// Test for correct heap-moving of escaped variables.
+// It is hard to check for the allocations, but it is easy
// to check that if you call the function twice at the
// same stack level, the pointers returned should be
// different.
@@ -18,15 +18,15 @@ var allptr = make([]*int, 0, 100)
func noalias(p, q *int, s string) {
n := len(allptr)
- *p = -(n+1)
- *q = -(n+2)
- allptr = allptr[0:n+2]
+ *p = -(n + 1)
+ *q = -(n + 2)
+ allptr = allptr[0 : n+2]
allptr[n] = p
allptr[n+1] = q
n += 2
for i := 0; i < n; i++ {
if allptr[i] != nil && *allptr[i] != -(i+1) {
- println("aliased pointers", -(i+1), *allptr[i], "after", s)
+ println("aliased pointers", -(i + 1), *allptr[i], "after", s)
allptr[i] = nil
bad = true
}
@@ -141,15 +141,27 @@ func for_escapes2(x int, y int) (*int, *int) {
return p[0], p[1]
}
+func for_escapes3(x int, y int) (*int, *int) {
+ var f [2]func() *int
+ n := 0
+ for i := x; n < 2; i = y {
+ p := new(int)
+ *p = i
+ f[n] = func() *int { return p }
+ n++
+ }
+ return f[0](), f[1]()
+}
+
func out_escapes(i int) (x int, p *int) {
x = i
- p = &x // ERROR "address of out parameter"
+ p = &x // ERROR "address of out parameter"
return
}
func out_escapes_2(i int) (x int, p *int) {
x = i
- return x, &x // ERROR "address of out parameter"
+ return x, &x // ERROR "address of out parameter"
}
func defer1(i int) (x int) {
@@ -187,6 +199,9 @@ func main() {
p, q = for_escapes2(103, 104)
chkalias(p, q, 103, "for_escapes2")
+ p, q = for_escapes3(105, 106)
+ chk(p, q, 105, "for_escapes3")
+
_, p = out_escapes(15)
_, q = out_escapes(16)
chk(p, q, 15, "out_escapes")
diff --git a/gcc/testsuite/go.test/test/escape2.go b/gcc/testsuite/go.test/test/escape2.go
index 73b2a7e58..8db12d991 100644
--- a/gcc/testsuite/go.test/test/escape2.go
+++ b/gcc/testsuite/go.test/test/escape2.go
@@ -1,9 +1,12 @@
-// errchk -0 $G -m -l $D/$F.go
+// errorcheck -0 -m -l
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test, using compiler diagnostic flags, that the escape analysis is working.
+// Compiles but does not run. Inlining is disabled.
+
package foo
import (
@@ -537,6 +540,19 @@ func foo74() {
}
}
+// issue 3975
+func foo74b() {
+ var array [3]func()
+ s := []int{3, 2, 1} // ERROR "\[\]int literal does not escape"
+ for i, v := range s {
+ vv := v // ERROR "moved to heap: vv"
+ // actually just escapes its scope
+ array[i] = func() { // ERROR "func literal escapes to heap"
+ println(vv) // ERROR "&vv escapes to heap"
+ }
+ }
+}
+
func myprint(y *int, x ...interface{}) *int { // ERROR "x does not escape" "leaking param: y"
return y
}
@@ -1048,7 +1064,7 @@ func foo122() {
goto L1
L1:
- i = new(int) // ERROR "does not escape"
+ i = new(int) // ERROR "new.int. does not escape"
_ = i
}
@@ -1057,8 +1073,159 @@ func foo123() {
var i *int
L1:
- i = new(int) // ERROR "escapes"
+ i = new(int) // ERROR "new.int. escapes to heap"
goto L1
_ = i
}
+
+func foo124(x **int) { // ERROR "x does not escape"
+ var i int // ERROR "moved to heap: i"
+ p := &i // ERROR "&i escapes"
+ func() { // ERROR "func literal does not escape"
+ *x = p // ERROR "leaking closure reference p"
+ }()
+}
+
+func foo125(ch chan *int) { // ERROR "does not escape"
+ var i int // ERROR "moved to heap"
+ p := &i // ERROR "&i escapes to heap"
+ func() { // ERROR "func literal does not escape"
+ ch <- p // ERROR "leaking closure reference p"
+ }()
+}
+
+func foo126() {
+ var px *int // loopdepth 0
+ for {
+ // loopdepth 1
+ var i int // ERROR "moved to heap"
+ func() { // ERROR "func literal does not escape"
+ px = &i // ERROR "&i escapes"
+ }()
+ }
+}
+
+var px *int
+
+func foo127() {
+ var i int // ERROR "moved to heap: i"
+ p := &i // ERROR "&i escapes to heap"
+ q := p
+ px = q
+}
+
+func foo128() {
+ var i int
+ p := &i // ERROR "&i does not escape"
+ q := p
+ _ = q
+}
+
+func foo129() {
+ var i int // ERROR "moved to heap: i"
+ p := &i // ERROR "&i escapes to heap"
+ func() { // ERROR "func literal does not escape"
+ q := p // ERROR "leaking closure reference p"
+ func() { // ERROR "func literal does not escape"
+ r := q // ERROR "leaking closure reference q"
+ px = r
+ }()
+ }()
+}
+
+func foo130() {
+ for {
+ var i int // ERROR "moved to heap"
+ func() { // ERROR "func literal does not escape"
+ px = &i // ERROR "&i escapes" "leaking closure reference i"
+ }()
+ }
+}
+
+func foo131() {
+ var i int // ERROR "moved to heap"
+ func() { // ERROR "func literal does not escape"
+ px = &i // ERROR "&i escapes" "leaking closure reference i"
+ }()
+}
+
+func foo132() {
+ var i int // ERROR "moved to heap"
+ go func() { // ERROR "func literal escapes to heap"
+ px = &i // ERROR "&i escapes" "leaking closure reference i"
+ }()
+}
+
+func foo133() {
+ var i int // ERROR "moved to heap"
+ defer func() { // ERROR "func literal does not escape"
+ px = &i // ERROR "&i escapes" "leaking closure reference i"
+ }()
+}
+
+func foo134() {
+ var i int
+ p := &i // ERROR "&i does not escape"
+ func() { // ERROR "func literal does not escape"
+ q := p
+ func() { // ERROR "func literal does not escape"
+ r := q
+ _ = r
+ }()
+ }()
+}
+
+func foo135() {
+ var i int // ERROR "moved to heap: i"
+ p := &i // ERROR "&i escapes to heap" "moved to heap: p"
+ go func() { // ERROR "func literal escapes to heap"
+ q := p // ERROR "&p escapes to heap"
+ func() { // ERROR "func literal does not escape"
+ r := q
+ _ = r
+ }()
+ }()
+}
+
+func foo136() {
+ var i int // ERROR "moved to heap: i"
+ p := &i // ERROR "&i escapes to heap" "moved to heap: p"
+ go func() { // ERROR "func literal escapes to heap"
+ q := p // ERROR "&p escapes to heap" "leaking closure reference p"
+ func() { // ERROR "func literal does not escape"
+ r := q // ERROR "leaking closure reference q"
+ px = r
+ }()
+ }()
+}
+
+func foo137() {
+ var i int // ERROR "moved to heap: i"
+ p := &i // ERROR "&i escapes to heap"
+ func() { // ERROR "func literal does not escape"
+ q := p // ERROR "leaking closure reference p" "moved to heap: q"
+ go func() { // ERROR "func literal escapes to heap"
+ r := q // ERROR "&q escapes to heap"
+ _ = r
+ }()
+ }()
+}
+
+func foo138() *byte {
+ type T struct {
+ x [1]byte
+ }
+ t := new(T) // ERROR "new.T. escapes to heap"
+ return &t.x[0] // ERROR "&t.x.0. escapes to heap"
+}
+
+func foo139() *byte {
+ type T struct {
+ x struct {
+ y byte
+ }
+ }
+ t := new(T) // ERROR "new.T. escapes to heap"
+ return &t.x.y // ERROR "&t.x.y escapes to heap"
+}
diff --git a/gcc/testsuite/go.test/test/escape3.go b/gcc/testsuite/go.test/test/escape3.go
index fc2d6ebbe..4c1989151 100644
--- a/gcc/testsuite/go.test/test/escape3.go
+++ b/gcc/testsuite/go.test/test/escape3.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Test run-time behavior of escape analysis-related optimizations.
+// Test the run-time behavior of escape analysis-related optimizations.
package main
diff --git a/gcc/testsuite/go.test/test/escape4.go b/gcc/testsuite/go.test/test/escape4.go
new file mode 100644
index 000000000..83bc8eb12
--- /dev/null
+++ b/gcc/testsuite/go.test/test/escape4.go
@@ -0,0 +1,57 @@
+// errorcheck -0 -m
+
+// Copyright 2010 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Test, using compiler diagnostic flags, that the escape analysis is working.
+// Compiles but does not run. Inlining is enabled.
+
+package foo
+
+var p *int
+
+func alloc(x int) *int { // ERROR "can inline alloc" "moved to heap: x"
+ return &x // ERROR "&x escapes to heap"
+}
+
+var f func()
+
+func f1() {
+ p = alloc(2) // ERROR "inlining call to alloc" "&x escapes to heap" "moved to heap: x"
+
+ // Escape analysis used to miss inlined code in closures.
+
+ func() { // ERROR "func literal does not escape"
+ p = alloc(3) // ERROR "inlining call to alloc" "&x escapes to heap" "moved to heap: x"
+ }()
+
+ f = func() { // ERROR "func literal escapes to heap"
+ p = alloc(3) // ERROR "inlining call to alloc" "&x escapes to heap" "moved to heap: x"
+ }
+ f()
+}
+
+func f2() {} // ERROR "can inline f2"
+
+// No inline for panic, recover.
+func f3() { panic(1) }
+func f4() { recover() }
+
+func f5() *byte {
+ type T struct {
+ x [1]byte
+ }
+ t := new(T) // ERROR "new.T. escapes to heap"
+ return &t.x[0] // ERROR "&t.x.0. escapes to heap"
+}
+
+func f6() *byte {
+ type T struct {
+ x struct {
+ y byte
+ }
+ }
+ t := new(T) // ERROR "new.T. escapes to heap"
+ return &t.x.y // ERROR "&t.x.y escapes to heap"
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug000.go b/gcc/testsuite/go.test/test/fixedbugs/bug000.go
index ccb24e8e9..9104a57aa 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug000.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug000.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug002.go b/gcc/testsuite/go.test/test/fixedbugs/bug002.go
index 230841974..3493426d3 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug002.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug002.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug003.go b/gcc/testsuite/go.test/test/fixedbugs/bug003.go
index e45975be4..7165d9d20 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug003.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug003.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug004.go b/gcc/testsuite/go.test/test/fixedbugs/bug004.go
index 20f467a5f..fb207e9bc 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug004.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug004.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug005.go b/gcc/testsuite/go.test/test/fixedbugs/bug005.go
index 3bd2fe815..3798f8321 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug005.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug005.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug006.go b/gcc/testsuite/go.test/test/fixedbugs/bug006.go
index 43b5dfb12..6761682b3 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug006.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug006.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug007.go b/gcc/testsuite/go.test/test/fixedbugs/bug007.go
index d65f6da45..3d9fcb9e0 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug007.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug007.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug008.go b/gcc/testsuite/go.test/test/fixedbugs/bug008.go
index 2baead11e..48f74a52d 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug008.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug008.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug009.go b/gcc/testsuite/go.test/test/fixedbugs/bug009.go
index ef8263bb2..0467b297a 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug009.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug009.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug010.go b/gcc/testsuite/go.test/test/fixedbugs/bug010.go
index 7d96988d4..f54b1d54a 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug010.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug010.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug011.go b/gcc/testsuite/go.test/test/fixedbugs/bug011.go
index ce627472c..519c3585f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug011.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug011.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug012.go b/gcc/testsuite/go.test/test/fixedbugs/bug012.go
index ffd5b5570..38efb6d97 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug012.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug012.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug013.go b/gcc/testsuite/go.test/test/fixedbugs/bug013.go
index 4b106775c..045786bf7 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug013.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug013.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug014.go b/gcc/testsuite/go.test/test/fixedbugs/bug014.go
index 38a6e51ab..a20f0310e 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug014.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug014.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug015.go b/gcc/testsuite/go.test/test/fixedbugs/bug015.go
index 9178f626f..d3a9f22ed 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug015.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug015.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug016.go b/gcc/testsuite/go.test/test/fixedbugs/bug016.go
index 4fbfd48fd..18fac78f3 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug016.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug016.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug017.go b/gcc/testsuite/go.test/test/fixedbugs/bug017.go
index fdc986d9d..2f5960d10 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug017.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug017.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug020.go b/gcc/testsuite/go.test/test/fixedbugs/bug020.go
index 896bf5707..cde3f8679 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug020.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug020.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug021.go b/gcc/testsuite/go.test/test/fixedbugs/bug021.go
index 201fa5f03..bf936e875 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug021.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug021.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug022.go b/gcc/testsuite/go.test/test/fixedbugs/bug022.go
index f94a58569..65a8bfe9a 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug022.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug022.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug023.go b/gcc/testsuite/go.test/test/fixedbugs/bug023.go
index b3d3d4a3c..9b211cd54 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug023.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug023.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug024.go b/gcc/testsuite/go.test/test/fixedbugs/bug024.go
index c7b17b7c0..2e235b7b4 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug024.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug024.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug026.go b/gcc/testsuite/go.test/test/fixedbugs/bug026.go
index eacea3745..bfd03cc95 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug026.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug026.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug027.go b/gcc/testsuite/go.test/test/fixedbugs/bug027.go
index cf2daaecf..874b47e7a 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug027.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug027.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug028.go b/gcc/testsuite/go.test/test/fixedbugs/bug028.go
index 0488ad2cb..2edf5a910 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug028.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug028.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug030.go b/gcc/testsuite/go.test/test/fixedbugs/bug030.go
index 7efde9b44..ffd29e057 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug030.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug030.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug031.go b/gcc/testsuite/go.test/test/fixedbugs/bug031.go
index acb4741e9..529e5ce84 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug031.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug031.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug035.go b/gcc/testsuite/go.test/test/fixedbugs/bug035.go
index bd2a633f2..ae41a1795 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug035.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug035.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug036.go b/gcc/testsuite/go.test/test/fixedbugs/bug036.go
deleted file mode 100644
index cc20516ce..000000000
--- a/gcc/testsuite/go.test/test/fixedbugs/bug036.go
+++ /dev/null
@@ -1,13 +0,0 @@
-// ! $G $D/$F.go >/dev/null
-// # ignoring error messages...
-
-// Copyright 2009 The Go Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style
-// license that can be found in the LICENSE file.
-
-package main
-
-func main() {
- s := float(0);
- s := float(0); // BUG redeclaration
-}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug037.go b/gcc/testsuite/go.test/test/fixedbugs/bug037.go
index ff7d28710..f17fb3fd7 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug037.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug037.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug038.go b/gcc/testsuite/go.test/test/fixedbugs/bug038.go
deleted file mode 100644
index 7585376a3..000000000
--- a/gcc/testsuite/go.test/test/fixedbugs/bug038.go
+++ /dev/null
@@ -1,13 +0,0 @@
-// ! $G $D/$F.go >/dev/null
-// # ignoring error messages...
-
-// Copyright 2009 The Go Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style
-// license that can be found in the LICENSE file.
-
-package main
-
-func main() {
- var z [3]byte;
- z := new([3]byte); // BUG redeclaration
-}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug039.go b/gcc/testsuite/go.test/test/fixedbugs/bug039.go
index 7ac02ceeb..d34f5e62e 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug039.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug039.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug040.go b/gcc/testsuite/go.test/test/fixedbugs/bug040.go
index 912316cb6..007f47f9f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug040.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug040.go
@@ -1,5 +1,4 @@
-// ! $G $D/$F.go >/dev/null
-// # ignoring error messages...
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
@@ -7,5 +6,6 @@
package main
-func main (x, x int) { // BUG redeclaration error
+func f (x, // GCCGO_ERROR "previous"
+ x int) { // ERROR "redeclared|redefinition" "duplicate"
}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug045.go b/gcc/testsuite/go.test/test/fixedbugs/bug045.go
index 94888c40e..c66a2411a 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug045.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug045.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug046.go b/gcc/testsuite/go.test/test/fixedbugs/bug046.go
index 8a9b79707..219e91d53 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug046.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug046.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug047.go b/gcc/testsuite/go.test/test/fixedbugs/bug047.go
index 5a776abce..7619ae73c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug047.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug047.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug048.go b/gcc/testsuite/go.test/test/fixedbugs/bug048.go
index b9fee7899..48ad751e2 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug048.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug048.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug049.go b/gcc/testsuite/go.test/test/fixedbugs/bug049.go
index 8fd67ccd5..51990f2df 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug049.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug049.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug050.go b/gcc/testsuite/go.test/test/fixedbugs/bug050.go
index 585c44623..aba68b1dc 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug050.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug050.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug051.go b/gcc/testsuite/go.test/test/fixedbugs/bug051.go
index dd1662306..c4ba2eff6 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug051.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug051.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug052.go b/gcc/testsuite/go.test/test/fixedbugs/bug052.go
index d2c1b5061..440a00ebe 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug052.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug052.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug053.go b/gcc/testsuite/go.test/test/fixedbugs/bug053.go
index c981403ed..00625fd7c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug053.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug053.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug054.go b/gcc/testsuite/go.test/test/fixedbugs/bug054.go
index c8a2272c2..01590585c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug054.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug054.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug055.go b/gcc/testsuite/go.test/test/fixedbugs/bug055.go
index 861739610..c3073cc1e 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug055.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug055.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug056.go b/gcc/testsuite/go.test/test/fixedbugs/bug056.go
index 050a4a5c5..13eac2920 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug056.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug056.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug057.go b/gcc/testsuite/go.test/test/fixedbugs/bug057.go
index d5d0f1d62..19b8651a5 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug057.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug057.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug058.go b/gcc/testsuite/go.test/test/fixedbugs/bug058.go
index e2b4a241a..2b97dbf7c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug058.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug058.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug059.go b/gcc/testsuite/go.test/test/fixedbugs/bug059.go
index 6a77367d6..6f64b9e0b 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug059.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug059.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug060.go b/gcc/testsuite/go.test/test/fixedbugs/bug060.go
index 82778b838..826072905 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug060.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug060.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug061.go b/gcc/testsuite/go.test/test/fixedbugs/bug061.go
index aedcf70fe..ae99b186d 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug061.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug061.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug062.go b/gcc/testsuite/go.test/test/fixedbugs/bug062.go
index 8ee5c84cb..1cc500365 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug062.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug062.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug063.go b/gcc/testsuite/go.test/test/fixedbugs/bug063.go
index 543e0b726..a3ae3f096 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug063.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug063.go
@@ -1,8 +1,8 @@
-// $G $D/$F.go
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-package main
+package bug063
const c = 0 ^ 0
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug064.go b/gcc/testsuite/go.test/test/fixedbugs/bug064.go
index 92d215423..d8b3bea9a 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug064.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug064.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: compilation should succeed
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug065.go b/gcc/testsuite/go.test/test/fixedbugs/bug065.go
index a5d1beddd..a1e3b08bb 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug065.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug065.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug066.go b/gcc/testsuite/go.test/test/fixedbugs/bug066.go
index 2fa5048f1..db3d7f860 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug066.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug066.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-package main
+package bug066
type Scope struct {
entries map[string] *Object;
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug067.go b/gcc/testsuite/go.test/test/fixedbugs/bug067.go
index 328d191bb..aaeefb0ba 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug067.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug067.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug068.go b/gcc/testsuite/go.test/test/fixedbugs/bug068.go
index a7cf4239c..2cb10ab3a 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug068.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug068.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug069.go b/gcc/testsuite/go.test/test/fixedbugs/bug069.go
index 9038387ac..7b07b773d 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug069.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug069.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug070.go b/gcc/testsuite/go.test/test/fixedbugs/bug070.go
index 24ac77988..3f3ffcf61 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug070.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug070.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug071.go b/gcc/testsuite/go.test/test/fixedbugs/bug071.go
index a5003ffb9..ec38f7a97 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug071.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug071.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go || echo BUG: compiler crashes
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-package main
+package bug071
type rat struct {
den int;
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug072.go b/gcc/testsuite/go.test/test/fixedbugs/bug072.go
index efe5626db..05ad93dac 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug072.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug072.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug073.go b/gcc/testsuite/go.test/test/fixedbugs/bug073.go
index 99e7cd19e..49b47ae46 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug073.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug073.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug074.go b/gcc/testsuite/go.test/test/fixedbugs/bug074.go
index 7b6d14e7e..fb789cb4c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug074.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug074.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug075.go b/gcc/testsuite/go.test/test/fixedbugs/bug075.go
index 7aed13089..d0b7d14e7 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug075.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug075.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug076.go b/gcc/testsuite/go.test/test/fixedbugs/bug076.go
index 2ca518d76..60aaa9760 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug076.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug076.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A
+// build
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug077.go b/gcc/testsuite/go.test/test/fixedbugs/bug077.go
index 2cbf96d98..80581a8a3 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug077.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug077.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug078.go b/gcc/testsuite/go.test/test/fixedbugs/bug078.go
index ddd3faeba..1041b858c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug078.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug078.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug080.go b/gcc/testsuite/go.test/test/fixedbugs/bug080.go
index bae16cdb2..32b2c53b9 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug080.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug080.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: fails incorrectly
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug081.go b/gcc/testsuite/go.test/test/fixedbugs/bug081.go
index 026ce8002..c25d28837 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug081.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug081.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug082.go b/gcc/testsuite/go.test/test/fixedbugs/bug082.go
index 8353ec200..e184ef193 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug082.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug082.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug083.go b/gcc/testsuite/go.test/test/fixedbugs/bug083.go
index 984969d47..8bdecaadb 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug083.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug083.go
@@ -1,5 +1,8 @@
// $G $D/$F.dir/bug0.go && errchk $G $D/$F.dir/bug1.go
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug084.go b/gcc/testsuite/go.test/test/fixedbugs/bug084.go
index c1054e550..700a67433 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug084.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug084.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug085.go b/gcc/testsuite/go.test/test/fixedbugs/bug085.go
index 02be71753..93ae7e0a4 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug085.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug085.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug086.go b/gcc/testsuite/go.test/test/fixedbugs/bug086.go
index f96472fbb..fc69e0e3f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug086.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug086.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug087.go b/gcc/testsuite/go.test/test/fixedbugs/bug087.go
index 4af8d976f..67e7210cd 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug087.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug087.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: fails incorrectly
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug088.go b/gcc/testsuite/go.test/test/fixedbugs/bug088.go
index 9715a703c..3b99da84d 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug088.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug088.go
@@ -1,4 +1,4 @@
-// $G $D/$F.dir/bug0.go && $G $D/$F.dir/bug1.go || echo BUG: fails incorrectly
+// compiledir
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug089.go b/gcc/testsuite/go.test/test/fixedbugs/bug089.go
index fd3dff3ec..e88f17bab 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug089.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug089.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug090.go b/gcc/testsuite/go.test/test/fixedbugs/bug090.go
index 8318ab9c0..320bd57f5 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug090.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug090.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug091.go b/gcc/testsuite/go.test/test/fixedbugs/bug091.go
index c2ede7153..dbb1287a1 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug091.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug091.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug092.go b/gcc/testsuite/go.test/test/fixedbugs/bug092.go
index 8f05c478f..8027d941e 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug092.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug092.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug093.go b/gcc/testsuite/go.test/test/fixedbugs/bug093.go
index 52d92c7e3..acd94466f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug093.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug093.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: fails incorrectly
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug094.go b/gcc/testsuite/go.test/test/fixedbugs/bug094.go
index 2953eb28d..3ef11da3d 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug094.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug094.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: fails incorrectly
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug096.go b/gcc/testsuite/go.test/test/fixedbugs/bug096.go
index 9be687a7b..411ba74e0 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug096.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug096.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug097.go b/gcc/testsuite/go.test/test/fixedbugs/bug097.go
index ec3c21543..a067e0f57 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug097.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug097.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG wrong result
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug098.go b/gcc/testsuite/go.test/test/fixedbugs/bug098.go
index 1dad4d502..eb4ee4de0 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug098.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug098.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug099.go b/gcc/testsuite/go.test/test/fixedbugs/bug099.go
index f76f0e873..03a5c454b 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug099.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug099.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG should not crash
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug101.go b/gcc/testsuite/go.test/test/fixedbugs/bug101.go
index 92487deaa..82e496a8a 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug101.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug101.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug102.go b/gcc/testsuite/go.test/test/fixedbugs/bug102.go
index 1d97eb4a8..f1c2324b7 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug102.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug102.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: should not crash
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug103.go b/gcc/testsuite/go.test/test/fixedbugs/bug103.go
index b789be1c4..1cb710e36 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug103.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug103.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug104.go b/gcc/testsuite/go.test/test/fixedbugs/bug104.go
index dd4bb5834..f0c19a8aa 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug104.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug104.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug106.go b/gcc/testsuite/go.test/test/fixedbugs/bug106.go
index 1874b2044..3b99da84d 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug106.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug106.go
@@ -1,4 +1,4 @@
-// $G $D/$F.dir/bug0.go && $G $D/$F.dir/bug1.go || echo BUG: failed to compile
+// compiledir
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug107.go b/gcc/testsuite/go.test/test/fixedbugs/bug107.go
index 0554bbc8b..dcd8e9d11 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug107.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug107.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug108.go b/gcc/testsuite/go.test/test/fixedbugs/bug108.go
index 10e406de6..9f2a27ebd 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug108.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug108.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug109.go b/gcc/testsuite/go.test/test/fixedbugs/bug109.go
index 766657723..556dc34dd 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug109.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug109.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go || echo BUG: should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-package main
+package bug109
func f(a float64) float64 {
e := 1.0
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug110.go b/gcc/testsuite/go.test/test/fixedbugs/bug110.go
index 4e43d1c01..5528ba3f1 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug110.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug110.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A || echo BUG: const bug
+// build
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug111.go b/gcc/testsuite/go.test/test/fixedbugs/bug111.go
index e72b343ae..d977bd54f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug111.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug111.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG should compile and run
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug112.go b/gcc/testsuite/go.test/test/fixedbugs/bug112.go
index 3c932843c..e2ed5c0d4 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug112.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug112.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug113.go b/gcc/testsuite/go.test/test/fixedbugs/bug113.go
index 4ca07dc65..a1e61cb36 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug113.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug113.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug114.go b/gcc/testsuite/go.test/test/fixedbugs/bug114.go
index 974b7cf26..99e66a2dd 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug114.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug114.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && (./$A.out || echo BUG: bug114 failed)
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug115.go b/gcc/testsuite/go.test/test/fixedbugs/bug115.go
index 16b22d707..7cc3dc40a 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug115.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug115.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: bug115 should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug116.go b/gcc/testsuite/go.test/test/fixedbugs/bug116.go
index 42ca80343..5d8e52031 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug116.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug116.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug116
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug117.go b/gcc/testsuite/go.test/test/fixedbugs/bug117.go
index ad89ebf52..038826cbc 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug117.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug117.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug118.go b/gcc/testsuite/go.test/test/fixedbugs/bug118.go
index 1271f5b0c..198b8ff28 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug118.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug118.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go || echo BUG should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-package main
+package bug118
func Send(c chan int) int {
select {
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug119.go b/gcc/testsuite/go.test/test/fixedbugs/bug119.go
index 750507891..6f2514c24 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug119.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug119.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: should not fail
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug120.go b/gcc/testsuite/go.test/test/fixedbugs/bug120.go
index bf401bf30..58355e53d 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug120.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug120.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug120
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug121.go b/gcc/testsuite/go.test/test/fixedbugs/bug121.go
index 15c8451da..5adf9827f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug121.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug121.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug122.go b/gcc/testsuite/go.test/test/fixedbugs/bug122.go
index 72bf38a83..fb4eb9f3a 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug122.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug122.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug123.go b/gcc/testsuite/go.test/test/fixedbugs/bug123.go
index bdac67417..f38551a91 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug123.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug123.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug126.go b/gcc/testsuite/go.test/test/fixedbugs/bug126.go
index a8d56e122..f5d976341 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug126.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug126.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug127.go b/gcc/testsuite/go.test/test/fixedbugs/bug127.go
index 25b48114d..f8ea99470 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug127.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug127.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug128.go b/gcc/testsuite/go.test/test/fixedbugs/bug128.go
index 3fd647c00..e8cbea079 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug128.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug128.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: should compile
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug129.go b/gcc/testsuite/go.test/test/fixedbugs/bug129.go
index d1e2d8b56..157ce78ff 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug129.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug129.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG129
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug130.go b/gcc/testsuite/go.test/test/fixedbugs/bug130.go
index 855c7072b..16b029af3 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug130.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug130.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: should run
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug131.go b/gcc/testsuite/go.test/test/fixedbugs/bug131.go
index e5d4ca07d..0ebbd2606 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug131.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug131.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug132.go b/gcc/testsuite/go.test/test/fixedbugs/bug132.go
index bab8996f1..e334566c7 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug132.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug132.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug133.go b/gcc/testsuite/go.test/test/fixedbugs/bug133.go
index 2beeb074f..a6baac26c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug133.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug133.go
@@ -1,5 +1,8 @@
// $G $D/$F.dir/bug0.go && $G $D/$F.dir/bug1.go && errchk $G $D/$F.dir/bug2.go
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug135.go b/gcc/testsuite/go.test/test/fixedbugs/bug135.go
index 470135ed4..34d234e22 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug135.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug135.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug136.go b/gcc/testsuite/go.test/test/fixedbugs/bug136.go
index 7491b65d8..bea9bac08 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug136.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug136.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug137.go b/gcc/testsuite/go.test/test/fixedbugs/bug137.go
index 9d43f431b..48368177a 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug137.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug137.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug139.go b/gcc/testsuite/go.test/test/fixedbugs/bug139.go
index 2bdbef1c0..095e5c93c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug139.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug139.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug140.go b/gcc/testsuite/go.test/test/fixedbugs/bug140.go
index 441c57a48..8caf1d7d9 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug140.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug140.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug141.go b/gcc/testsuite/go.test/test/fixedbugs/bug141.go
index 1b125e5d1..81ba6f1b5 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug141.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug141.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: should run
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug142.go b/gcc/testsuite/go.test/test/fixedbugs/bug142.go
index e54458baf..e28d889a9 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug142.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug142.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug142
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug143.go b/gcc/testsuite/go.test/test/fixedbugs/bug143.go
index 2f575fcfe..a43e40667 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug143.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug143.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug144.go b/gcc/testsuite/go.test/test/fixedbugs/bug144.go
index bab9a4402..9f8ec7667 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug144.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug144.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug145.go b/gcc/testsuite/go.test/test/fixedbugs/bug145.go
index c59bcebd6..602fe7426 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug145.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug145.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug146.go b/gcc/testsuite/go.test/test/fixedbugs/bug146.go
index 16324c741..e29f910ba 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug146.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug146.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug147.go b/gcc/testsuite/go.test/test/fixedbugs/bug147.go
index a16630b87..e8b3d2439 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug147.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug147.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug147
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug148.go b/gcc/testsuite/go.test/test/fixedbugs/bug148.go
index 251020c96..b67870b12 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug148.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug148.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug149.go b/gcc/testsuite/go.test/test/fixedbugs/bug149.go
index a40403b7d..78b687e97 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug149.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug149.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug150.go b/gcc/testsuite/go.test/test/fixedbugs/bug150.go
index fc25444b6..b565ef73d 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug150.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug150.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go || echo BUG: bug150
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-package main
+package bug150
type T int
func (t T) M()
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug151.go b/gcc/testsuite/go.test/test/fixedbugs/bug151.go
index 46546dfe1..d9f5e021c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug151.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug151.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go || echo BUG: bug151
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-package main
+package bug151
type S string
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug1515.go b/gcc/testsuite/go.test/test/fixedbugs/bug1515.go
index 740252516..a4baccda7 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug1515.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug1515.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug152.go b/gcc/testsuite/go.test/test/fixedbugs/bug152.go
index 30c3cac91..45b9b3d53 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug152.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug152.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug154.go b/gcc/testsuite/go.test/test/fixedbugs/bug154.go
index 4371cc5ce..a2cfd4acc 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug154.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug154.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: should not panic
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug155.go b/gcc/testsuite/go.test/test/fixedbugs/bug155.go
index 312c8e6a9..8872e978d 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug155.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug155.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A || echo BUG: bug155
+// build
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug156.go b/gcc/testsuite/go.test/test/fixedbugs/bug156.go
index 0b77a72d9..f26658729 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug156.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug156.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: bug156
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug157.go b/gcc/testsuite/go.test/test/fixedbugs/bug157.go
index 9bf68f7a4..1072d7df4 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug157.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug157.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug158.go b/gcc/testsuite/go.test/test/fixedbugs/bug158.go
index cdf3195fe..496d7e0db 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug158.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug158.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug159.go b/gcc/testsuite/go.test/test/fixedbugs/bug159.go
index 1aa64433a..92d534563 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug159.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug159.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug159
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug160.go b/gcc/testsuite/go.test/test/fixedbugs/bug160.go
index 8fd53ea07..c5e166a0c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug160.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug160.go
@@ -1,5 +1,8 @@
// $G $D/bug160.dir/x.go && $G $D/bug160.dir/y.go && $L y.$A && ./$A.out
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug161.go b/gcc/testsuite/go.test/test/fixedbugs/bug161.go
index e5f25f746..aab58ee89 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug161.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug161.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug163.go b/gcc/testsuite/go.test/test/fixedbugs/bug163.go
index 919298e6f..d69f6bef0 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug163.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug163.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug164.go b/gcc/testsuite/go.test/test/fixedbugs/bug164.go
index 746f631ae..888b495ee 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug164.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug164.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug165.go b/gcc/testsuite/go.test/test/fixedbugs/bug165.go
index 8ce67a46d..f8d50af13 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug165.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug165.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug167.go b/gcc/testsuite/go.test/test/fixedbugs/bug167.go
index 33eb3cb1a..3a50e6ff0 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug167.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug167.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A || echo BUG: bug167
+// build
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug168.go b/gcc/testsuite/go.test/test/fixedbugs/bug168.go
index e25eb56b0..53301fa81 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug168.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug168.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug168
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug169.go b/gcc/testsuite/go.test/test/fixedbugs/bug169.go
index c42727f38..f63c2f3e1 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug169.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug169.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug170.go b/gcc/testsuite/go.test/test/fixedbugs/bug170.go
index e7f1c5120..11ff5ff3c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug170.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug170.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug171.go b/gcc/testsuite/go.test/test/fixedbugs/bug171.go
index 5357b2adc..49bbb3b89 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug171.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug171.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug172.go b/gcc/testsuite/go.test/test/fixedbugs/bug172.go
index 1837a1158..4dbe7930f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug172.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug172.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug173.go b/gcc/testsuite/go.test/test/fixedbugs/bug173.go
index 898b8400b..6479bb253 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug173.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug173.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: bug173
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug174.go b/gcc/testsuite/go.test/test/fixedbugs/bug174.go
index 7ff865513..448f63086 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug174.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug174.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: bug174
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug175.go b/gcc/testsuite/go.test/test/fixedbugs/bug175.go
index 1ca141507..5fca4b22b 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug175.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug175.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug176.go b/gcc/testsuite/go.test/test/fixedbugs/bug176.go
index 5820df308..82f8dba0a 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug176.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug176.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug177.go b/gcc/testsuite/go.test/test/fixedbugs/bug177.go
index a120ad0ab..9f2c1ea52 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug177.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug177.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug178.go b/gcc/testsuite/go.test/test/fixedbugs/bug178.go
index a7ff09dae..2bae5a1c5 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug178.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug178.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug179.go b/gcc/testsuite/go.test/test/fixedbugs/bug179.go
index 3347613d8..dea82fe0a 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug179.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug179.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug180.go b/gcc/testsuite/go.test/test/fixedbugs/bug180.go
index 96823fb3a..cfdcfab26 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug180.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug180.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug181.go b/gcc/testsuite/go.test/test/fixedbugs/bug181.go
index f87bc9d4e..4827e9cf0 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug181.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug181.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug182.go b/gcc/testsuite/go.test/test/fixedbugs/bug182.go
index 81df2ca13..e02dc59f8 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug182.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug182.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug183.go b/gcc/testsuite/go.test/test/fixedbugs/bug183.go
index 7fd6e4942..dc9f5356e 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug183.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug183.go
@@ -1,4 +1,4 @@
-//errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug184.go b/gcc/testsuite/go.test/test/fixedbugs/bug184.go
index 3cc984535..c084ea5cf 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug184.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug184.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug185.go b/gcc/testsuite/go.test/test/fixedbugs/bug185.go
index acae174f4..890900600 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug185.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug185.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug186.go b/gcc/testsuite/go.test/test/fixedbugs/bug186.go
index dde794a5d..5aefd7e5c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug186.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug186.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug187.go b/gcc/testsuite/go.test/test/fixedbugs/bug187.go
index 66aa5f024..5c3c2bb1e 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug187.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug187.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug188.go b/gcc/testsuite/go.test/test/fixedbugs/bug188.go
index e1cbce05d..550614789 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug188.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug188.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug189.go b/gcc/testsuite/go.test/test/fixedbugs/bug189.go
index ce338305c..9e412c66d 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug189.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug189.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug190.go b/gcc/testsuite/go.test/test/fixedbugs/bug190.go
index da0bfde0f..bb2d81cbb 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug190.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug190.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug191.go b/gcc/testsuite/go.test/test/fixedbugs/bug191.go
index 44fcccfc0..11a6e58e5 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug191.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug191.go
@@ -1,5 +1,8 @@
// $G $D/bug191.dir/a.go && $G $D/bug191.dir/b.go && $G $D/$F.go && $L $F.$A
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug192.go b/gcc/testsuite/go.test/test/fixedbugs/bug192.go
index 282ed30d3..679aaed1f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug192.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug192.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug193.go b/gcc/testsuite/go.test/test/fixedbugs/bug193.go
index 5ef02b1c1..64e06da89 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug193.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug193.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug194.go b/gcc/testsuite/go.test/test/fixedbugs/bug194.go
index dcd633dde..297652903 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug194.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug194.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG should compile and run
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug195.go b/gcc/testsuite/go.test/test/fixedbugs/bug195.go
index d8e112a3a..85367cb88 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug195.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug195.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug196.go b/gcc/testsuite/go.test/test/fixedbugs/bug196.go
index ea8ab0dc1..5255de189 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug196.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug196.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug196
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug197.go b/gcc/testsuite/go.test/test/fixedbugs/bug197.go
index c205c5bca..4a9f103ea 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug197.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug197.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug198.go b/gcc/testsuite/go.test/test/fixedbugs/bug198.go
index ea71fad58..73bb64688 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug198.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug198.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug199.go b/gcc/testsuite/go.test/test/fixedbugs/bug199.go
index 71226290f..f69f23b59 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug199.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug199.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug200.go b/gcc/testsuite/go.test/test/fixedbugs/bug200.go
index 63b8633bd..da628faf5 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug200.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug200.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug201.go b/gcc/testsuite/go.test/test/fixedbugs/bug201.go
index f7db62fc9..59248231a 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug201.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug201.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug202.go b/gcc/testsuite/go.test/test/fixedbugs/bug202.go
index 2fc91b520..49871e3e0 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug202.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug202.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG should run
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug203.go b/gcc/testsuite/go.test/test/fixedbugs/bug203.go
index bf86ee912..2fb084bd6 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug203.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug203.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug204.go b/gcc/testsuite/go.test/test/fixedbugs/bug204.go
index adf0aafd6..8810a5f92 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug204.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug204.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug205.go b/gcc/testsuite/go.test/test/fixedbugs/bug205.go
index e12be72f9..de17cb698 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug205.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug205.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug206.go b/gcc/testsuite/go.test/test/fixedbugs/bug206.go
index 7efc0b14a..c2382acf1 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug206.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug206.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out >/dev/null 2>&1 || echo BUG: bug206
+// cmpout
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug206.out b/gcc/testsuite/go.test/test/fixedbugs/bug206.out
new file mode 100644
index 000000000..aa47d0d46
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug206.out
@@ -0,0 +1,2 @@
+0
+0
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug207.go b/gcc/testsuite/go.test/test/fixedbugs/bug207.go
index 5810d6690..50923df1c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug207.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug207.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug208.go b/gcc/testsuite/go.test/test/fixedbugs/bug208.go
index 13b040084..09ec0afbe 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug208.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug208.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug209.go b/gcc/testsuite/go.test/test/fixedbugs/bug209.go
index ae6f10f60..52faf1fb9 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug209.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug209.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug211.go b/gcc/testsuite/go.test/test/fixedbugs/bug211.go
index 69aeeeeac..b15047927 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug211.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug211.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug212.go b/gcc/testsuite/go.test/test/fixedbugs/bug212.go
index 51df9b8ae..4e58b91ec 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug212.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug212.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug213.go b/gcc/testsuite/go.test/test/fixedbugs/bug213.go
index 4d81dbb4d..7f4786b52 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug213.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug213.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug214.go b/gcc/testsuite/go.test/test/fixedbugs/bug214.go
index 502e69826..5420058c4 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug214.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug214.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: bug214
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug215.go b/gcc/testsuite/go.test/test/fixedbugs/bug215.go
index 8f7fb2d3c..08ed662c6 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug215.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug215.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug216.go b/gcc/testsuite/go.test/test/fixedbugs/bug216.go
index 76f85464a..c83a522bf 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug216.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug216.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: bug216
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug217.go b/gcc/testsuite/go.test/test/fixedbugs/bug217.go
index 98334c4ce..ec93c25d9 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug217.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug217.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug218.go b/gcc/testsuite/go.test/test/fixedbugs/bug218.go
index b2c9ede75..0e008db17 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug218.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug218.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: bug218
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug219.go b/gcc/testsuite/go.test/test/fixedbugs/bug219.go
index 966d3fcf3..290c691ea 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug219.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug219.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go || echo BUG: bug219
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-package main
+package bug219
func f(func()) int { return 0 }
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug221.go b/gcc/testsuite/go.test/test/fixedbugs/bug221.go
index b64583114..86fda2035 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug221.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug221.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug222.dir/chanbug.go b/gcc/testsuite/go.test/test/fixedbugs/bug222.dir/chanbug.go
index 9194927b5..16920246e 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug222.dir/chanbug.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug222.dir/chanbug.go
@@ -1,3 +1,7 @@
+// Copyright 2009 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file
+
package chanbug
var C chan<- (chan int)
var D chan<- func()
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug222.dir/chanbug2.go b/gcc/testsuite/go.test/test/fixedbugs/bug222.dir/chanbug2.go
index 73e16678e..109581dc3 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug222.dir/chanbug2.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug222.dir/chanbug2.go
@@ -1,2 +1,6 @@
+// Copyright 2009 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file
+
package Bar
import _ "chanbug"
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug222.go b/gcc/testsuite/go.test/test/fixedbugs/bug222.go
index 5c23a533d..3b99da84d 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug222.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug222.go
@@ -1,4 +1,4 @@
-// $G $D/$F.dir/chanbug.go && $G -I. $D/$F.dir/chanbug2.go
+// compiledir
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug223.go b/gcc/testsuite/go.test/test/fixedbugs/bug223.go
index 80f9cae81..29ae53cb7 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug223.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug223.go
@@ -1,4 +1,4 @@
-// (! $G $D/$F.go) | grep 'initialization loop' >/dev/null || echo BUG: bug223
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
@@ -18,4 +18,4 @@ func f() {
}
}
-var m = map[string]F{"f": f}
+var m = map[string]F{"f": f} // ERROR "initialization loop|depends upon itself"
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug224.go b/gcc/testsuite/go.test/test/fixedbugs/bug224.go
index 11ee57ecf..d2fd67cf3 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug224.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug224.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug225.go b/gcc/testsuite/go.test/test/fixedbugs/bug225.go
index 8acf66c4e..1bda9ab4b 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug225.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug225.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug227.go b/gcc/testsuite/go.test/test/fixedbugs/bug227.go
index a60866044..ea8d02d10 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug227.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug227.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug228.go b/gcc/testsuite/go.test/test/fixedbugs/bug228.go
index da335dbc0..3d23609dd 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug228.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug228.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug229.go b/gcc/testsuite/go.test/test/fixedbugs/bug229.go
index a70a926da..19776881d 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug229.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug229.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug230.go b/gcc/testsuite/go.test/test/fixedbugs/bug230.go
index c7ad1a366..210acc430 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug230.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug230.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug231.go b/gcc/testsuite/go.test/test/fixedbugs/bug231.go
index 9500e582b..a9d409b7d 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug231.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug231.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug232.go b/gcc/testsuite/go.test/test/fixedbugs/bug232.go
index 99bd02ff6..d18727e90 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug232.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug232.go
@@ -1,8 +1,8 @@
-// $G $D/$F.go
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-package main
+package bug232
type I interface { X(...int) }
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug233.go b/gcc/testsuite/go.test/test/fixedbugs/bug233.go
index 31bb673eb..63f8ee2e9 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug233.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug233.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-package main
+package bug233
import p "fmt"
var _ = p.Print
var fmt = 10
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug234.go b/gcc/testsuite/go.test/test/fixedbugs/bug234.go
index 562109a05..9f503f04a 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug234.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug234.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug235.go b/gcc/testsuite/go.test/test/fixedbugs/bug235.go
index 8cecd9d04..d12d9e736 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug235.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug235.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
@@ -6,7 +6,7 @@
// used to crash the compiler
-package main
+package bug235
type T struct {
x [4]byte
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug236.go b/gcc/testsuite/go.test/test/fixedbugs/bug236.go
index 895f82a23..6c245565f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug236.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug236.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug237.go b/gcc/testsuite/go.test/test/fixedbugs/bug237.go
index 55cc86ace..58996cadc 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug237.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug237.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug238.go b/gcc/testsuite/go.test/test/fixedbugs/bug238.go
index 4d5a905f0..cc47189e1 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug238.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug238.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug239.go b/gcc/testsuite/go.test/test/fixedbugs/bug239.go
index 32c3d7e1c..e4902527d 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug239.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug239.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: bug239
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug240.go b/gcc/testsuite/go.test/test/fixedbugs/bug240.go
index 6cba9c8b1..478b5b2ea 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug240.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug240.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug241.go b/gcc/testsuite/go.test/test/fixedbugs/bug241.go
index 172b3742e..1f4440147 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug241.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug241.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug242.go b/gcc/testsuite/go.test/test/fixedbugs/bug242.go
index d80ae76a2..4791ae485 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug242.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug242.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: tuple evaluation order
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug243.go b/gcc/testsuite/go.test/test/fixedbugs/bug243.go
index e3ddf0e77..4870c3614 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug243.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug243.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug244.go b/gcc/testsuite/go.test/test/fixedbugs/bug244.go
index 915c3fcd0..29bf0d58b 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug244.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug244.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug245.go b/gcc/testsuite/go.test/test/fixedbugs/bug245.go
index 6e5a8b344..c607a6dc3 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug245.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug245.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: bug245
+// compile
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug246.go b/gcc/testsuite/go.test/test/fixedbugs/bug246.go
index 12041eb1d..e506f8c0d 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug246.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug246.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug246
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug247.go b/gcc/testsuite/go.test/test/fixedbugs/bug247.go
index 2f56b88d4..b6851e1bc 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug247.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug247.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug247
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug248.dir/bug0.go b/gcc/testsuite/go.test/test/fixedbugs/bug248.dir/bug0.go
index 7fc7401c5..78433f504 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug248.dir/bug0.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug248.dir/bug0.go
@@ -1,3 +1,7 @@
+// Copyright 2010 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file
+
package p
type T struct {
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug248.dir/bug1.go b/gcc/testsuite/go.test/test/fixedbugs/bug248.dir/bug1.go
index 7fc7401c5..78433f504 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug248.dir/bug1.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug248.dir/bug1.go
@@ -1,3 +1,7 @@
+// Copyright 2010 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file
+
package p
type T struct {
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug248.dir/bug2.go b/gcc/testsuite/go.test/test/fixedbugs/bug248.dir/bug2.go
index adce36677..ba547d64a 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug248.dir/bug2.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug248.dir/bug2.go
@@ -1,3 +1,7 @@
+// Copyright 2010 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file
+
package main
import (
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug248.dir/bug3.go b/gcc/testsuite/go.test/test/fixedbugs/bug248.dir/bug3.go
index e5a244955..4a56c5cc8 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug248.dir/bug3.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug248.dir/bug3.go
@@ -1,3 +1,7 @@
+// Copyright 2010 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file
+
package main
import (
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug248.go b/gcc/testsuite/go.test/test/fixedbugs/bug248.go
index 055bf1fd7..98cda35c4 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug248.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug248.go
@@ -5,6 +5,9 @@
// $L bug2.$A &&
// ./$A.out || echo BUG: failed to compile
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug249.go b/gcc/testsuite/go.test/test/fixedbugs/bug249.go
index c85708fd8..dc922455e 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug249.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug249.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug250.go b/gcc/testsuite/go.test/test/fixedbugs/bug250.go
index cd28642bf..5140f3e29 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug250.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug250.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go || echo BUG: bug250
+// compile
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-package main
+package bug250
type I1 interface {
m() I2
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug251.go b/gcc/testsuite/go.test/test/fixedbugs/bug251.go
index fb7b98a01..43d9d526f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug251.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug251.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
@@ -16,6 +16,6 @@ type I2 interface {
}
-var i1 I1 = i2 // GC_ERROR "missing m method|need type assertion"
+var i1 I1 = i2
var i2 I2
var i2a I2 = i1
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug252.go b/gcc/testsuite/go.test/test/fixedbugs/bug252.go
index a2c1dab9d..6f007fb77 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug252.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug252.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug253.go b/gcc/testsuite/go.test/test/fixedbugs/bug253.go
index bb5b770f5..f6ab712ef 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug253.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug253.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug253
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug254.go b/gcc/testsuite/go.test/test/fixedbugs/bug254.go
index c0c7f249e..9b1c81911 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug254.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug254.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug254
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug255.go b/gcc/testsuite/go.test/test/fixedbugs/bug255.go
index 44427cfdb..dbd41cc6a 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug255.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug255.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug256.go b/gcc/testsuite/go.test/test/fixedbugs/bug256.go
index 37fa5f5c8..0498a40d5 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug256.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug256.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug257.go b/gcc/testsuite/go.test/test/fixedbugs/bug257.go
index 1b3247500..003f3ff94 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug257.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug257.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bugxxx
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug258.go b/gcc/testsuite/go.test/test/fixedbugs/bug258.go
index 8984df592..d362e5a69 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug258.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug258.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug259.go b/gcc/testsuite/go.test/test/fixedbugs/bug259.go
index d148fb3a0..e4dcaeb2f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug259.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug259.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug260.go b/gcc/testsuite/go.test/test/fixedbugs/bug260.go
index 91dc89f77..6211c4885 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug260.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug260.go
@@ -1,4 +1,8 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug260 failed
+// run
+
+// Copyright 2010 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file
// Test that structures pack densely, according to the alignment of the largest field.
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug261.go b/gcc/testsuite/go.test/test/fixedbugs/bug261.go
index 8c3fda1e7..f7879b04c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug261.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug261.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug262.go b/gcc/testsuite/go.test/test/fixedbugs/bug262.go
index ebca7905f..6cf248a18 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug262.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug262.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug263.go b/gcc/testsuite/go.test/test/fixedbugs/bug263.go
index cab986ad5..f1cf9010d 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug263.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug263.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug264.go b/gcc/testsuite/go.test/test/fixedbugs/bug264.go
index 6d86c6fe5..fcf373cce 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug264.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug264.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug265.go b/gcc/testsuite/go.test/test/fixedbugs/bug265.go
index 55f32ecec..7f06fced6 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug265.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug265.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug266.go b/gcc/testsuite/go.test/test/fixedbugs/bug266.go
index 25c246f7d..d4da891d3 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug266.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug266.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug266
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug267.go b/gcc/testsuite/go.test/test/fixedbugs/bug267.go
index 9646142f2..cf8bf841f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug267.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug267.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go || echo BUG
+// compile
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-package main
+package bug267
type T []int
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug269.go b/gcc/testsuite/go.test/test/fixedbugs/bug269.go
index 4cc0408c3..c13eb26ce 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug269.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug269.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug271.go b/gcc/testsuite/go.test/test/fixedbugs/bug271.go
index ba93d93ed..88add7040 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug271.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug271.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug272.go b/gcc/testsuite/go.test/test/fixedbugs/bug272.go
index 3b7c46674..c27f7ee44 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug272.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug272.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug273.go b/gcc/testsuite/go.test/test/fixedbugs/bug273.go
index dd5aaa7b8..c5e73e945 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug273.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug273.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
@@ -8,14 +8,14 @@
package main
-import "unsafe"
-
var bug = false
var minus1 = -1
var big int64 = 10 | 1<<32
-var g1 []int
+type block [1<<19]byte
+
+var g1 []block
func shouldfail(f func(), desc string) {
defer func() { recover() }()
@@ -28,55 +28,47 @@ func shouldfail(f func(), desc string) {
}
func badlen() {
- g1 = make([]int, minus1)
+ g1 = make([]block, minus1)
}
func biglen() {
- g1 = make([]int, big)
+ g1 = make([]block, big)
}
func badcap() {
- g1 = make([]int, 10, minus1)
+ g1 = make([]block, 10, minus1)
}
func badcap1() {
- g1 = make([]int, 10, 5)
+ g1 = make([]block, 10, 5)
}
func bigcap() {
- g1 = make([]int, 10, big)
+ g1 = make([]block, 10, big)
}
-var g3 map[int]int
+var g3 map[block]block
func badmapcap() {
- g3 = make(map[int]int, minus1)
+ g3 = make(map[block]block, minus1)
}
func bigmapcap() {
- g3 = make(map[int]int, big)
+ g3 = make(map[block]block, big)
}
-var g4 chan int
+type cblock [1<<16-1]byte
+
+var g4 chan cblock
func badchancap() {
- g4 = make(chan int, minus1)
+ g4 = make(chan cblock, minus1)
}
func bigchancap() {
- g4 = make(chan int, big)
+ g4 = make(chan cblock, big)
}
-const addrBits = unsafe.Sizeof((*byte)(nil))
-
-var g5 chan [1<<15]byte
func overflowchan() {
- if addrBits == 32 {
- g5 = make(chan [1<<15]byte, 1<<20)
- } else {
- // cannot overflow on 64-bit, because
- // int is 32 bits and max chan value size
- // in the implementation is 64 kB.
- panic(1)
- }
+ g4 = make(chan cblock, 1<<30)
}
func main() {
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug274.go b/gcc/testsuite/go.test/test/fixedbugs/bug274.go
index 198544c3f..beb2d61ac 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug274.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug274.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug275.go b/gcc/testsuite/go.test/test/fixedbugs/bug275.go
index 2bbc807c5..f5f6b14f0 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug275.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug275.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG should compile
+// compile
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug276.go b/gcc/testsuite/go.test/test/fixedbugs/bug276.go
index 844a6b238..dc2308ea6 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug276.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug276.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG code should run
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug277.go b/gcc/testsuite/go.test/test/fixedbugs/bug277.go
index 22b2908c9..207556493 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug277.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug277.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG should compile
+// compile
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug278.go b/gcc/testsuite/go.test/test/fixedbugs/bug278.go
index 3699b9a14..68a3d811c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug278.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug278.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug279.go b/gcc/testsuite/go.test/test/fixedbugs/bug279.go
index af8e056d9..e5ec5943c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug279.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug279.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug280.go b/gcc/testsuite/go.test/test/fixedbugs/bug280.go
index 869d44626..ba594a2c4 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug280.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug280.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug281.go b/gcc/testsuite/go.test/test/fixedbugs/bug281.go
index 821b02825..24d6fdce8 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug281.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug281.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug282.go b/gcc/testsuite/go.test/test/fixedbugs/bug282.go
index 463f21e94..3b99da84d 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug282.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug282.go
@@ -1,4 +1,4 @@
-// $G $D/$F.dir/p1.go && $G $D/$F.dir/p2.go
+// compiledir
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug283.go b/gcc/testsuite/go.test/test/fixedbugs/bug283.go
index 45ee9082f..eefed0334 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug283.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug283.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: should compile
+// compile
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
@@ -7,7 +7,7 @@
// http://code.google.com/p/go/issues/detail?id=806
// triggered out of registers on 8g
-package main
+package bug283
type Point struct {
x int
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug284.go b/gcc/testsuite/go.test/test/fixedbugs/bug284.go
index bcf161e3d..68208085f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug284.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug284.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug285.go b/gcc/testsuite/go.test/test/fixedbugs/bug285.go
index 7eed8fb7a..0a8a0f09e 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug285.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug285.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug285
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug286.go b/gcc/testsuite/go.test/test/fixedbugs/bug286.go
index eb6783856..44f05153f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug286.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug286.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug286 failed
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug287.go b/gcc/testsuite/go.test/test/fixedbugs/bug287.go
index a4a08eedc..2ed81c593 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug287.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug287.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug288.go b/gcc/testsuite/go.test/test/fixedbugs/bug288.go
index 0105159d1..d2461e6a9 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug288.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug288.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go
+// compile
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug289.go b/gcc/testsuite/go.test/test/fixedbugs/bug289.go
index f7180ff04..3c6b68767 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug289.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug289.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug290.go b/gcc/testsuite/go.test/test/fixedbugs/bug290.go
index 80437c7f8..c8ff0bc45 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug290.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug290.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug291.go b/gcc/testsuite/go.test/test/fixedbugs/bug291.go
index 09334c921..17a5483ef 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug291.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug291.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug292.go b/gcc/testsuite/go.test/test/fixedbugs/bug292.go
index 05852cd46..07051dd3f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug292.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug292.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug293.go b/gcc/testsuite/go.test/test/fixedbugs/bug293.go
index ca9b71a3a..bf926f5a4 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug293.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug293.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug294.go b/gcc/testsuite/go.test/test/fixedbugs/bug294.go
index 18f45931c..0f3e38098 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug294.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug294.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug295.go b/gcc/testsuite/go.test/test/fixedbugs/bug295.go
index fec2351f3..e2e5206ca 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug295.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug295.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug296.go b/gcc/testsuite/go.test/test/fixedbugs/bug296.go
index 46d8dbcfe..a7c4e0c46 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug296.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug296.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug297.go b/gcc/testsuite/go.test/test/fixedbugs/bug297.go
index 8767cdfea..b5dfa8d87 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug297.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug297.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug298.go b/gcc/testsuite/go.test/test/fixedbugs/bug298.go
index c16c3f98a..bd362ace2 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug298.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug298.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug299.go b/gcc/testsuite/go.test/test/fixedbugs/bug299.go
index 1c7adb5f5..9646723bf 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug299.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug299.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug300.go b/gcc/testsuite/go.test/test/fixedbugs/bug300.go
index 09ee3ab69..1ef43a0ad 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug300.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug300.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug301.go b/gcc/testsuite/go.test/test/fixedbugs/bug301.go
index a58f4e13b..572668f19 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug301.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug301.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: bug301.go
+// compile
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug302.go b/gcc/testsuite/go.test/test/fixedbugs/bug302.go
index e9edb94ac..dc7637fe5 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug302.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug302.go
@@ -1,4 +1,7 @@
-// $G $D/bug302.dir/p.go && gopack grc pp.a p.$A && $G $D/bug302.dir/main.go
+// $G $D/bug302.dir/p.go && pack grc pp.a p.$A && $G $D/bug302.dir/main.go
+
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug303.go b/gcc/testsuite/go.test/test/fixedbugs/bug303.go
index 3bd790f13..94ca07e70 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug303.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug303.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug304.go b/gcc/testsuite/go.test/test/fixedbugs/bug304.go
index adcf08a35..ad71b20f3 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug304.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug304.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go
+// compile
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug305.go b/gcc/testsuite/go.test/test/fixedbugs/bug305.go
index 758fee269..d0a4b24b8 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug305.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug305.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug306.go b/gcc/testsuite/go.test/test/fixedbugs/bug306.go
index a0a43507d..e8967c25d 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug306.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug306.go
@@ -1,4 +1,4 @@
-// $G $D/$F.dir/p1.go && $G $D/$F.dir/p2.go
+// compiledir
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug307.go b/gcc/testsuite/go.test/test/fixedbugs/bug307.go
index 1b42c09ab..644512529 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug307.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug307.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go
+// compile
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug308.go b/gcc/testsuite/go.test/test/fixedbugs/bug308.go
index c2845f042..5bea5175b 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug308.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug308.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go
+// compile
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug309.go b/gcc/testsuite/go.test/test/fixedbugs/bug309.go
index d893916cd..948ca5c79 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug309.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug309.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go
+// compile
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
@@ -6,7 +6,7 @@
// issue 1016
-package main
+package bug309
func foo(t interface{}, c chan int) {
switch v := t.(type) {
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug311.go b/gcc/testsuite/go.test/test/fixedbugs/bug311.go
index ed937a674..edcd97596 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug311.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug311.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug312.go b/gcc/testsuite/go.test/test/fixedbugs/bug312.go
index 70888dd41..c7c17e101 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug312.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug312.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug313.go b/gcc/testsuite/go.test/test/fixedbugs/bug313.go
index eb2a0223b..9009c5e8f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug313.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug313.go
@@ -1,5 +1,8 @@
// errchk $G -e $D/$F.dir/[ab].go
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug314.go b/gcc/testsuite/go.test/test/fixedbugs/bug314.go
index 95d81d795..6e26d14e1 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug314.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug314.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug314
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug315.go b/gcc/testsuite/go.test/test/fixedbugs/bug315.go
index c59ef29e6..7b8a9e570 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug315.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug315.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: bug315
+// compile
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug316.go b/gcc/testsuite/go.test/test/fixedbugs/bug316.go
index 2146408a1..e1374122d 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug316.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug316.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: bug316
+// compile
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug317.go b/gcc/testsuite/go.test/test/fixedbugs/bug317.go
index 0cb26c29b..3ff4dc465 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug317.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug317.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug317
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug318.go b/gcc/testsuite/go.test/test/fixedbugs/bug318.go
index 9c46a0426..93de2d847 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug318.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug318.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug319.go b/gcc/testsuite/go.test/test/fixedbugs/bug319.go
index f60eee4fb..f8e959a31 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug319.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug319.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go
+// compile
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug320.go b/gcc/testsuite/go.test/test/fixedbugs/bug320.go
index 06d41f2ed..c2dd31b81 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug320.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug320.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug321.go b/gcc/testsuite/go.test/test/fixedbugs/bug321.go
index d0595ff59..7d018271f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug321.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug321.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug321
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug322.go b/gcc/testsuite/go.test/test/fixedbugs/bug322.go
index ad0e62dc8..401a8600a 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug322.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug322.go
@@ -1,5 +1,8 @@
// $G $D/$F.dir/lib.go && $G $D/$F.dir/main.go && $L main.$A && ./$A.out || echo BUG: fails incorrectly
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug323.go b/gcc/testsuite/go.test/test/fixedbugs/bug323.go
index 23e2be660..9730ae5c8 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug323.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug323.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug324.go b/gcc/testsuite/go.test/test/fixedbugs/bug324.go
index 3da75630a..ee090ae42 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug324.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug324.go
@@ -1,5 +1,8 @@
// $G $D/$F.dir/p.go && $G $D/$F.dir/main.go && $L main.$A && ./$A.out
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug325.go b/gcc/testsuite/go.test/test/fixedbugs/bug325.go
index b86740fff..6ccd0e3c8 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug325.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug325.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug326.go b/gcc/testsuite/go.test/test/fixedbugs/bug326.go
index 7e123e3a3..57f6471dc 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug326.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug326.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug327.go b/gcc/testsuite/go.test/test/fixedbugs/bug327.go
index 4ba5f6072..0598d95d6 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug327.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug327.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug328.go b/gcc/testsuite/go.test/test/fixedbugs/bug328.go
index 825298371..73ab46d45 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug328.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug328.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out 2>&1 | cmp - $D/$F.out
+// cmpout
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug329.go b/gcc/testsuite/go.test/test/fixedbugs/bug329.go
index 0b7074d62..74fc78198 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug329.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug329.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug330.go b/gcc/testsuite/go.test/test/fixedbugs/bug330.go
index 114492aff..ef6a0777f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug330.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug330.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug331.go b/gcc/testsuite/go.test/test/fixedbugs/bug331.go
index 6c5acd1f4..fac0e3628 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug331.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug331.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug331
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug332.go b/gcc/testsuite/go.test/test/fixedbugs/bug332.go
index be79286b8..702779ba6 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug332.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug332.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug333.go b/gcc/testsuite/go.test/test/fixedbugs/bug333.go
index 515c1f3fa..bb690f0e5 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug333.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug333.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug334.go b/gcc/testsuite/go.test/test/fixedbugs/bug334.go
index 870c9ae24..bd671696b 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug334.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug334.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: bug334
+// compile
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug335.dir/a.go b/gcc/testsuite/go.test/test/fixedbugs/bug335.dir/a.go
index 5a8112a9d..256c110d7 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug335.dir/a.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug335.dir/a.go
@@ -4,6 +4,8 @@
package a
-import "./b"
+type T interface{}
-var Bar = b.Foo
+func f() T { return nil }
+
+var Foo T = f()
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug335.dir/b.go b/gcc/testsuite/go.test/test/fixedbugs/bug335.dir/b.go
index 7428c2a91..1474470d4 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug335.dir/b.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug335.dir/b.go
@@ -4,8 +4,6 @@
package b
-type T interface{}
+import "./a"
-func f() T { return nil }
-
-var Foo T = f()
+var Bar = a.Foo
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug335.go b/gcc/testsuite/go.test/test/fixedbugs/bug335.go
index 915b74657..37c97d7b5 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug335.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug335.go
@@ -1,5 +1,4 @@
-// $G $D/$F.dir/b.go && $G $D/$F.dir/a.go
-// rm -f a.$A b.$A
+// compiledir
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
@@ -7,4 +6,4 @@
// Issue 1705.
-unused (see script at top of file)
+package ignored
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug336.go b/gcc/testsuite/go.test/test/fixedbugs/bug336.go
index 8de36898f..fbf23207c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug336.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug336.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug337.go b/gcc/testsuite/go.test/test/fixedbugs/bug337.go
index ca9b4b453..38dc665fa 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug337.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug337.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug338.go b/gcc/testsuite/go.test/test/fixedbugs/bug338.go
index c368a7fad..c2193fcc2 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug338.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug338.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go
+// compile
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug339.go b/gcc/testsuite/go.test/test/fixedbugs/bug339.go
index eac7c5ee6..59921d41c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug339.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug339.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug340.go b/gcc/testsuite/go.test/test/fixedbugs/bug340.go
index 34cc01315..d996ab64c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug340.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug340.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug341.go b/gcc/testsuite/go.test/test/fixedbugs/bug341.go
index 8ee52e1ef..db1af3eaa 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug341.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug341.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug341
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug342.go b/gcc/testsuite/go.test/test/fixedbugs/bug342.go
index 0852cdd34..5f1efbdfe 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug342.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug342.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug343.go b/gcc/testsuite/go.test/test/fixedbugs/bug343.go
index efc87e3d7..82201088b 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug343.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug343.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug343
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug344.go b/gcc/testsuite/go.test/test/fixedbugs/bug344.go
index ce953f7f2..4a92624c7 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug344.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug344.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug345.go b/gcc/testsuite/go.test/test/fixedbugs/bug345.go
index 874710ce8..e3705f6c1 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug345.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug345.go
@@ -1,5 +1,8 @@
// $G $D/$F.dir/io.go && errchk $G -e $D/$F.dir/main.go
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug346.go b/gcc/testsuite/go.test/test/fixedbugs/bug346.go
index 31284c31a..d9203aa43 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug346.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug346.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: issue2056
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug347.go b/gcc/testsuite/go.test/test/fixedbugs/bug347.go
index 5532cee83..08edf0f4f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug347.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug347.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug348.go b/gcc/testsuite/go.test/test/fixedbugs/bug348.go
index 1a539aa3e..54a289a8d 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug348.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug348.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug349.go b/gcc/testsuite/go.test/test/fixedbugs/bug349.go
index e7612edb7..a3e6bd161 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug349.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug349.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug350.go b/gcc/testsuite/go.test/test/fixedbugs/bug350.go
index f8df3f58b..5ce8996ff 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug350.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug350.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug351.go b/gcc/testsuite/go.test/test/fixedbugs/bug351.go
index 9625c6a50..4c5c7c327 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug351.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug351.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug352.go b/gcc/testsuite/go.test/test/fixedbugs/bug352.go
index 62fd006c4..1ae2d6139 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug352.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug352.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug352
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug353.go b/gcc/testsuite/go.test/test/fixedbugs/bug353.go
index b59d97f33..2a532c491 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug353.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug353.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug354.go b/gcc/testsuite/go.test/test/fixedbugs/bug354.go
index a95256e27..1245d91f5 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug354.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug354.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: bug354
+// compile
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
@@ -7,7 +7,7 @@
// issue 2086
// was calling makeclosure twice on the closure
-package main
+package bug354
type Inner struct {
F func() error
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug355.go b/gcc/testsuite/go.test/test/fixedbugs/bug355.go
index a9cf0161b..fcf859b7f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug355.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug355.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug356.go b/gcc/testsuite/go.test/test/fixedbugs/bug356.go
index d21f0cfac..273c5b8ef 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug356.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug356.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug344
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug357.go b/gcc/testsuite/go.test/test/fixedbugs/bug357.go
index 448d98263..2ac64a80b 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug357.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug357.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug358.go b/gcc/testsuite/go.test/test/fixedbugs/bug358.go
index 82fbf7f81..6a008484f 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug358.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug358.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug361.go b/gcc/testsuite/go.test/test/fixedbugs/bug361.go
index d2a64bcef..3e3b7c181 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug361.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug361.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: bug360
+// compile
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug362.go b/gcc/testsuite/go.test/test/fixedbugs/bug362.go
index f38572c0d..b888ccb44 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug362.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug362.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug363.go b/gcc/testsuite/go.test/test/fixedbugs/bug363.go
index 9347ec28b..615c66865 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug363.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug363.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug364.go b/gcc/testsuite/go.test/test/fixedbugs/bug364.go
index a93312107..64120d164 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug364.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug364.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug365.go b/gcc/testsuite/go.test/test/fixedbugs/bug365.go
index bc8c2c5e6..795323bb3 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug365.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug365.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug366.go b/gcc/testsuite/go.test/test/fixedbugs/bug366.go
index 8c000f50a..33a1a5a7e 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug366.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug366.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug367.dir/main.go b/gcc/testsuite/go.test/test/fixedbugs/bug367.dir/main.go
index 21e9a5002..c278e4dd9 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug367.dir/main.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug367.dir/main.go
@@ -1,3 +1,7 @@
+// Copyright 2011 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file
+
package main
import (
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug367.dir/p.go b/gcc/testsuite/go.test/test/fixedbugs/bug367.dir/p.go
index c8772d2d0..2028f740c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug367.dir/p.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug367.dir/p.go
@@ -1,3 +1,7 @@
+// Copyright 2011 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file
+
package p
type T struct{ x int }
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug367.go b/gcc/testsuite/go.test/test/fixedbugs/bug367.go
index 25d11a153..bf8edcd1b 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug367.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug367.go
@@ -1,5 +1,8 @@
// $G $D/$F.dir/p.go && $G $D/$F.dir/main.go && $L main.$A && ./$A.out || echo BUG: should not fail
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug368.go b/gcc/testsuite/go.test/test/fixedbugs/bug368.go
index 8d94f531c..c38cc7fad 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug368.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug368.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug369.go b/gcc/testsuite/go.test/test/fixedbugs/bug369.go
index 8eb23eecf..2ee8568e0 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug369.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug369.go
@@ -1,6 +1,9 @@
// $G -N -o slow.$A $D/bug369.dir/pkg.go &&
// $G -o fast.$A $D/bug369.dir/pkg.go &&
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
+
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug370.go b/gcc/testsuite/go.test/test/fixedbugs/bug370.go
index 9cb45f6e0..246bc7c4e 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug370.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug370.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug371.go b/gcc/testsuite/go.test/test/fixedbugs/bug371.go
index bf993df06..6329e9635 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug371.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug371.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug372.go b/gcc/testsuite/go.test/test/fixedbugs/bug372.go
index a6f7208bb..34578565a 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug372.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug372.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug372
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug373.go b/gcc/testsuite/go.test/test/fixedbugs/bug373.go
index 934a6c732..e91f26d6e 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug373.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug373.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug374.go b/gcc/testsuite/go.test/test/fixedbugs/bug374.go
index b55c5df45..4f0b721f2 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug374.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug374.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug375.go b/gcc/testsuite/go.test/test/fixedbugs/bug375.go
index 527358526..cb159b0d6 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug375.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug375.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug375
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug376.go b/gcc/testsuite/go.test/test/fixedbugs/bug376.go
index 1efbeecf2..5fbbc9cd4 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug376.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug376.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug377.dir/one.go b/gcc/testsuite/go.test/test/fixedbugs/bug377.dir/one.go
index c9060756b..e29b813a4 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug377.dir/one.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug377.dir/one.go
@@ -1,3 +1,7 @@
+// Copyright 2011 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file
+
package one
func Foo() (n int64, _ *int) {
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug377.dir/two.go b/gcc/testsuite/go.test/test/fixedbugs/bug377.dir/two.go
index 8a5346ab7..2a10812d5 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug377.dir/two.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug377.dir/two.go
@@ -1,3 +1,7 @@
+// Copyright 2011 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file
+
package two
import _ "./one"
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug377.go b/gcc/testsuite/go.test/test/fixedbugs/bug377.go
index e905e34d6..22df005b2 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug377.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug377.go
@@ -1,4 +1,4 @@
-// $G $D/$F.dir/one.go && $G $D/$F.dir/two.go
+// compiledir
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug378.go b/gcc/testsuite/go.test/test/fixedbugs/bug378.go
index b393b3dc1..f3346c648 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug378.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug378.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: bug378
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug379.go b/gcc/testsuite/go.test/test/fixedbugs/bug379.go
index 3dd3d2983..81e9c266e 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug379.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug379.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug380.go b/gcc/testsuite/go.test/test/fixedbugs/bug380.go
index 75b58064f..96e1edeca 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug380.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug380.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go
+// compile
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug381.go b/gcc/testsuite/go.test/test/fixedbugs/bug381.go
index 3f3232bf1..0253e1446 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug381.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug381.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
@@ -7,14 +7,25 @@
// Issue 2276.
// Check that the error messages says
-// bug378.go:19: unsafe.Alignof(0) not used
+// bug381.go:29: unsafe.Alignof(0) not used
// and not
-// bug378.go:19: 4 not used
+// bug381.go:29: 4 not used
+
+// Issue 2768: previously got
+// bug381.go:30: cannot use 3 (type time.Weekday) as type int in function argument
+// want
+// bug381.go:30: cannot use time.Wednesday (type time.Weekday) as type int in function argument
package main
-import "unsafe"
+import (
+ "time"
+ "unsafe"
+)
+
+func f(int)
func main() {
unsafe.Alignof(0) // ERROR "unsafe\.Alignof|value computed is not used"
+ f(time.Wednesday) // ERROR "time.Wednesday|incompatible type"
}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug382.go b/gcc/testsuite/go.test/test/fixedbugs/bug382.go
index 6212fbf50..10c71d466 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug382.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug382.go
@@ -1,5 +1,12 @@
// $G $D/$F.dir/pkg.go && $G $D/$F.go || echo "Bug 382"
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
+// Copyright 2011 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file
+
// Issue 2529
package main
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug383.go b/gcc/testsuite/go.test/test/fixedbugs/bug383.go
index 181a897b6..503779c37 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug383.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug383.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug384.go b/gcc/testsuite/go.test/test/fixedbugs/bug384.go
index b3d646688..0233c197c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug384.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug384.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug385_32.go b/gcc/testsuite/go.test/test/fixedbugs/bug385_32.go
index a009f664e..5ac4136e7 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug385_32.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug385_32.go
@@ -1,4 +1,7 @@
-// [ $O == 6 ] || errchk $G -e $D/$F.go
+// [ $A == 6 ] || errchk $G -e $D/$F.go
+
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug385_64.go b/gcc/testsuite/go.test/test/fixedbugs/bug385_64.go
index 701be0d09..8c7b9d520 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug385_64.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug385_64.go
@@ -1,4 +1,7 @@
-// [ $O != 6 ] || errchk $G -e $D/$F.go
+// [ $A != 6 ] || errchk $G -e $D/$F.go
+
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
@@ -8,7 +11,7 @@
package main
func main() { // ERROR "stack frame too large"
- var arr [1000200030]int
+ var arr [1000200030]int32
arr_bkup := arr
_ = arr_bkup
}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug386.go b/gcc/testsuite/go.test/test/fixedbugs/bug386.go
index b42c07073..ec358bd36 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug386.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug386.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug387.go b/gcc/testsuite/go.test/test/fixedbugs/bug387.go
index c9db4aea8..59d5ef903 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug387.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug387.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo "Bug387"
+// compile
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug388.go b/gcc/testsuite/go.test/test/fixedbugs/bug388.go
index c17fd7ca2..d41f9ea54 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug388.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug388.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug389.go b/gcc/testsuite/go.test/test/fixedbugs/bug389.go
index ecbbbdd58..55a02e05c 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug389.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug389.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug390.go b/gcc/testsuite/go.test/test/fixedbugs/bug390.go
index 31c4dd40b..7ce9e1370 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug390.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug390.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug391.go b/gcc/testsuite/go.test/test/fixedbugs/bug391.go
index 81507188b..07d129ddc 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug391.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug391.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo "Issue2576"
+// compile
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug392.dir/one.go b/gcc/testsuite/go.test/test/fixedbugs/bug392.dir/one.go
index a7017255e..8242f2846 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug392.dir/one.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug392.dir/one.go
@@ -20,3 +20,24 @@ func F3() (ret []int) { return append(ret, 1) }
// Call of inlined method with blank receiver.
func (_ *T) M() int { return 1 }
func (t *T) MM() int { return t.M() }
+
+
+// One more like issue 2678
+type S struct { x, y int }
+type U []S
+
+func F4(S int) U { return U{{S,S}} }
+
+func F5() []*S {
+ return []*S{ {1,2}, { 3, 4} }
+}
+
+func F6(S int) *U {
+ return &U{{S,S}}
+}
+
+// Bug in the fix.
+
+type PB struct { x int }
+
+func (t *PB) Reset() { *t = PB{} }
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug392.dir/two.go b/gcc/testsuite/go.test/test/fixedbugs/bug392.dir/pkg2.go
index b0ce26d39..8320b2fff 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug392.dir/two.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug392.dir/pkg2.go
@@ -5,7 +5,7 @@
// Use the functions in one.go so that the inlined
// forms get type-checked.
-package two
+package pkg2
import "./one"
@@ -13,8 +13,13 @@ func use() {
one.F1(nil)
one.F2(nil)
one.F3()
+ one.F4(1)
var t *one.T
t.M()
t.MM()
}
+
+var V = []one.PB{{}, {}}
+
+func F() *one.PB
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug392.dir/pkg3.go b/gcc/testsuite/go.test/test/fixedbugs/bug392.dir/pkg3.go
new file mode 100644
index 000000000..402c3b083
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug392.dir/pkg3.go
@@ -0,0 +1,13 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Use the functions in pkg2.go so that the inlined
+// forms get type-checked.
+
+package pkg3
+
+import "./pkg2"
+
+var x = pkg2.F()
+var v = pkg2.V
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug392.go b/gcc/testsuite/go.test/test/fixedbugs/bug392.go
index 50af6006f..48b79e01b 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug392.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug392.go
@@ -1,4 +1,4 @@
-// $G $D/$F.dir/one.go && $G $D/$F.dir/two.go
+// compiledir
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug393.go b/gcc/testsuite/go.test/test/fixedbugs/bug393.go
index e21b9c4a4..f8a9c6578 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug393.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug393.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: bug393
+// compile
// Copyright 2012 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
@@ -7,7 +7,7 @@
// issue 2672
// was trying binary search with an interface type
-package main
+package bug393
func f(x interface{}) int {
switch x {
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug394.go b/gcc/testsuite/go.test/test/fixedbugs/bug394.go
index 42c20e7a9..2d77156c1 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug394.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug394.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug396.dir/one.go b/gcc/testsuite/go.test/test/fixedbugs/bug396.dir/one.go
index 7902a07d5..96a1dd7dc 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug396.dir/one.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug396.dir/one.go
@@ -4,6 +4,7 @@
package one
+// Issue 2687
type T struct { int }
func New(i int) T { return T{i} }
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug396.go b/gcc/testsuite/go.test/test/fixedbugs/bug396.go
index 50af6006f..48b79e01b 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug396.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug396.go
@@ -1,4 +1,4 @@
-// $G $D/$F.dir/one.go && $G $D/$F.dir/two.go
+// compiledir
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug397.go b/gcc/testsuite/go.test/test/fixedbugs/bug397.go
index 039570130..56cc7cdd4 100644
--- a/gcc/testsuite/go.test/test/fixedbugs/bug397.go
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug397.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug398.go b/gcc/testsuite/go.test/test/fixedbugs/bug398.go
new file mode 100644
index 000000000..1dd3fa421
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug398.go
@@ -0,0 +1,24 @@
+// compile
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Used to crash compiler in interface type equality check.
+
+package p
+
+type I1 interface {
+ F() interface{I1}
+}
+
+type I2 interface {
+ F() interface{I2}
+}
+
+var v1 I1
+var v2 I2
+
+func f() bool {
+ return v1 == v2
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug399.go b/gcc/testsuite/go.test/test/fixedbugs/bug399.go
new file mode 100644
index 000000000..94852c9ee
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug399.go
@@ -0,0 +1,15 @@
+// compile
+
+// Copyright 2011 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Issue 2674
+
+package main
+const dow = "\000\003"
+
+func main() {
+ println(int(dow[1]))
+}
+
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug401.go b/gcc/testsuite/go.test/test/fixedbugs/bug401.go
new file mode 100644
index 000000000..5589b5b1b
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug401.go
@@ -0,0 +1,46 @@
+// run
+
+// Copyright 2011 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Issue 2582
+package main
+
+type T struct{}
+
+func (T) cplx() complex128 {
+ for false {
+ } // avoid inlining
+ return complex(1, 0)
+}
+
+func (T) cplx2() complex128 {
+ return complex(0, 1)
+}
+
+type I interface {
+ cplx() complex128
+}
+
+func main() {
+
+ var t T
+
+ if v := real(t.cplx()); v != 1 {
+ panic("not-inlined complex call failed")
+ }
+ _ = imag(t.cplx())
+
+ _ = real(t.cplx2())
+ if v := imag(t.cplx2()); v != 1 {
+ panic("potentially inlined complex call failed")
+ }
+
+ var i I
+ i = t
+ if v := real(i.cplx()); v != 1 {
+ panic("potentially inlined complex call failed")
+ }
+ _ = imag(i.cplx())
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug402.go b/gcc/testsuite/go.test/test/fixedbugs/bug402.go
new file mode 100644
index 000000000..db3f3da44
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug402.go
@@ -0,0 +1,31 @@
+// run
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package main
+
+import "fmt"
+
+var a = []int64{
+ 0.0005 * 1e9,
+ 0.001 * 1e9,
+ 0.005 * 1e9,
+ 0.01 * 1e9,
+ 0.05 * 1e9,
+ 0.1 * 1e9,
+ 0.5 * 1e9,
+ 1 * 1e9,
+ 5 * 1e9,
+}
+
+func main() {
+ s := ""
+ for _, v := range a {
+ s += fmt.Sprint(v) + " "
+ }
+ if s != "500000 1000000 5000000 10000000 50000000 100000000 500000000 1000000000 5000000000 " {
+ panic(s)
+ }
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug403.go b/gcc/testsuite/go.test/test/fixedbugs/bug403.go
new file mode 100644
index 000000000..ed7b49aea
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug403.go
@@ -0,0 +1,23 @@
+// compile
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Crashed gccgo.
+
+package p
+
+type S struct {
+ f interface{}
+}
+
+func F(p *S) bool {
+ v := p.f
+ switch a := v.(type) {
+ case nil:
+ _ = a
+ return true
+ }
+ return true
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug404.dir/one.go b/gcc/testsuite/go.test/test/fixedbugs/bug404.dir/one.go
new file mode 100644
index 000000000..2024eb007
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug404.dir/one.go
@@ -0,0 +1,19 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package one
+
+type T1 int
+type T2 []T1
+type T3 T2
+
+func F1(T2) {
+}
+
+func (p *T1) M1() T3 {
+ return nil
+}
+
+func (p T3) M2() {
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug404.dir/two.go b/gcc/testsuite/go.test/test/fixedbugs/bug404.dir/two.go
new file mode 100644
index 000000000..162eae712
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug404.dir/two.go
@@ -0,0 +1,12 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// The gccgo compiler would fail on the import statement.
+// two.go:10:13: error: use of undefined type ‘one.T2’
+
+package two
+
+import "./one"
+
+var V one.T3
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug404.go b/gcc/testsuite/go.test/test/fixedbugs/bug404.go
new file mode 100644
index 000000000..481acda32
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug404.go
@@ -0,0 +1,7 @@
+// compiledir
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package ignored
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug405.go b/gcc/testsuite/go.test/test/fixedbugs/bug405.go
new file mode 100644
index 000000000..e8ecc4d03
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug405.go
@@ -0,0 +1,24 @@
+// run
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Test using _ receiver. Failed with gccgo.
+
+package main
+
+type S struct {}
+
+func (_ S) F(i int) int {
+ return i
+}
+
+func main() {
+ s := S{}
+ const c = 123
+ i := s.F(c)
+ if i != c {
+ panic(i)
+ }
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug406.go b/gcc/testsuite/go.test/test/fixedbugs/bug406.go
new file mode 100644
index 000000000..c6f8534c9
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug406.go
@@ -0,0 +1,25 @@
+// run
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Issue 2821
+package main
+
+type matrix struct {
+ e []int
+}
+
+func (a matrix) equal() bool {
+ for _ = range a.e {
+ }
+ return true
+}
+
+func main() {
+ var a matrix
+ var i interface{}
+ i = true && a.equal()
+ _ = i
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug407.dir/one.go b/gcc/testsuite/go.test/test/fixedbugs/bug407.dir/one.go
new file mode 100644
index 000000000..a91d90433
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug407.dir/one.go
@@ -0,0 +1,20 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package one
+
+// Issue 2877
+type T struct {
+ f func(t *T, arg int)
+ g func(t T, arg int)
+}
+
+func (t *T) foo(arg int) {}
+func (t T) goo(arg int) {}
+
+func (t *T) F() { t.f = (*T).foo }
+func (t *T) G() { t.g = T.goo }
+
+
+
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug407.dir/two.go b/gcc/testsuite/go.test/test/fixedbugs/bug407.dir/two.go
new file mode 100644
index 000000000..67e1852ea
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug407.dir/two.go
@@ -0,0 +1,15 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Use the functions in one.go so that the inlined
+// forms get type-checked.
+
+package two
+
+import "./one"
+
+func use() {
+ var r one.T
+ r.F()
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug407.go b/gcc/testsuite/go.test/test/fixedbugs/bug407.go
new file mode 100644
index 000000000..48b79e01b
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug407.go
@@ -0,0 +1,7 @@
+// compiledir
+
+// Copyright 2011 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package ignored
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug409.go b/gcc/testsuite/go.test/test/fixedbugs/bug409.go
new file mode 100644
index 000000000..1dca43b7a
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug409.go
@@ -0,0 +1,20 @@
+// cmpout
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Multiple inlined calls to a function that causes
+// redundant address loads.
+
+package main
+
+func F(v [2]float64) [2]float64 {
+ return [2]float64{v[0], v[1]}
+}
+
+func main() {
+ a := F([2]float64{1, 2})
+ b := F([2]float64{3, 4})
+ println(a[0], a[1], b[0], b[1])
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug409.out b/gcc/testsuite/go.test/test/fixedbugs/bug409.out
new file mode 100644
index 000000000..3cb40ed59
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug409.out
@@ -0,0 +1 @@
++1.000000e+000 +2.000000e+000 +3.000000e+000 +4.000000e+000
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug410.go b/gcc/testsuite/go.test/test/fixedbugs/bug410.go
new file mode 100644
index 000000000..35ecbfc05
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug410.go
@@ -0,0 +1,24 @@
+// compile
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Used to run 6g out of registers. Issue 2669.
+
+package p
+
+type y struct {
+ num int
+}
+
+func zzz () {
+ k := make([]byte, 10)
+ arr := make ([]*y, 0)
+ for s := range arr {
+ x := make([]byte, 10)
+ for i := 0; i < 100 ; i++ {
+ x[i] ^= k[i-arr[s].num%0]
+ }
+ }
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug411.go b/gcc/testsuite/go.test/test/fixedbugs/bug411.go
new file mode 100644
index 000000000..3b90db88d
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug411.go
@@ -0,0 +1,19 @@
+// compile
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Issue 2588. Used to trigger internal compiler error on 8g,
+// because the compiler tried to registerize the int64 being
+// used as a memory operand of a int64->float64 move.
+
+package p
+
+func f1(a int64) {
+ f2(float64(a), float64(a))
+}
+
+func f2(a,b float64) {
+}
+
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug412.go b/gcc/testsuite/go.test/test/fixedbugs/bug412.go
new file mode 100644
index 000000000..8dd0a5fcc
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug412.go
@@ -0,0 +1,16 @@
+// errorcheck
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package p
+
+type t struct {
+ x int // ERROR "duplicate field x|duplicate field name .x."
+ x int
+}
+
+func f(t *t) int {
+ return t.x // GC_ERROR "ambiguous selector t.x"
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug413.go b/gcc/testsuite/go.test/test/fixedbugs/bug413.go
new file mode 100644
index 000000000..ba8046490
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug413.go
@@ -0,0 +1,11 @@
+// errorcheck
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package p
+
+func f(i int) int { return i }
+
+var i = func() int {a := f(i); return a}() // ERROR "initialization loop|depends upon itself"
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug414.dir/main.go b/gcc/testsuite/go.test/test/fixedbugs/bug414.dir/main.go
new file mode 100644
index 000000000..52001233c
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug414.dir/main.go
@@ -0,0 +1,18 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+ package main
+
+ import "./p1"
+
+ type MyObject struct {
+ p1.Fer
+ }
+
+ func main() {
+ var b p1.Fer = &p1.Object{}
+ p1.PrintFer(b)
+ var c p1.Fer = &MyObject{b}
+ p1.PrintFer(c)
+ }
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug414.dir/p1.go b/gcc/testsuite/go.test/test/fixedbugs/bug414.dir/p1.go
new file mode 100644
index 000000000..7768818bf
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug414.dir/p1.go
@@ -0,0 +1,21 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+ package p1
+
+ import "fmt"
+
+ type Fer interface {
+ f() string
+ }
+
+ type Object struct {}
+
+ func (this *Object) f() string {
+ return "Object.f"
+ }
+
+ func PrintFer(fer Fer) {
+ fmt.Sprintln(fer.f())
+ }
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug414.go b/gcc/testsuite/go.test/test/fixedbugs/bug414.go
new file mode 100644
index 000000000..5612fd5c2
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug414.go
@@ -0,0 +1,10 @@
+// $G $D/$F.dir/p1.go && $G $D/$F.dir/main.go && $L main.$A && ./$A.out
+
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package ignored
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug415.dir/p.go b/gcc/testsuite/go.test/test/fixedbugs/bug415.dir/p.go
new file mode 100644
index 000000000..b4152d63a
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug415.dir/p.go
@@ -0,0 +1,14 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package p
+
+type A struct {
+ s struct{int}
+}
+
+func (a *A) f() {
+ a.s = struct{int}{0}
+}
+
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug415.dir/prog.go b/gcc/testsuite/go.test/test/fixedbugs/bug415.dir/prog.go
new file mode 100644
index 000000000..b894453fc
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug415.dir/prog.go
@@ -0,0 +1,9 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package main
+import "./p"
+func main() {}
+var _ p.A
+
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug415.go b/gcc/testsuite/go.test/test/fixedbugs/bug415.go
new file mode 100644
index 000000000..8cd4c49f2
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug415.go
@@ -0,0 +1,9 @@
+// compiledir
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Issue 2716. Export metadata error made main.go not compile.
+
+package ignored
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug416.go b/gcc/testsuite/go.test/test/fixedbugs/bug416.go
new file mode 100644
index 000000000..1d24fa935
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug416.go
@@ -0,0 +1,13 @@
+// errorcheck
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package p
+
+type T struct {
+ X int
+}
+
+func (t *T) X() {} // ERROR "type T has both field and method named X|redeclares struct field name"
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug417.go b/gcc/testsuite/go.test/test/fixedbugs/bug417.go
new file mode 100644
index 000000000..a9acb4238
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug417.go
@@ -0,0 +1,32 @@
+// compile
+
+// Copyright 2009 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Some indirect uses of types crashed gccgo, because it assumed that
+// the size of the type was known before it had been computed.
+
+package p
+
+type S1 struct {
+ p *[1]S3
+ s [][1]S3
+ m map[int][1]S3
+ c chan [1]S3
+ i interface { f([1]S3) [1]S3 }
+ f func([1]S3) [1]S3
+}
+
+type S2 struct {
+ p *struct { F S3 }
+ s []struct { F S3 }
+ m map[int]struct { F S3 }
+ c chan struct { F S3 }
+ i interface { f(struct { F S3 }) struct { F S3 } }
+ f func(struct { F S3 } ) struct { F S3 }
+}
+
+type S3 struct {
+ I int
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug418.go b/gcc/testsuite/go.test/test/fixedbugs/bug418.go
new file mode 100644
index 000000000..64d86b340
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug418.go
@@ -0,0 +1,22 @@
+// errorcheck
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Issue 3044.
+// Multiple valued expressions in return lists.
+
+package p
+
+func Two() (a, b int)
+
+// F used to compile.
+func F() (x interface{}, y int) {
+ return Two(), 0 // ERROR "single-value context"
+}
+
+// Recursive used to trigger an internal compiler error.
+func Recursive() (x interface{}, y int) {
+ return Recursive(), 0 // ERROR "single-value context"
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug419.go b/gcc/testsuite/go.test/test/fixedbugs/bug419.go
new file mode 100644
index 000000000..cfab404eb
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug419.go
@@ -0,0 +1,17 @@
+// compile
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Issue 1811.
+// gccgo failed to compile this.
+
+package p
+
+type E interface{}
+
+type I interface {
+ E
+ E
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug420.go b/gcc/testsuite/go.test/test/fixedbugs/bug420.go
new file mode 100644
index 000000000..02b4349d8
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug420.go
@@ -0,0 +1,14 @@
+// compile
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Issue 1757.
+// gccgo failed to compile this.
+
+package main
+
+func main() {
+ (_) = 0
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug421.go b/gcc/testsuite/go.test/test/fixedbugs/bug421.go
new file mode 100644
index 000000000..1fe02375a
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug421.go
@@ -0,0 +1,17 @@
+// errorcheck
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Issue 1927.
+// gccgo failed to issue the first error below.
+
+package main
+
+func main() {
+ println(int(1) == uint(1)) // ERROR "types"
+ var x int = 1
+ var y uint = 1
+ println(x == y) // ERROR "types"
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug422.go b/gcc/testsuite/go.test/test/fixedbugs/bug422.go
new file mode 100644
index 000000000..6865fe4b6
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug422.go
@@ -0,0 +1,11 @@
+// compile
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// gccgo crashed compiling this file.
+
+package p
+
+var V = "a" > "b"
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug423.go b/gcc/testsuite/go.test/test/fixedbugs/bug423.go
new file mode 100644
index 000000000..726891245
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug423.go
@@ -0,0 +1,277 @@
+// run
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// gc used to overflow a counter when a variable was
+// mentioned 256 times, and generate stack corruption.
+
+package main
+
+func main() {
+ F(1)
+}
+
+func F(arg int) {
+ var X interface{}
+ _ = X // used once
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0 // used 32 times
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0 // used 64 times
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0 // used 96 times
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0 // used 128 times
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0 // used 200 times
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0
+ X = 0 // used 256 times
+ if arg != 1 {
+ panic("argument was changed")
+ }
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug424.dir/lib.go b/gcc/testsuite/go.test/test/fixedbugs/bug424.dir/lib.go
new file mode 100644
index 000000000..97054da3a
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug424.dir/lib.go
@@ -0,0 +1,16 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package lib
+
+type I interface {
+ m() string
+}
+
+type T struct{}
+
+// m is not accessible from outside this package.
+func (t *T) m() string {
+ return "lib.T.m"
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug424.go b/gcc/testsuite/go.test/test/fixedbugs/bug424.go
new file mode 100644
index 000000000..41524543a
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug424.go
@@ -0,0 +1,102 @@
+// $G $D/$F.dir/lib.go && $G $D/$F.go && $L $F.$A && ./$A.out
+
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Tests that method calls through an interface always
+// call the locally defined method localT.m independent
+// at which embedding level it is and in which order
+// embedding is done.
+
+package main
+
+import "./lib"
+import "reflect"
+import "fmt"
+
+type localI interface {
+ m() string
+}
+
+type localT struct{}
+
+func (t *localT) m() string {
+ return "main.localT.m"
+}
+
+type myT1 struct {
+ localT
+}
+
+type myT2 struct {
+ localT
+ lib.T
+}
+
+type myT3 struct {
+ lib.T
+ localT
+}
+
+func main() {
+ var i localI
+
+ i = new(localT)
+ if i.m() != "main.localT.m" {
+ println("BUG: localT:", i.m(), "called")
+ }
+
+ i = new(myT1)
+ if i.m() != "main.localT.m" {
+ println("BUG: myT1:", i.m(), "called")
+ }
+
+ i = new(myT2)
+ if i.m() != "main.localT.m" {
+ println("BUG: myT2:", i.m(), "called")
+ }
+
+ t3 := new(myT3)
+ if t3.m() != "main.localT.m" {
+ println("BUG: t3:", t3.m(), "called")
+ }
+
+ i = new(myT3)
+ if i.m() != "main.localT.m" {
+ t := reflect.TypeOf(i)
+ n := t.NumMethod()
+ for j := 0; j < n; j++ {
+ m := t.Method(j)
+ fmt.Printf("#%d: %s.%s %s\n", j, m.PkgPath, m.Name, m.Type)
+ }
+ println("BUG: myT3:", i.m(), "called")
+ }
+
+ var t4 struct {
+ localT
+ lib.T
+ }
+ if t4.m() != "main.localT.m" {
+ println("BUG: t4:", t4.m(), "called")
+ }
+ i = &t4
+ if i.m() != "main.localT.m" {
+ println("BUG: myT4:", i.m(), "called")
+ }
+
+ var t5 struct {
+ lib.T
+ localT
+ }
+ if t5.m() != "main.localT.m" {
+ println("BUG: t5:", t5.m(), "called")
+ }
+ i = &t5
+ if i.m() != "main.localT.m" {
+ println("BUG: myT5:", i.m(), "called")
+ }
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug425.go b/gcc/testsuite/go.test/test/fixedbugs/bug425.go
new file mode 100644
index 000000000..5546bd96b
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug425.go
@@ -0,0 +1,17 @@
+// compile
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// http://code.google.com/p/go/issues/detail?id=3119
+
+package main
+
+import "fmt"
+
+func main() {
+ s := "hello"
+ fmt.Println(s == "")
+ fmt.Println(s + "world" == "world")
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug426.go b/gcc/testsuite/go.test/test/fixedbugs/bug426.go
new file mode 100644
index 000000000..a1af3cf99
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug426.go
@@ -0,0 +1,15 @@
+// compile
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// gccgo crashed compiling this.
+
+package p
+
+type T *T
+
+func f(t T) {
+ println(t, *t)
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug427.go b/gcc/testsuite/go.test/test/fixedbugs/bug427.go
new file mode 100644
index 000000000..1239e7a33
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug427.go
@@ -0,0 +1,39 @@
+// compile
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// http://code.google.com/p/go/issues/detail?id=3351
+
+package main
+
+// struct with four fields of basic type
+type S struct {a, b, c, d int}
+
+// struct with five fields of basic type
+type T struct {a, b, c, d, e int}
+
+// array with four elements
+type A [4]int
+
+// array with five elements
+type B [5]int
+
+func main() {
+ var i interface{}
+
+ var s1, s2 S
+ i = s1 == s2
+
+ var t1, t2 T
+ i = t1 == t2
+
+ var a1, a2 A
+ i = a1 == a2
+
+ var b1, b2 B
+ i = b1 == b2
+
+ _ = i
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug428.go b/gcc/testsuite/go.test/test/fixedbugs/bug428.go
new file mode 100644
index 000000000..298c45518
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug428.go
@@ -0,0 +1,19 @@
+// run
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Test that when the compiler expands append inline it does not
+// overwrite a value before it needs it (issue 3369).
+
+package main
+
+func main() {
+ s := make([]byte, 5, 6)
+ copy(s, "12346")
+ s = append(s[:len(s)-1], '5', s[len(s)-1])
+ if string(s) != "123456" {
+ panic(s)
+ }
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug429.go b/gcc/testsuite/go.test/test/fixedbugs/bug429.go
new file mode 100644
index 000000000..794d293db
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug429.go
@@ -0,0 +1,16 @@
+// $G $D/$F.go && $L $F.$A && ! ./$A.out || echo BUG: bug429
+
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Should print deadlock message, not hang.
+
+package main
+
+func main() {
+ select {}
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug430.go b/gcc/testsuite/go.test/test/fixedbugs/bug430.go
new file mode 100644
index 000000000..93d5cf2d5
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug430.go
@@ -0,0 +1,22 @@
+// compile
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// gccgo crashed compiling this.
+
+package main
+
+type S struct {
+ f [2][]int
+}
+
+func F() (r [2][]int) {
+ return
+}
+
+func main() {
+ var a []S
+ a[0].f = F()
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug431.go b/gcc/testsuite/go.test/test/fixedbugs/bug431.go
new file mode 100644
index 000000000..1057dadcc
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug431.go
@@ -0,0 +1,18 @@
+// compile
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// gccgo gave an invalid error ("floating point constant truncated to
+// integer") compiling this.
+
+package p
+
+const C = 1<<63 - 1
+
+func F(i int64) int64 {
+ return i
+}
+
+var V = F(int64(C) / 1e6)
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug432.go b/gcc/testsuite/go.test/test/fixedbugs/bug432.go
new file mode 100644
index 000000000..0c1a91461
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug432.go
@@ -0,0 +1,13 @@
+// compile
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// gccgo crashed compiling this.
+
+package p
+
+var v struct{ I }
+
+type I interface{}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug433.go b/gcc/testsuite/go.test/test/fixedbugs/bug433.go
new file mode 100644
index 000000000..1139dfa00
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug433.go
@@ -0,0 +1,39 @@
+// run
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Test that initializing struct fields out of order still runs
+// functions in the right order. This failed with gccgo.
+
+package main
+
+type S struct {
+ i1, i2, i3 int
+}
+
+var G int
+
+func v(i int) int {
+ if i != G {
+ panic(i)
+ }
+ G = i + 1
+ return G
+}
+
+func F() S {
+ return S{
+ i1: v(0),
+ i3: v(1),
+ i2: v(2),
+ }
+}
+
+func main() {
+ s := F()
+ if s != (S{1, 3, 2}) {
+ panic(s)
+ }
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug434.go b/gcc/testsuite/go.test/test/fixedbugs/bug434.go
new file mode 100644
index 000000000..5abb567b4
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug434.go
@@ -0,0 +1,32 @@
+// run
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Test that typed and untyped negative zero floating point constants
+// are treated as equivalent to zero constants.
+
+package main
+
+import "math"
+
+const zero = 0.0
+
+func main() {
+ x := -zero
+ b := math.Float64bits(x)
+ if b != 0 {
+ panic(b)
+ }
+ x = -float64(zero)
+ b = math.Float64bits(x)
+ if b != 0 {
+ panic(b)
+ }
+ v := x
+ b = math.Float64bits(-v)
+ if b != 0x8000000000000000 {
+ panic(b)
+ }
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug435.go b/gcc/testsuite/go.test/test/fixedbugs/bug435.go
new file mode 100644
index 000000000..9c30b143b
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug435.go
@@ -0,0 +1,15 @@
+// errorcheck
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Test that a syntax error caused by an unexpected EOF
+// gives an error message with the correct line number.
+//
+// https://code.google.com/p/go/issues/detail?id=3392
+
+package main
+
+func foo() {
+ bar(1, // ERROR "unexpected|missing|undefined"
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug436.go b/gcc/testsuite/go.test/test/fixedbugs/bug436.go
new file mode 100644
index 000000000..e848eaeba
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug436.go
@@ -0,0 +1,32 @@
+// run
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Gccgo used to crash compiling this.
+
+package main
+
+func foo() (int, int) {
+ return 1, 2
+}
+
+var c = b
+var a, b = foo()
+var d = b + 1
+
+func main() {
+ if a != 1 {
+ panic(a)
+ }
+ if b != 2 {
+ panic(b)
+ }
+ if c != 2 {
+ panic(c)
+ }
+ if d != 3 {
+ panic(d)
+ }
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug437.dir/one.go b/gcc/testsuite/go.test/test/fixedbugs/bug437.dir/one.go
new file mode 100644
index 000000000..8d3caadae
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug437.dir/one.go
@@ -0,0 +1,18 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package one
+
+type I1 interface {
+ f()
+}
+
+type S1 struct {
+}
+
+func (s S1) f() {
+}
+
+func F1(i1 I1) {
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug437.dir/two.go b/gcc/testsuite/go.test/test/fixedbugs/bug437.dir/two.go
new file mode 100644
index 000000000..406dd5903
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug437.dir/two.go
@@ -0,0 +1,11 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package two
+
+import "./one"
+
+type S2 struct {
+ one.S1
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug437.go b/gcc/testsuite/go.test/test/fixedbugs/bug437.go
new file mode 100644
index 000000000..b1e76a6a7
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug437.go
@@ -0,0 +1,30 @@
+// $G $D/$F.dir/one.go && $G $D/$F.dir/two.go && $G $D/$F.go && $L $F.$A && ./$A.out
+
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Test converting a type defined in a different package to an
+// interface defined in a third package, where the interface has a
+// hidden method. This used to cause a link error with gccgo.
+
+package main
+
+import (
+ "./one"
+ "./two"
+)
+
+func F(i1 one.I1) {
+ switch v := i1.(type) {
+ case two.S2:
+ one.F1(v)
+ }
+}
+
+func main() {
+ F(nil)
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug438.go b/gcc/testsuite/go.test/test/fixedbugs/bug438.go
new file mode 100644
index 000000000..15d3fdab8
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug438.go
@@ -0,0 +1,16 @@
+// compile
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Gccgo used to incorrectly give an error when compiling this.
+
+package p
+
+func F() (i int) {
+ for first := true; first; first = false {
+ i++
+ }
+ return
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug439.go b/gcc/testsuite/go.test/test/fixedbugs/bug439.go
new file mode 100644
index 000000000..87d4ae037
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug439.go
@@ -0,0 +1,22 @@
+// compile
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Gccgo used to crash compiling this.
+
+package p
+
+type E int
+
+func (e E) P() *E { return &e }
+
+const (
+ C1 E = 0
+ C2 = C1
+)
+
+func F() *E {
+ return C2.P()
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug440_32.go b/gcc/testsuite/go.test/test/fixedbugs/bug440_32.go
new file mode 100644
index 000000000..2d26fbb90
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug440_32.go
@@ -0,0 +1,21 @@
+// run
+
+// Test for 8g register move bug. The optimizer gets confused
+// about 16- vs 32-bit moves during splitContractIndex.
+
+// Issue 3910.
+
+package main
+
+func main() {
+ const c = 0x12345678
+ index, n, offset := splitContractIndex(c)
+ if index != int((c&0xffff)>>5) || n != int(c&(1<<5-1)) || offset != (c>>16)&(1<<14-1) {
+ println("BUG", index, n, offset)
+ }
+}
+
+func splitContractIndex(ce uint32) (index, n, offset int) {
+ h := uint16(ce)
+ return int(h >> 5), int(h & (1<<5 - 1)), int(ce>>16) & (1<<14 - 1)
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug440_64.go b/gcc/testsuite/go.test/test/fixedbugs/bug440_64.go
new file mode 100644
index 000000000..3ab3e565d
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug440_64.go
@@ -0,0 +1,21 @@
+// run
+
+// Test for 6g register move bug. The optimizer gets confused
+// about 32- vs 64-bit moves during splitContractIndex.
+
+// Issue 3918.
+
+package main
+
+func main() {
+ const c = 0x123400005678
+ index, offset := splitContractIndex(c)
+ if index != (c&0xffffffff)>>5 || offset != c+1 {
+ println("BUG", index, offset)
+ }
+}
+
+func splitContractIndex(ce uint64) (index uint32, offset uint64) {
+ h := uint32(ce)
+ return h >> 5, ce + 1
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug441.go b/gcc/testsuite/go.test/test/fixedbugs/bug441.go
new file mode 100644
index 000000000..8562bfeef
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug441.go
@@ -0,0 +1,36 @@
+// run
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Was discarding function calls made for arguments named _
+// in inlined functions. Issue 3593.
+
+package main
+
+var did int
+
+func main() {
+ foo(side())
+ foo2(side(), side())
+ foo3(side(), side())
+ T.m1(T(side()))
+ T(1).m2(side())
+ const want = 7
+ if did != want {
+ println("BUG: missing", want-did, "calls")
+ }
+}
+
+func foo(_ int) {}
+func foo2(_, _ int) {}
+func foo3(int, int) {}
+type T int
+func (_ T) m1() {}
+func (t T) m2(_ int) {}
+
+func side() int {
+ did++
+ return 1
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug442.go b/gcc/testsuite/go.test/test/fixedbugs/bug442.go
new file mode 100644
index 000000000..1d1a94816
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug442.go
@@ -0,0 +1,27 @@
+// run
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Used to crash generating hash and == functions for struct
+// with leading _ field. Issue 3607.
+
+package main
+
+type T struct {
+ _ int
+ X interface{}
+ _ string
+ Y float64
+}
+
+func main() {
+ m := map[T]int{}
+ m[T{X: 1, Y: 2}] = 1
+ m[T{X: 2, Y: 3}] = 2
+ m[T{X: 1, Y: 2}] = 3 // overwrites first entry
+ if len(m) != 2 {
+ println("BUG")
+ }
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug443.go b/gcc/testsuite/go.test/test/fixedbugs/bug443.go
new file mode 100644
index 000000000..b67bd8cb8
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug443.go
@@ -0,0 +1,17 @@
+// compile
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Was failing to compile with 'invalid receiver' due to
+// incomplete type definition evaluation. Issue 3709.
+
+package p
+
+type T1 struct { F *T2 }
+type T2 T1
+
+type T3 T2
+func (*T3) M() // was invalid receiver
+
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug444.go b/gcc/testsuite/go.test/test/fixedbugs/bug444.go
new file mode 100644
index 000000000..b54fb4f58
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug444.go
@@ -0,0 +1,36 @@
+// run
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// The no-op conversion here used to confuse the compiler
+// into doing a load-effective-address of nil.
+// See issue 3670.
+
+package main
+
+import "reflect"
+
+type T interface {}
+
+var x bool
+
+func main() {
+ reflect.TypeOf(nil)
+ reflect.TypeOf(T(nil)) // used to miscompile
+ shouldPanic()
+}
+
+func f() byte {
+ return []byte(nil)[0] // used to miscompile
+}
+
+func shouldPanic() {
+ defer func() {
+ if recover() == nil {
+ panic("not panicking")
+ }
+ }()
+ f()
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug445.go b/gcc/testsuite/go.test/test/fixedbugs/bug445.go
new file mode 100644
index 000000000..497ecd3ab
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug445.go
@@ -0,0 +1,14 @@
+// compile
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Issue 3765
+
+package main
+
+func f(x uint) uint {
+ m := ^(1 << x)
+ return uint(m)
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug446.go b/gcc/testsuite/go.test/test/fixedbugs/bug446.go
new file mode 100644
index 000000000..1e435e110
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug446.go
@@ -0,0 +1,36 @@
+// run
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Issue 3824.
+// Method calls are ignored when deciding initialization
+// order.
+
+package main
+
+type T int
+
+func (r T) Method1() int { return a }
+func (r T) Method2() int { return b }
+
+// dummy1 and dummy2 must be initialized after a and b.
+var dummy1 = T(0).Method1()
+var dummy2 = T.Method2(0)
+
+// Use a function call to force generating code.
+var a = identity(1)
+var b = identity(2)
+
+func identity(a int) int { return a }
+
+func main() {
+ if dummy1 != 1 {
+ panic("dummy1 != 1")
+ }
+ if dummy2 != 2 {
+ panic("dummy2 != 2")
+ }
+}
+
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug447.go b/gcc/testsuite/go.test/test/fixedbugs/bug447.go
new file mode 100644
index 000000000..a4c871bdb
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug447.go
@@ -0,0 +1,105 @@
+// runoutput
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Issue 3804
+// test all possible float -> integer conversions
+
+package main
+
+import (
+ "bytes"
+ "fmt"
+ "strings"
+)
+
+var (
+ intWidths = []int{8, 16, 32, 64} // int%d and uint%d
+ floatWidths = []int{32, 64} // float%d
+)
+
+func main() {
+
+ var names, funcs bytes.Buffer
+
+ for _, iWidth := range intWidths {
+ for _, typ := range []string{"int", "uint"} {
+ var segs bytes.Buffer
+ itype := fmt.Sprintf("%s%d", typ, iWidth)
+ names.WriteString("\ttest" + itype + ",\n")
+ for _, fWidth := range floatWidths {
+ ftype := fmt.Sprintf("float%d", fWidth)
+ seg := strings.Replace(testSegment, "$F", ftype, -1)
+ seg = strings.Replace(seg, "$I", itype, -1)
+ segs.WriteString(seg)
+ }
+ body := strings.Replace(testFunc, "$I", itype, -1)
+ if typ[0] == 'u' {
+ body = strings.Replace(body, "$TEST", " || i < 0", 1)
+ } else {
+ body = strings.Replace(body, "$TEST", "", 1)
+ }
+ body = strings.Replace(body, "$TESTSEGMENTS", segs.String(), 1)
+ funcs.WriteString(body)
+ }
+ }
+
+ program = strings.Replace(program, "$NAMES", names.String(), 1)
+ program = strings.Replace(program, "$FUNCS", funcs.String(), 1)
+ fmt.Print(program)
+}
+
+const testSegment = `
+ f$F := $F(f)
+ if math.Abs(float64(f$F) - f) < 0.05 {
+ if v := $I(f$F); v != $I(i) {
+ fmt.Printf("$I($F(%f)) = %v, expected %v\n", f, v, i)
+ }
+ }`
+
+const testFunc =
+`func test$I(f float64, i int64) {
+ if i != int64($I(i))$TEST {
+ return
+ }
+$TESTSEGMENTS
+}
+`
+
+var program =
+`package main
+
+import (
+ "fmt"
+ "math"
+)
+
+var tests = []struct {
+ f float64
+ i int64
+}{
+ {39.7, 39},
+ {-39.7, -39},
+ {258.6, 258},
+ {-258.6, -258},
+ {65538.9, 65538},
+ {-65538.9, -65538},
+ {4294967298.8, 4294967298},
+ {-4294967298.8, -4294967298},
+}
+
+var funcs = []func(float64, int64){
+$NAMES
+}
+
+$FUNCS
+func main() {
+ for _, t := range tests {
+ for _, f := range funcs {
+ f(t.f, t.i)
+ }
+ }
+}
+`
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug448.dir/pkg1.go b/gcc/testsuite/go.test/test/fixedbugs/bug448.dir/pkg1.go
new file mode 100644
index 000000000..032e5d9de
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug448.dir/pkg1.go
@@ -0,0 +1,11 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package pkg1
+
+var x = make(chan interface{})
+
+func Do() int {
+ return (<-x).(int)
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug448.dir/pkg2.go b/gcc/testsuite/go.test/test/fixedbugs/bug448.dir/pkg2.go
new file mode 100644
index 000000000..5c78c7d2f
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug448.dir/pkg2.go
@@ -0,0 +1,14 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Issue 3843: inlining bug due to wrong receive operator precedence.
+
+package pkg2
+
+import "./pkg1"
+
+func F() {
+ pkg1.Do()
+}
+
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug448.go b/gcc/testsuite/go.test/test/fixedbugs/bug448.go
new file mode 100644
index 000000000..242f5999e
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug448.go
@@ -0,0 +1,7 @@
+// compiledir
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package ignored
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug449.go b/gcc/testsuite/go.test/test/fixedbugs/bug449.go
new file mode 100644
index 000000000..a9650f4c6
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug449.go
@@ -0,0 +1,69 @@
+// runoutput
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Issue 3866
+// runtime.equal failed to take padding between arguments and
+// return values into account, so in certain cases gc-generated
+// code will read a random bool from the stack as the result of
+// the comparison.
+// This program generates a lot of equality tests and hopes to
+// catch this.
+// NOTE: this program assumes comparing instance of T and T's
+// underlying []byte will make gc emit calls to runtime.equal,
+// and if gc optimizes this case, then the test will no longer
+// be correct (in the sense that it no longer tests runtime.equal).
+
+package main
+
+import (
+ "bytes"
+ "fmt"
+ "strconv"
+ "strings"
+)
+
+const ntest = 1024
+
+func main() {
+ var decls, calls bytes.Buffer
+
+ for i := 1; i <= ntest; i++ {
+ s := strconv.Itoa(i)
+ decls.WriteString(strings.Replace(decl, "$", s, -1))
+ calls.WriteString(strings.Replace("call(test$)\n\t", "$", s, -1))
+ }
+
+ program = strings.Replace(program, "$DECLS", decls.String(), 1)
+ program = strings.Replace(program, "$CALLS", calls.String(), 1)
+ fmt.Print(program)
+}
+
+var program = `package main
+
+var count int
+
+func call(f func() bool) {
+ if f() {
+ count++
+ }
+}
+
+$DECLS
+
+func main() {
+ $CALLS
+ if count != 0 {
+ println("failed", count, "case(s)")
+ }
+}
+`
+
+const decl = `
+type T$ [$]uint8
+func test$() bool {
+ v := T${1}
+ return v == [$]uint8{2} || v != [$]uint8{1}
+}`
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug450.go b/gcc/testsuite/go.test/test/fixedbugs/bug450.go
new file mode 100644
index 000000000..3f13de16c
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug450.go
@@ -0,0 +1,28 @@
+// run
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Issue 3899: 8g incorrectly thinks a variable is
+// "set but not used" and elides an assignment, causing
+// variables to end up with wrong data.
+//
+// The reason is a miscalculation of variable width.
+
+package main
+
+func bar(f func()) {
+ f()
+}
+
+func foo() {
+ f := func() {}
+ if f == nil {
+ }
+ bar(f)
+}
+
+func main() {
+ foo()
+}
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug451.go b/gcc/testsuite/go.test/test/fixedbugs/bug451.go
new file mode 100644
index 000000000..75ce97490
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug451.go
@@ -0,0 +1,11 @@
+// errorcheck
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package main
+
+type T x.T // ERROR "undefined|expected package"
+
+// bogus "invalid recursive type"
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug452.go b/gcc/testsuite/go.test/test/fixedbugs/bug452.go
new file mode 100644
index 000000000..d2e4a0b44
--- /dev/null
+++ b/gcc/testsuite/go.test/test/fixedbugs/bug452.go
@@ -0,0 +1,38 @@
+// run
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Issue 3835: 8g tries to optimize arithmetic involving integer
+// constants, but can run out of registers in the process.
+
+package main
+
+var a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u, v, w, x, y, z, A, B, C, D, E, F, G int
+
+func foo() int {
+ return a + 1 + b + 2 + c + 3 + d + 4 + e + 5 + f + 6 + g + 7 + h + 8 + i + 9 + j + 10 +
+ k + 1 + l + 2 + m + 3 + n + 4 + o + 5 + p + 6 + q + 7 + r + 8 + s + 9 + t + 10 +
+ u + 1 + v + 2 + w + 3 + x + 4 + y + 5 + z + 6 + A + 7 + B + 8 + C + 9 + D + 10 +
+ E + 1 + F + 2 + G + 3
+}
+
+func bar() int8 {
+ var (
+ W int16
+ X int32
+ Y int32
+ Z int32
+ )
+ return int8(W+int16(X+3)+3) * int8(Y+3+Z*3)
+}
+
+func main() {
+ if foo() == 0 {
+ panic("foo")
+ }
+ if bar() == 0 {
+ panic("bar")
+ }
+}
diff --git a/gcc/testsuite/go.test/test/float_lit.go b/gcc/testsuite/go.test/test/float_lit.go
index 7b91d88e5..2912c3749 100644
--- a/gcc/testsuite/go.test/test/float_lit.go
+++ b/gcc/testsuite/go.test/test/float_lit.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test floating-point literal syntax.
+
package main
var bad bool
diff --git a/gcc/testsuite/go.test/test/floatcmp.go b/gcc/testsuite/go.test/test/floatcmp.go
index f51cbc277..f9f59a937 100644
--- a/gcc/testsuite/go.test/test/floatcmp.go
+++ b/gcc/testsuite/go.test/test/floatcmp.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test floating-point comparison involving NaN.
+
package main
import "math"
diff --git a/gcc/testsuite/go.test/test/for.go b/gcc/testsuite/go.test/test/for.go
index 36ad15709..8a5009065 100644
--- a/gcc/testsuite/go.test/test/for.go
+++ b/gcc/testsuite/go.test/test/for.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test for loops.
+
package main
func assertequal(is, shouldbe int, msg string) {
diff --git a/gcc/testsuite/go.test/test/func.go b/gcc/testsuite/go.test/test/func.go
index e8ed928bc..246cb56fd 100644
--- a/gcc/testsuite/go.test/test/func.go
+++ b/gcc/testsuite/go.test/test/func.go
@@ -1,9 +1,10 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test simple functions.
package main
diff --git a/gcc/testsuite/go.test/test/func1.go b/gcc/testsuite/go.test/test/func1.go
index 056ff9877..c89f7ff2e 100644
--- a/gcc/testsuite/go.test/test/func1.go
+++ b/gcc/testsuite/go.test/test/func1.go
@@ -1,14 +1,15 @@
-// errchk $G $F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// does not compile and should not compile
+// Test that result parameters are in the same scope as regular parameters.
+// Does not compile.
package main
-func f1(a int) (int, float32) { // BUG (not caught by compiler): multiple return values must have names
+func f1(a int) (int, float32) {
return 7, 7.0
}
diff --git a/gcc/testsuite/go.test/test/func2.go b/gcc/testsuite/go.test/test/func2.go
index 87e78194e..b5966a91f 100644
--- a/gcc/testsuite/go.test/test/func2.go
+++ b/gcc/testsuite/go.test/test/func2.go
@@ -1,9 +1,12 @@
-// $G $F.go || echo BUG: should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test function signatures.
+// Compiled but not run.
+
package main
type t1 int
diff --git a/gcc/testsuite/go.test/test/func3.go b/gcc/testsuite/go.test/test/func3.go
index 110b0ef1c..6be3bf018 100644
--- a/gcc/testsuite/go.test/test/func3.go
+++ b/gcc/testsuite/go.test/test/func3.go
@@ -1,9 +1,12 @@
-// errchk $G $F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that illegal function signatures are detected.
+// Does not compile.
+
package main
type t1 int
diff --git a/gcc/testsuite/go.test/test/func4.go b/gcc/testsuite/go.test/test/func4.go
index 2a1a932de..85f1e4b81 100644
--- a/gcc/testsuite/go.test/test/func4.go
+++ b/gcc/testsuite/go.test/test/func4.go
@@ -1,9 +1,12 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that it is illegal to take the address of a function.
+// Does not compile.
+
package main
var notmain func()
diff --git a/gcc/testsuite/go.test/test/func5.go b/gcc/testsuite/go.test/test/func5.go
index e27825c2b..2e058be7e 100644
--- a/gcc/testsuite/go.test/test/func5.go
+++ b/gcc/testsuite/go.test/test/func5.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test functions and goroutines.
+
package main
func caller(f func(int, int) int, a, b int, c chan int) {
diff --git a/gcc/testsuite/go.test/test/func6.go b/gcc/testsuite/go.test/test/func6.go
index 1356b6aa8..456cb49f0 100644
--- a/gcc/testsuite/go.test/test/func6.go
+++ b/gcc/testsuite/go.test/test/func6.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test closures in if conditions.
+
package main
func main() {
diff --git a/gcc/testsuite/go.test/test/func7.go b/gcc/testsuite/go.test/test/func7.go
index e38b008cc..6f6766f29 100644
--- a/gcc/testsuite/go.test/test/func7.go
+++ b/gcc/testsuite/go.test/test/func7.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test evaluation order in if condition.
+
package main
var calledf = false
diff --git a/gcc/testsuite/go.test/test/func8.go b/gcc/testsuite/go.test/test/func8.go
new file mode 100644
index 000000000..7defe265b
--- /dev/null
+++ b/gcc/testsuite/go.test/test/func8.go
@@ -0,0 +1,49 @@
+// run
+
+// Copyright 2011 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Test evaluation order.
+
+package main
+
+var calledf int
+
+func f() int {
+ calledf++
+ return 0
+}
+
+func g() int {
+ return calledf
+}
+
+var xy string
+
+func x() bool {
+ for false {
+ } // no inlining
+ xy += "x"
+ return false
+}
+
+func y() string {
+ for false {
+ } // no inlining
+ xy += "y"
+ return "abc"
+}
+
+func main() {
+ if f() == g() {
+ println("wrong f,g order")
+ }
+
+ if x() == (y() == "abc") {
+ panic("wrong compare")
+ }
+ if xy != "xy" {
+ println("wrong x,y order")
+ }
+}
diff --git a/gcc/testsuite/go.test/test/gc.go b/gcc/testsuite/go.test/test/gc.go
index 3aab8fac9..6688f9fbd 100644
--- a/gcc/testsuite/go.test/test/gc.go
+++ b/gcc/testsuite/go.test/test/gc.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Simple test of the garbage collector.
+
package main
import "runtime"
diff --git a/gcc/testsuite/go.test/test/gc1.go b/gcc/testsuite/go.test/test/gc1.go
index 84034e7ce..6049ea14e 100644
--- a/gcc/testsuite/go.test/test/gc1.go
+++ b/gcc/testsuite/go.test/test/gc1.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// A simple test of the garbage collector.
+
package main
func main() {
diff --git a/gcc/testsuite/go.test/test/gc2.go b/gcc/testsuite/go.test/test/gc2.go
index 772f9810d..de52a4fbf 100644
--- a/gcc/testsuite/go.test/test/gc2.go
+++ b/gcc/testsuite/go.test/test/gc2.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Check that buffered channels are garbage collected properly.
+// Test that buffered channels are garbage collected properly.
// An interesting case because they have finalizers and used to
// have self loops that kept them from being collected.
// (Cyclic data with finalizers is never finalized, nor collected.)
diff --git a/gcc/testsuite/go.test/test/golden.out b/gcc/testsuite/go.test/test/golden.out
index e0b4cf6e2..3e44e04c6 100644
--- a/gcc/testsuite/go.test/test/golden.out
+++ b/gcc/testsuite/go.test/test/golden.out
@@ -11,9 +11,18 @@
== dwarf/
+== safe/
+
== fixedbugs/
+=========== fixedbugs/bug429.go
+throw: all goroutines are asleep - deadlock!
+
== bugs/
=========== bugs/bug395.go
bug395 is broken
+
+=========== bugs/bug434.go
+bugs/bug434.dir/two.go:10: one.t.int undefined (cannot refer to unexported field or method one.int)
+BUG:bug434
diff --git a/gcc/testsuite/go.test/test/goprint.go b/gcc/testsuite/go.test/test/goprint.go
index 53ed055a0..2f0d3c390 100644
--- a/gcc/testsuite/go.test/test/goprint.go
+++ b/gcc/testsuite/go.test/test/goprint.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out 2>&1 | cmp - $D/$F.out
+// cmpout
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test that println can be the target of a go statement.
+
package main
import "time"
diff --git a/gcc/testsuite/go.test/test/goto.go b/gcc/testsuite/go.test/test/goto.go
index 1fccb314c..ca477b3d0 100644
--- a/gcc/testsuite/go.test/test/goto.go
+++ b/gcc/testsuite/go.test/test/goto.go
@@ -1,9 +1,12 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify goto semantics.
+// Does not compile.
+//
// Each test is in a separate function just so that if the
// compiler stops processing after one error, we don't
// lose other ones.
diff --git a/gcc/testsuite/go.test/test/hashmap.go b/gcc/testsuite/go.test/test/hashmap.go
deleted file mode 100755
index 0a4d7ab61..000000000
--- a/gcc/testsuite/go.test/test/hashmap.go
+++ /dev/null
@@ -1,181 +0,0 @@
-// $G $F.go && $L $F.$A && ./$A.out
-
-// Copyright 2009 The Go Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style
-// license that can be found in the LICENSE file.
-
-package main
-
-// ----------------------------------------------------------------------------
-// Helper functions
-
-func ASSERT(p bool) {
- if !p {
- // panic 0
- }
-}
-
-
-// ----------------------------------------------------------------------------
-// Implementation of the HashMap
-
-type KeyType interface {
- Hash() uint32
- Match(other KeyType) bool
-}
-
-
-type ValueType interface {
- // empty interface
-}
-
-
-type Entry struct {
- key KeyType
- value ValueType
-}
-
-
-type Array [1024]Entry
-
-type HashMap struct {
- map_ *Array
- log2_capacity_ uint32
- occupancy_ uint32
-}
-
-
-func (m *HashMap) capacity() uint32 {
- return 1 << m.log2_capacity_
-}
-
-
-func (m *HashMap) Clear() {
- // Mark all entries as empty.
- var i uint32 = m.capacity() - 1
- for i > 0 {
- m.map_[i].key = nil
- i = i - 1
- }
- m.occupancy_ = 0
-}
-
-
-func (m *HashMap) Initialize (initial_log2_capacity uint32) {
- m.log2_capacity_ = initial_log2_capacity
- m.map_ = new(Array)
- m.Clear()
-}
-
-
-func (m *HashMap) Probe (key KeyType) *Entry {
- ASSERT(key != nil)
-
- var i uint32 = key.Hash() % m.capacity()
- ASSERT(0 <= i && i < m.capacity())
-
- ASSERT(m.occupancy_ < m.capacity()) // guarantees loop termination
- for m.map_[i].key != nil && !m.map_[i].key.Match(key) {
- i++
- if i >= m.capacity() {
- i = 0
- }
- }
-
- return &m.map_[i]
-}
-
-
-func (m *HashMap) Lookup (key KeyType, insert bool) *Entry {
- // Find a matching entry.
- var p *Entry = m.Probe(key)
- if p.key != nil {
- return p
- }
-
- // No entry found; insert one if necessary.
- if insert {
- p.key = key
- p.value = nil
- m.occupancy_++
-
- // Grow the map if we reached >= 80% occupancy.
- if m.occupancy_ + m.occupancy_/4 >= m.capacity() {
- m.Resize()
- p = m.Probe(key)
- }
-
- return p
- }
-
- // No entry found and none inserted.
- return nil
-}
-
-
-func (m *HashMap) Resize() {
- var hmap *Array = m.map_
- var n uint32 = m.occupancy_
-
- // Allocate a new map of twice the current size.
- m.Initialize(m.log2_capacity_ << 1)
-
- // Rehash all current entries.
- var i uint32 = 0
- for n > 0 {
- if hmap[i].key != nil {
- m.Lookup(hmap[i].key, true).value = hmap[i].value
- n = n - 1
- }
- i++
- }
-}
-
-
-// ----------------------------------------------------------------------------
-// Test code
-
-type Number struct {
- x uint32
-}
-
-
-func (n *Number) Hash() uint32 {
- return n.x * 23
-}
-
-
-func (n *Number) Match(other KeyType) bool {
- // var y *Number = other
- // return n.x == y.x
- return false
-}
-
-
-func MakeNumber (x uint32) *Number {
- var n *Number = new(Number)
- n.x = x
- return n
-}
-
-
-func main() {
- // func (n int) int { return n + 1; }(1)
-
- //print "HashMap - gri 2/8/2008\n"
-
- var hmap *HashMap = new(HashMap)
- hmap.Initialize(0)
-
- var x1 *Number = MakeNumber(1001)
- var x2 *Number = MakeNumber(2002)
- var x3 *Number = MakeNumber(3003)
- _, _, _ = x1, x2, x3
-
- // this doesn't work I think...
- //hmap.Lookup(x1, true)
- //hmap.Lookup(x2, true)
- //hmap.Lookup(x3, true)
-
- //print "done\n"
-}
diff --git a/gcc/testsuite/go.test/test/helloworld.go b/gcc/testsuite/go.test/test/helloworld.go
index 16c95f006..5025ec9bb 100644
--- a/gcc/testsuite/go.test/test/helloworld.go
+++ b/gcc/testsuite/go.test/test/helloworld.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out 2>&1 | cmp - $D/$F.out
+// cmpout
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test that we can do page 1 of the C book.
+
package main
func main() {
diff --git a/gcc/testsuite/go.test/test/if.go b/gcc/testsuite/go.test/test/if.go
index 18a6715d7..25cc14164 100644
--- a/gcc/testsuite/go.test/test/if.go
+++ b/gcc/testsuite/go.test/test/if.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test if statements in various forms.
+
package main
func assertequal(is, shouldbe int, msg string) {
diff --git a/gcc/testsuite/go.test/test/import.go b/gcc/testsuite/go.test/test/import.go
index bd83dc3bd..d135cd284 100644
--- a/gcc/testsuite/go.test/test/import.go
+++ b/gcc/testsuite/go.test/test/import.go
@@ -1,11 +1,11 @@
-// $G $D/$F.go
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// check that when import gives multiple names
-// to a type, they're still all the same type
+// Test that when import gives multiple names
+// to a single type, they still all refer to the same type.
package main
diff --git a/gcc/testsuite/go.test/test/import1.go b/gcc/testsuite/go.test/test/import1.go
index ebd704ef9..56b29d58c 100644
--- a/gcc/testsuite/go.test/test/import1.go
+++ b/gcc/testsuite/go.test/test/import1.go
@@ -1,10 +1,11 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// check for import conflicts
+// Verify that import conflicts are detected by the compiler.
+// Does not compile.
package main
diff --git a/gcc/testsuite/go.test/test/import2.go b/gcc/testsuite/go.test/test/import2.go
index 0efc285fa..5c275f34b 100644
--- a/gcc/testsuite/go.test/test/import2.go
+++ b/gcc/testsuite/go.test/test/import2.go
@@ -1,9 +1,12 @@
-// true # used by import3
+// skip # used by import3
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Various declarations of exported variables and functions.
+// Imported by import3.go.
+
package p
var C1 chan <- chan int = (chan<- (chan int))(nil)
diff --git a/gcc/testsuite/go.test/test/import3.go b/gcc/testsuite/go.test/test/import3.go
index e4900b93d..0a5ba1d01 100644
--- a/gcc/testsuite/go.test/test/import3.go
+++ b/gcc/testsuite/go.test/test/import3.go
@@ -1,10 +1,13 @@
// $G $D/import2.go && $G $D/$F.go
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Check that all the types from import2.go made it
+// Test that all the types from import2.go made it
// intact and with the same meaning, by assigning to or using them.
package main
diff --git a/gcc/testsuite/go.test/test/import4.go b/gcc/testsuite/go.test/test/import4.go
index 1ae1d0e4a..f35f56781 100644
--- a/gcc/testsuite/go.test/test/import4.go
+++ b/gcc/testsuite/go.test/test/import4.go
@@ -1,12 +1,17 @@
// $G $D/empty.go && errchk $G $D/$F.go
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-package main
+// Verify that various kinds of "imported and not used"
+// errors are caught by the compiler.
+// Does not compile.
-// various kinds of imported and not used
+package main
// standard
import "fmt" // ERROR "imported and not used.*fmt"
diff --git a/gcc/testsuite/go.test/test/import5.go b/gcc/testsuite/go.test/test/import5.go
new file mode 100644
index 000000000..6480acff9
--- /dev/null
+++ b/gcc/testsuite/go.test/test/import5.go
@@ -0,0 +1,55 @@
+// errorcheck
+
+// Copyright 2009 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Verify that invalid imports are rejected by the compiler.
+// Does not compile.
+
+package main
+
+// Correct import paths.
+import _ "fmt"
+import _ `time`
+import _ "m\x61th"
+import _ "go/parser"
+
+// Correct import paths, but the packages don't exist.
+// Don't test.
+//import "a.b"
+//import "greek/αβ"
+
+// Import paths must be strings.
+import 42 // ERROR "import statement"
+import 'a' // ERROR "import statement"
+import 3.14 // ERROR "import statement"
+import 0.25i // ERROR "import statement"
+
+// Each of these pairs tests both `` vs "" strings
+// and also use of invalid characters spelled out as
+// escape sequences and written directly.
+// For example `"\x00"` tests import "\x00"
+// while "`\x00`" tests import `<actual-NUL-byte>`.
+import "" // ERROR "import path"
+import `` // ERROR "import path"
+import "\x00" // ERROR "import path"
+import `\x00` // ERROR "import path"
+import "\x7f" // ERROR "import path"
+import `\x7f` // ERROR "import path"
+import "a!" // ERROR "import path"
+import `a!` // ERROR "import path"
+import "a b" // ERROR "import path"
+import `a b` // ERROR "import path"
+import "a\\b" // ERROR "import path"
+import `a\\b` // ERROR "import path"
+import "\"`a`\"" // ERROR "import path"
+import `\"a\"` // ERROR "import path"
+import "\x80\x80" // ERROR "import path"
+import `\x80\x80` // ERROR "import path"
+import "\xFFFD" // ERROR "import path"
+import `\xFFFD` // ERROR "import path"
+
+// Invalid local imports.
+import "/foo" // ERROR "import path cannot be absolute path"
+import "c:/foo" // ERROR "import path contains invalid character"
diff --git a/gcc/testsuite/go.test/test/index.go b/gcc/testsuite/go.test/test/index.go
index 38aa33dd3..447d70896 100644
--- a/gcc/testsuite/go.test/test/index.go
+++ b/gcc/testsuite/go.test/test/index.go
@@ -4,11 +4,15 @@
// ./$A.out -pass 2 >tmp.go && errchk $G -e tmp.go
// rm -f tmp.go $A.out1
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
// Generate test of index and slice bounds checks.
+// The output is compiled and run.
package main
@@ -30,16 +34,20 @@ import (
type quad struct { x, y, z, w int }
const (
- cj = 11
- ci int = 12
- ci32 int32 = 13
- ci64 int64 = 14
+ cj = 100011
+ ci int = 100012
+ ci8 int8 = 115
+ ci16 int16 = 10016
+ ci32 int32 = 100013
+ ci64 int64 = 100014
ci64big int64 = 1<<31
ci64bigger int64 = 1<<32
chuge = 1<<100
cnj = -2
cni int = -3
+ cni8 int8 = -6
+ cni16 int16 = -7
cni32 int32 = -4
cni64 int64 = -5
cni64big int64 = -1<<31
@@ -47,16 +55,20 @@ const (
cnhuge = -1<<100
)
-var j int = 20
-var i int = 21
-var i32 int32 = 22
-var i64 int64 = 23
+var j int = 100020
+var i int = 100021
+var i8 int8 = 126
+var i16 int16 = 10025
+var i32 int32 = 100022
+var i64 int64 = 100023
var i64big int64 = 1<<31
var i64bigger int64 = 1<<32
var huge uint64 = 1<<64 - 1
var nj int = -10
var ni int = -11
+var ni8 int8 = -14
+var ni16 int16 = -15
var ni32 int32 = -12
var ni64 int64 = -13
var ni64big int64 = -1<<31
@@ -71,6 +83,14 @@ var sq []quad = make([]quad, 10)
var aq [10]quad
var paq *[10]quad = &aq
+var sib []int = make([]int, 100000)
+var aib [100000]int
+var paib *[100000]int = &aib
+
+var sqb []quad = make([]quad, 100000)
+var aqb [100000]quad
+var paqb *[100000]quad = &aqb
+
type T struct {
si []int
ai [10]int
@@ -78,11 +98,18 @@ type T struct {
sq []quad
aq [10]quad
paq *[10]quad
+
+ sib []int
+ aib [100000]int
+ paib *[100000]int
+ sqb []quad
+ aqb [100000]quad
+ paqb *[100000]quad
}
-var t = T{si, ai, pai, sq, aq, paq}
+var t = T{si, ai, pai, sq, aq, paq, sib, aib, paib, sqb, aqb, paqb}
-var pt = &T{si, ai, pai, sq, aq, paq}
+var pt = &T{si, ai, pai, sq, aq, paq, sib, aib, paib, sqb, aqb, paqb}
// test that f panics
func test(f func(), s string) {
@@ -91,11 +118,25 @@ func test(f func(), s string) {
_, file, line, _ := runtime.Caller(2)
bug()
print(file, ":", line, ": ", s, " did not panic\n")
+ } else if !contains(err.(error).Error(), "out of range") {
+ _, file, line, _ := runtime.Caller(2)
+ bug()
+ print(file, ":", line, ": ", s, " unexpected panic: ", err.(error).Error(), "\n")
}
}()
f()
}
+func contains(x, y string) bool {
+ for i := 0; i+len(y) <= len(x); i++ {
+ if x[i:i+len(y)] == y {
+ return true
+ }
+ }
+ return false
+}
+
+
var X interface{}
func use(y interface{}) {
X = y
@@ -146,11 +187,14 @@ func main() {
// Array, pointer to array, slice.
[]string{"a", "pa", "s"},
-
+
// Element is int, element is quad (struct).
// This controls whether we end up in gsubr.c (i) or cgen.c (q).
[]string{"i", "q"},
+ // Small or big len.
+ []string{"", "b"},
+
// Variable or constant.
[]string{"", "c"},
@@ -158,11 +202,11 @@ func main() {
[]string{"", "n"},
// Size of index.
- []string{"j", "i", "i32", "i64", "i64big", "i64bigger", "huge"},
+ []string{"j", "i", "i8", "i16", "i32", "i64", "i64big", "i64bigger", "huge"},
}
forall(choices, func(x []string) {
- p, a, e, c, n, i := x[0], x[1], x[2], x[3], x[4], x[5]
+ p, a, e, big, c, n, i := x[0], x[1], x[2], x[3], x[4], x[5], x[6]
// Pass: dynamic=0, static=1, 2.
// Which cases should be caught statically?
@@ -184,10 +228,15 @@ func main() {
thisPass = 2
}
}
+
+ // If we're using the big-len data, positive int8 and int16 cannot overflow.
+ if big == "b" && n == "" && (i == "i8" || i == "i16") {
+ return
+ }
// Only print the test case if it is appropriate for this pass.
if thisPass == *pass {
- pae := p+a+e
+ pae := p+a+e+big
cni := c+n+i
// Index operation
diff --git a/gcc/testsuite/go.test/test/indirect.go b/gcc/testsuite/go.test/test/indirect.go
index cfddde9ce..bb20f3009 100644
--- a/gcc/testsuite/go.test/test/indirect.go
+++ b/gcc/testsuite/go.test/test/indirect.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG indirect
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test various safe uses of indirection.
+
package main
var m0 map[string]int
diff --git a/gcc/testsuite/go.test/test/indirect1.go b/gcc/testsuite/go.test/test/indirect1.go
index ecb4f138a..51da4cc7c 100644
--- a/gcc/testsuite/go.test/test/indirect1.go
+++ b/gcc/testsuite/go.test/test/indirect1.go
@@ -1,9 +1,12 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that illegal uses of indirection are caught by the compiler.
+// Does not compile.
+
package main
var m0 map[string]int
diff --git a/gcc/testsuite/go.test/test/init.go b/gcc/testsuite/go.test/test/init.go
index 74c2d5c26..f4689443c 100644
--- a/gcc/testsuite/go.test/test/init.go
+++ b/gcc/testsuite/go.test/test/init.go
@@ -1,9 +1,12 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that erroneous use of init is detected.
+// Does not compile.
+
package main
import "runtime"
diff --git a/gcc/testsuite/go.test/test/init1.go b/gcc/testsuite/go.test/test/init1.go
index 9ce3c12ee..a888ad744 100644
--- a/gcc/testsuite/go.test/test/init1.go
+++ b/gcc/testsuite/go.test/test/init1.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
@@ -16,10 +16,11 @@ func init() {
c := make(chan int)
go send(c)
<-c
-
- const chunk = 1<<20
- runtime.UpdateMemStats()
- sys := runtime.MemStats.Sys
+
+ const chunk = 1 << 20
+ memstats := new(runtime.MemStats)
+ runtime.ReadMemStats(memstats)
+ sys := memstats.Sys
b := make([]byte, chunk)
for i := range b {
b[i] = byte(i%10 + '0')
@@ -28,8 +29,8 @@ func init() {
for i := 0; i < 1000; i++ {
x = []byte(s)
}
- runtime.UpdateMemStats()
- sys1 := runtime.MemStats.Sys
+ runtime.ReadMemStats(memstats)
+ sys1 := memstats.Sys
if sys1-sys > chunk*50 {
println("allocated 1000 chunks of", chunk, "and used ", sys1-sys, "memory")
}
@@ -41,4 +42,3 @@ func send(c chan int) {
func main() {
}
-
diff --git a/gcc/testsuite/go.test/test/initcomma.go b/gcc/testsuite/go.test/test/initcomma.go
index 195d4575f..a54fce428 100644
--- a/gcc/testsuite/go.test/test/initcomma.go
+++ b/gcc/testsuite/go.test/test/initcomma.go
@@ -1,15 +1,17 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test trailing commas. DO NOT gofmt THIS FILE.
+
package main
-var a = []int{1, 2}
-var b = [5]int{1, 2, 3}
-var c = []int{1}
-var d = [...]int{1, 2, 3}
+var a = []int{1, 2, }
+var b = [5]int{1, 2, 3, }
+var c = []int{1, }
+var d = [...]int{1, 2, 3, }
func main() {
if len(a) != 2 {
diff --git a/gcc/testsuite/go.test/test/initialize.go b/gcc/testsuite/go.test/test/initialize.go
index 6dd7d67dc..1307e0209 100644
--- a/gcc/testsuite/go.test/test/initialize.go
+++ b/gcc/testsuite/go.test/test/initialize.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test initialization of package-level variables.
+
package main
import "fmt"
diff --git a/gcc/testsuite/go.test/test/initializerr.go b/gcc/testsuite/go.test/test/initializerr.go
index e7f8b0e92..48908c347 100644
--- a/gcc/testsuite/go.test/test/initializerr.go
+++ b/gcc/testsuite/go.test/test/initializerr.go
@@ -1,9 +1,12 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that erroneous initialization expressions are caught by the compiler
+// Does not compile.
+
package main
type S struct {
diff --git a/gcc/testsuite/go.test/test/initsyscall.go b/gcc/testsuite/go.test/test/initsyscall.go
deleted file mode 100644
index d0c26d2a8..000000000
--- a/gcc/testsuite/go.test/test/initsyscall.go
+++ /dev/null
@@ -1,26 +0,0 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
-
-// Copyright 2009 The Go Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style
-// license that can be found in the LICENSE file.
-
-// This used to crash because the scheduler
-// tried to kick off a new scheduling thread for f
-// when time.Nanoseconds went into the system call.
-// It's not okay to schedule new goroutines
-// until main has started.
-
-package main
-
-import "time"
-
-func f() {
-}
-
-func init() {
- go f()
- time.Now()
-}
-
-func main() {
-}
diff --git a/gcc/testsuite/go.test/test/int_lit.go b/gcc/testsuite/go.test/test/int_lit.go
index 2644e17b5..78deaea13 100644
--- a/gcc/testsuite/go.test/test/int_lit.go
+++ b/gcc/testsuite/go.test/test/int_lit.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test integer literal syntax.
+
package main
import "os"
diff --git a/gcc/testsuite/go.test/test/intcvt.go b/gcc/testsuite/go.test/test/intcvt.go
index 407bcfd9b..3920528a4 100644
--- a/gcc/testsuite/go.test/test/intcvt.go
+++ b/gcc/testsuite/go.test/test/intcvt.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test implicit and explicit conversions of constants.
+
package main
const (
diff --git a/gcc/testsuite/go.test/test/interface/bigdata.go b/gcc/testsuite/go.test/test/interface/bigdata.go
index 44f6ab127..0f2e9a990 100644
--- a/gcc/testsuite/go.test/test/interface/bigdata.go
+++ b/gcc/testsuite/go.test/test/interface/bigdata.go
@@ -1,11 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// check that big vs small, pointer vs not
-// interface methods work.
+// Test big vs. small, pointer vs. value interface methods.
package main
diff --git a/gcc/testsuite/go.test/test/interface/convert.go b/gcc/testsuite/go.test/test/interface/convert.go
index 7f429f703..eb6fd1d55 100644
--- a/gcc/testsuite/go.test/test/interface/convert.go
+++ b/gcc/testsuite/go.test/test/interface/convert.go
@@ -1,11 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Check uses of all the different interface
-// conversion runtime functions.
+// Test all the different interface conversion runtime functions.
package main
diff --git a/gcc/testsuite/go.test/test/interface/convert1.go b/gcc/testsuite/go.test/test/interface/convert1.go
index 658b1a92f..4a3ec8a37 100644
--- a/gcc/testsuite/go.test/test/interface/convert1.go
+++ b/gcc/testsuite/go.test/test/interface/convert1.go
@@ -1,11 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Check that static interface conversion of
-// interface value nil succeeds.
+// Test static interface conversion of interface value nil.
package main
diff --git a/gcc/testsuite/go.test/test/interface/convert2.go b/gcc/testsuite/go.test/test/interface/convert2.go
index 658b1a92f..4a3ec8a37 100644
--- a/gcc/testsuite/go.test/test/interface/convert2.go
+++ b/gcc/testsuite/go.test/test/interface/convert2.go
@@ -1,11 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Check that static interface conversion of
-// interface value nil succeeds.
+// Test static interface conversion of interface value nil.
package main
diff --git a/gcc/testsuite/go.test/test/interface/embed.go b/gcc/testsuite/go.test/test/interface/embed.go
index 2fddee190..5c52ac023 100644
--- a/gcc/testsuite/go.test/test/interface/embed.go
+++ b/gcc/testsuite/go.test/test/interface/embed.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Check methods derived from embedded interface values.
+// Test methods derived from embedded interface values.
package main
diff --git a/gcc/testsuite/go.test/test/interface/embed0.go b/gcc/testsuite/go.test/test/interface/embed0.go
index bbd81e760..e2ee20ade 100644
--- a/gcc/testsuite/go.test/test/interface/embed0.go
+++ b/gcc/testsuite/go.test/test/interface/embed0.go
@@ -1,10 +1,10 @@
-// true # used by embed1.go
+// skip # used by embed1.go
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Check that embedded interface types can have local methods.
+// Test that embedded interface types can have local methods.
package p
diff --git a/gcc/testsuite/go.test/test/interface/embed1.go b/gcc/testsuite/go.test/test/interface/embed1.go
index 24e50471f..07b873a63 100644
--- a/gcc/testsuite/go.test/test/interface/embed1.go
+++ b/gcc/testsuite/go.test/test/interface/embed1.go
@@ -1,10 +1,13 @@
// $G $D/embed0.go && $G $D/$F.go && $L $F.$A && ./$A.out
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Check that embedded interface types can have local methods.
+// Test that embedded interface types can have local methods.
package main
diff --git a/gcc/testsuite/go.test/test/interface/embed2.go b/gcc/testsuite/go.test/test/interface/embed2.go
index c18a1fece..1636db78e 100644
--- a/gcc/testsuite/go.test/test/interface/embed2.go
+++ b/gcc/testsuite/go.test/test/interface/embed2.go
@@ -1,10 +1,10 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Check methods derived from embedded interface and *interface values.
+// Test methods derived from embedded interface and *interface values.
package main
diff --git a/gcc/testsuite/go.test/test/interface/explicit.go b/gcc/testsuite/go.test/test/interface/explicit.go
index daae59b36..eb81156e0 100644
--- a/gcc/testsuite/go.test/test/interface/explicit.go
+++ b/gcc/testsuite/go.test/test/interface/explicit.go
@@ -1,10 +1,11 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Static error messages about interface conversions.
+// Verify compiler messages about erroneous static interface conversions.
+// Does not compile.
package main
@@ -14,6 +15,10 @@ type T struct {
var t *T
+type X int
+
+func (x *X) M() {}
+
type I interface {
M()
}
@@ -39,7 +44,7 @@ func main() {
// because i has an extra method
// that t does not, so i cannot contain a t.
i = t // ERROR "incompatible|missing M method"
- t = i // ERROR "incompatible|need type assertion"
+ t = i // ERROR "incompatible|assignment$"
i = i2 // ok
i2 = i // ERROR "incompatible|missing N method"
@@ -65,6 +70,8 @@ func (Int) M(float64) {}
var _ = m.(Int) // ERROR "impossible type assertion"
+var _ = m.(X) // ERROR "pointer receiver"
+
var ii int
var jj Int
diff --git a/gcc/testsuite/go.test/test/interface/fail.go b/gcc/testsuite/go.test/test/interface/fail.go
index 0c20bcf75..72b854dc0 100644
--- a/gcc/testsuite/go.test/test/interface/fail.go
+++ b/gcc/testsuite/go.test/test/interface/fail.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Check that interface conversion fails when method is missing.
+// Test that interface conversion fails when method is missing.
package main
diff --git a/gcc/testsuite/go.test/test/interface/fake.go b/gcc/testsuite/go.test/test/interface/fake.go
index ddb832542..861a64084 100644
--- a/gcc/testsuite/go.test/test/interface/fake.go
+++ b/gcc/testsuite/go.test/test/interface/fake.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Interface comparisons using types hidden
+// Test interface comparisons using types hidden
// inside reflected-on structs.
package main
diff --git a/gcc/testsuite/go.test/test/interface/noeq.go b/gcc/testsuite/go.test/test/interface/noeq.go
index 3c2ea5975..1c5166ede 100644
--- a/gcc/testsuite/go.test/test/interface/noeq.go
+++ b/gcc/testsuite/go.test/test/interface/noeq.go
@@ -1,10 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG: interface/noeq
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Interface values containing types that cannot be compared for equality.
+// Test run-time error detection for interface values containing types
+// that cannot be compared for equality.
package main
diff --git a/gcc/testsuite/go.test/test/interface/pointer.go b/gcc/testsuite/go.test/test/interface/pointer.go
index f1e363cbf..292705066 100644
--- a/gcc/testsuite/go.test/test/interface/pointer.go
+++ b/gcc/testsuite/go.test/test/interface/pointer.go
@@ -1,10 +1,11 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Check that interface{M()} = *interface{M()} produces a compiler error.
+// Test that interface{M()} = *interface{M()} produces a compiler error.
+// Does not compile.
package main
diff --git a/gcc/testsuite/go.test/test/interface/private.go b/gcc/testsuite/go.test/test/interface/private.go
index 37890c923..0a42385ea 100644
--- a/gcc/testsuite/go.test/test/interface/private.go
+++ b/gcc/testsuite/go.test/test/interface/private.go
@@ -1,9 +1,15 @@
// $G $D/${F}1.go && errchk $G $D/$F.go
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test that unexported methods are not visible outside the package.
+// Does not compile.
+
package main
import "./private1"
diff --git a/gcc/testsuite/go.test/test/interface/private1.go b/gcc/testsuite/go.test/test/interface/private1.go
index 3173fbef4..3281c38be 100644
--- a/gcc/testsuite/go.test/test/interface/private1.go
+++ b/gcc/testsuite/go.test/test/interface/private1.go
@@ -1,9 +1,11 @@
-// true # used by private.go
+// skip # used by private.go
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Imported by private.go, which should not be able to see the private method.
+
package p
type Exported interface {
diff --git a/gcc/testsuite/go.test/test/interface/receiver.go b/gcc/testsuite/go.test/test/interface/receiver.go
index f53daf8da..4511ab3b4 100644
--- a/gcc/testsuite/go.test/test/interface/receiver.go
+++ b/gcc/testsuite/go.test/test/interface/receiver.go
@@ -1,11 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Implicit methods for embedded types.
-// Mixed pointer and non-pointer receivers.
+// Test Implicit methods for embedded types and
+// mixed pointer and non-pointer receivers.
package main
diff --git a/gcc/testsuite/go.test/test/interface/receiver1.go b/gcc/testsuite/go.test/test/interface/receiver1.go
index 51312d000..2b7ccdc1a 100644
--- a/gcc/testsuite/go.test/test/interface/receiver1.go
+++ b/gcc/testsuite/go.test/test/interface/receiver1.go
@@ -1,10 +1,11 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Error messages about missing implicit methods.
+// Verify compiler complains about missing implicit methods.
+// Does not compile.
package main
diff --git a/gcc/testsuite/go.test/test/interface/recursive.go b/gcc/testsuite/go.test/test/interface/recursive.go
index 1eb56e976..fcc88331e 100644
--- a/gcc/testsuite/go.test/test/interface/recursive.go
+++ b/gcc/testsuite/go.test/test/interface/recursive.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go || echo BUG: should compile
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
@@ -6,7 +6,7 @@
// Check mutually recursive interfaces
-package main
+package recursive
type I1 interface {
foo() I2
diff --git a/gcc/testsuite/go.test/test/interface/recursive1.go b/gcc/testsuite/go.test/test/interface/recursive1.go
index 2c93a2836..cc3cdc37f 100644
--- a/gcc/testsuite/go.test/test/interface/recursive1.go
+++ b/gcc/testsuite/go.test/test/interface/recursive1.go
@@ -1,9 +1,11 @@
-// true # used by recursive2
+// skip # used by recursive2
// Copyright 2012 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Mutually recursive type definitions imported and used by recursive1.go.
+
package p
type I1 interface {
diff --git a/gcc/testsuite/go.test/test/interface/recursive2.go b/gcc/testsuite/go.test/test/interface/recursive2.go
index a7f9ab5db..3a1059960 100644
--- a/gcc/testsuite/go.test/test/interface/recursive2.go
+++ b/gcc/testsuite/go.test/test/interface/recursive2.go
@@ -1,10 +1,13 @@
// $G $D/recursive1.go && $G $D/$F.go
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2012 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Check that the mutually recursive types in recursive1.go made it
+// Test that the mutually recursive types in recursive1.go made it
// intact and with the same meaning, by assigning to or using them.
package main
diff --git a/gcc/testsuite/go.test/test/interface/returntype.go b/gcc/testsuite/go.test/test/interface/returntype.go
index 5cf083617..4d86f3918 100644
--- a/gcc/testsuite/go.test/test/interface/returntype.go
+++ b/gcc/testsuite/go.test/test/interface/returntype.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Check methods with different return types.
+// Test interface methods with different return types are distinct.
package main
diff --git a/gcc/testsuite/go.test/test/interface/struct.go b/gcc/testsuite/go.test/test/interface/struct.go
index 40b7f4f91..f60819ca8 100644
--- a/gcc/testsuite/go.test/test/interface/struct.go
+++ b/gcc/testsuite/go.test/test/interface/struct.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG interface6
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Interface values containing structures.
+// Test interface values containing structures.
package main
diff --git a/gcc/testsuite/go.test/test/iota.go b/gcc/testsuite/go.test/test/iota.go
index c40ca1f38..7187dbe33 100644
--- a/gcc/testsuite/go.test/test/iota.go
+++ b/gcc/testsuite/go.test/test/iota.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test iota.
+
package main
func assert(cond bool, msg string) {
diff --git a/gcc/testsuite/go.test/test/ken/array.go b/gcc/testsuite/go.test/test/ken/array.go
index 40209f5da..9412e3502 100644
--- a/gcc/testsuite/go.test/test/ken/array.go
+++ b/gcc/testsuite/go.test/test/ken/array.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test arrays and slices.
+
package main
func setpd(a []int) {
@@ -68,6 +70,9 @@ func testpdpd() {
a = a[5:25]
res(sumpd(a), 5, 25)
+
+ a = a[30:95]
+ res(sumpd(a), 35, 100)
}
// call ptr fixed with ptr fixed
diff --git a/gcc/testsuite/go.test/test/ken/chan.go b/gcc/testsuite/go.test/test/ken/chan.go
index ef75b044d..36b18f80e 100644
--- a/gcc/testsuite/go.test/test/ken/chan.go
+++ b/gcc/testsuite/go.test/test/ken/chan.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test communication operations including select.
+
package main
import "os"
diff --git a/gcc/testsuite/go.test/test/ken/chan1.go b/gcc/testsuite/go.test/test/ken/chan1.go
index e5fc033f3..cbd21a3d6 100644
--- a/gcc/testsuite/go.test/test/ken/chan1.go
+++ b/gcc/testsuite/go.test/test/ken/chan1.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test communication with multiple simultaneous goroutines.
+
package main
import "runtime"
diff --git a/gcc/testsuite/go.test/test/ken/complit.go b/gcc/testsuite/go.test/test/ken/complit.go
index da0a84a04..bc50bbe22 100644
--- a/gcc/testsuite/go.test/test/ken/complit.go
+++ b/gcc/testsuite/go.test/test/ken/complit.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test composite literals.
+
package main
type M map[int]int
diff --git a/gcc/testsuite/go.test/test/ken/convert.go b/gcc/testsuite/go.test/test/ken/convert.go
index 3780ec886..33acbd8cd 100644
--- a/gcc/testsuite/go.test/test/ken/convert.go
+++ b/gcc/testsuite/go.test/test/ken/convert.go
@@ -1,10 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// near-exhaustive test of converting numbers between types.
+// Test, near-exhaustive, of converting numbers between types.
+// No complex numbers though.
package main
diff --git a/gcc/testsuite/go.test/test/ken/cplx0.go b/gcc/testsuite/go.test/test/ken/cplx0.go
index f38ce5b65..665e52a5f 100644
--- a/gcc/testsuite/go.test/test/ken/cplx0.go
+++ b/gcc/testsuite/go.test/test/ken/cplx0.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out 2>&1 | cmp - $D/$F.out
+// cmpout
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test trivial, bootstrap-level complex numbers, including printing.
+
package main
const (
diff --git a/gcc/testsuite/go.test/test/ken/cplx1.go b/gcc/testsuite/go.test/test/ken/cplx1.go
index 8ec7d40f5..78240a563 100644
--- a/gcc/testsuite/go.test/test/ken/cplx1.go
+++ b/gcc/testsuite/go.test/test/ken/cplx1.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test simple arithmetic and assignment for complex numbers.
+
package main
const (
diff --git a/gcc/testsuite/go.test/test/ken/cplx2.go b/gcc/testsuite/go.test/test/ken/cplx2.go
index 89f4a0418..eb1da7b8c 100644
--- a/gcc/testsuite/go.test/test/ken/cplx2.go
+++ b/gcc/testsuite/go.test/test/ken/cplx2.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test arithmetic on complex numbers, including multiplication and division.
+
package main
const (
diff --git a/gcc/testsuite/go.test/test/ken/cplx3.go b/gcc/testsuite/go.test/test/ken/cplx3.go
index 048c93eef..be0b8646a 100644
--- a/gcc/testsuite/go.test/test/ken/cplx3.go
+++ b/gcc/testsuite/go.test/test/ken/cplx3.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test composition, decomposition, and reflection on complex numbers.
+
package main
import "unsafe"
diff --git a/gcc/testsuite/go.test/test/ken/cplx4.go b/gcc/testsuite/go.test/test/ken/cplx4.go
index 738afcd2c..97d5d16f4 100644
--- a/gcc/testsuite/go.test/test/ken/cplx4.go
+++ b/gcc/testsuite/go.test/test/ken/cplx4.go
@@ -1,9 +1,12 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test complex numbers,including fmt support.
+// Used to crash.
+
package main
import "fmt"
diff --git a/gcc/testsuite/go.test/test/ken/cplx5.go b/gcc/testsuite/go.test/test/ken/cplx5.go
index e6696674b..4e8f4433d 100644
--- a/gcc/testsuite/go.test/test/ken/cplx5.go
+++ b/gcc/testsuite/go.test/test/ken/cplx5.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test compound types made of complex numbers.
+
package main
var a [12]complex128
diff --git a/gcc/testsuite/go.test/test/ken/divconst.go b/gcc/testsuite/go.test/test/ken/divconst.go
index 5a64d16b4..670e07417 100644
--- a/gcc/testsuite/go.test/test/ken/divconst.go
+++ b/gcc/testsuite/go.test/test/ken/divconst.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test integer division by constants.
+
package main
import "math/rand"
diff --git a/gcc/testsuite/go.test/test/ken/divmod.go b/gcc/testsuite/go.test/test/ken/divmod.go
index dc44ea245..f1bd56ec6 100644
--- a/gcc/testsuite/go.test/test/ken/divmod.go
+++ b/gcc/testsuite/go.test/test/ken/divmod.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test integer division and modulus.
+
package main
const (
diff --git a/gcc/testsuite/go.test/test/ken/embed.go b/gcc/testsuite/go.test/test/ken/embed.go
index 9805e479b..9b35c56ac 100644
--- a/gcc/testsuite/go.test/test/ken/embed.go
+++ b/gcc/testsuite/go.test/test/ken/embed.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test embedded fields of structs, including methods.
+
package main
diff --git a/gcc/testsuite/go.test/test/ken/for.go b/gcc/testsuite/go.test/test/ken/for.go
index 176ecd749..db35548db 100644
--- a/gcc/testsuite/go.test/test/ken/for.go
+++ b/gcc/testsuite/go.test/test/ken/for.go
@@ -1,9 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test simple for loop.
package main
diff --git a/gcc/testsuite/go.test/test/ken/interbasic.go b/gcc/testsuite/go.test/test/ken/interbasic.go
index 9bb50886a..d8fbb95a3 100644
--- a/gcc/testsuite/go.test/test/ken/interbasic.go
+++ b/gcc/testsuite/go.test/test/ken/interbasic.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test interfaces on basic types.
+
package main
type myint int
diff --git a/gcc/testsuite/go.test/test/ken/interfun.go b/gcc/testsuite/go.test/test/ken/interfun.go
index 94bc7eaad..9432181df 100644
--- a/gcc/testsuite/go.test/test/ken/interfun.go
+++ b/gcc/testsuite/go.test/test/ken/interfun.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test interfaces and methods.
+
package main
type S struct {
diff --git a/gcc/testsuite/go.test/test/ken/intervar.go b/gcc/testsuite/go.test/test/ken/intervar.go
index 73d1b0660..8a2fca0d4 100644
--- a/gcc/testsuite/go.test/test/ken/intervar.go
+++ b/gcc/testsuite/go.test/test/ken/intervar.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test interface assignment.
+
package main
type Iputs interface {
diff --git a/gcc/testsuite/go.test/test/ken/label.go b/gcc/testsuite/go.test/test/ken/label.go
index 7a509f048..fcb3e611d 100644
--- a/gcc/testsuite/go.test/test/ken/label.go
+++ b/gcc/testsuite/go.test/test/ken/label.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test goto and labels.
+
package main
func main() {
diff --git a/gcc/testsuite/go.test/test/ken/litfun.go b/gcc/testsuite/go.test/test/ken/litfun.go
index bac2bc17c..e241d4edb 100644
--- a/gcc/testsuite/go.test/test/ken/litfun.go
+++ b/gcc/testsuite/go.test/test/ken/litfun.go
@@ -1,9 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test simple function literals.
package main
diff --git a/gcc/testsuite/go.test/test/ken/mfunc.go b/gcc/testsuite/go.test/test/ken/mfunc.go
index ae0bc0c58..ef2499194 100644
--- a/gcc/testsuite/go.test/test/ken/mfunc.go
+++ b/gcc/testsuite/go.test/test/ken/mfunc.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test simple multi-argument multi-valued function.
+
package main
func
diff --git a/gcc/testsuite/go.test/test/ken/modconst.go b/gcc/testsuite/go.test/test/ken/modconst.go
index c2603a0a0..d88cf1003 100644
--- a/gcc/testsuite/go.test/test/ken/modconst.go
+++ b/gcc/testsuite/go.test/test/ken/modconst.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test integer modulus by contstants.
+
package main
import "math/rand"
diff --git a/gcc/testsuite/go.test/test/ken/ptrfun.go b/gcc/testsuite/go.test/test/ken/ptrfun.go
index 6739ba33a..af806cfd9 100644
--- a/gcc/testsuite/go.test/test/ken/ptrfun.go
+++ b/gcc/testsuite/go.test/test/ken/ptrfun.go
@@ -1,9 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test method invocation with pointer receivers and function-valued fields.
package main
diff --git a/gcc/testsuite/go.test/test/ken/ptrvar.go b/gcc/testsuite/go.test/test/ken/ptrvar.go
index e2ddde629..d78170c9d 100644
--- a/gcc/testsuite/go.test/test/ken/ptrvar.go
+++ b/gcc/testsuite/go.test/test/ken/ptrvar.go
@@ -1,9 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test pointers and the . (selector) operator on structs.
package main
diff --git a/gcc/testsuite/go.test/test/ken/range.go b/gcc/testsuite/go.test/test/ken/range.go
index 9535fd497..89c14e5c3 100644
--- a/gcc/testsuite/go.test/test/ken/range.go
+++ b/gcc/testsuite/go.test/test/ken/range.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test 'for range' on arrays, slices, and maps.
+
package main
const size = 16
diff --git a/gcc/testsuite/go.test/test/ken/rob1.go b/gcc/testsuite/go.test/test/ken/rob1.go
index a5854b93e..3042a671b 100644
--- a/gcc/testsuite/go.test/test/ken/rob1.go
+++ b/gcc/testsuite/go.test/test/ken/rob1.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test general operation using a list implementation.
+
package main
type Item interface {
diff --git a/gcc/testsuite/go.test/test/ken/rob2.go b/gcc/testsuite/go.test/test/ken/rob2.go
index d13e2441d..4b4410ee8 100644
--- a/gcc/testsuite/go.test/test/ken/rob2.go
+++ b/gcc/testsuite/go.test/test/ken/rob2.go
@@ -1,9 +1,12 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test general operation using s-list.
+// First Go program ever run (although not in this exact form).
+
package main
import "fmt"
diff --git a/gcc/testsuite/go.test/test/ken/robfor.go b/gcc/testsuite/go.test/test/ken/robfor.go
index 05188a472..c6a420b39 100644
--- a/gcc/testsuite/go.test/test/ken/robfor.go
+++ b/gcc/testsuite/go.test/test/ken/robfor.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test for loops of many forms.
+
package main
func assertequal(is, shouldbe int, msg string) {
diff --git a/gcc/testsuite/go.test/test/ken/robfunc.go b/gcc/testsuite/go.test/test/ken/robfunc.go
index 6b3d4b2e4..885267e30 100644
--- a/gcc/testsuite/go.test/test/ken/robfunc.go
+++ b/gcc/testsuite/go.test/test/ken/robfunc.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test functions of many signatures.
+
package main
func assertequal(is, shouldbe int, msg string) {
diff --git a/gcc/testsuite/go.test/test/ken/shift.go b/gcc/testsuite/go.test/test/ken/shift.go
index 157a07aec..af8789615 100644
--- a/gcc/testsuite/go.test/test/ken/shift.go
+++ b/gcc/testsuite/go.test/test/ken/shift.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test shift.
+
package main
var ians [18]int;
diff --git a/gcc/testsuite/go.test/test/ken/simparray.go b/gcc/testsuite/go.test/test/ken/simparray.go
index 1b6f245ee..0e81a341b 100644
--- a/gcc/testsuite/go.test/test/ken/simparray.go
+++ b/gcc/testsuite/go.test/test/ken/simparray.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test simple operations on arrays.
+
package main
var b[10] float32;
diff --git a/gcc/testsuite/go.test/test/ken/simpbool.go b/gcc/testsuite/go.test/test/ken/simpbool.go
index dbd9c8d8b..ab2ecc21a 100644
--- a/gcc/testsuite/go.test/test/ken/simpbool.go
+++ b/gcc/testsuite/go.test/test/ken/simpbool.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test basic operations on bool.
+
package main
type s struct {
diff --git a/gcc/testsuite/go.test/test/ken/simpconv.go b/gcc/testsuite/go.test/test/ken/simpconv.go
index feb85d299..22cad2ad0 100644
--- a/gcc/testsuite/go.test/test/ken/simpconv.go
+++ b/gcc/testsuite/go.test/test/ken/simpconv.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test simple arithmetic conversion.
+
package main
type vlong int64
diff --git a/gcc/testsuite/go.test/test/ken/simpfun.go b/gcc/testsuite/go.test/test/ken/simpfun.go
index ba9ce6f7b..e5dc2b249 100644
--- a/gcc/testsuite/go.test/test/ken/simpfun.go
+++ b/gcc/testsuite/go.test/test/ken/simpfun.go
@@ -1,9 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test simple functions.
package main
diff --git a/gcc/testsuite/go.test/test/ken/simpswitch.go b/gcc/testsuite/go.test/test/ken/simpswitch.go
index 710af2e08..b28250b1d 100644
--- a/gcc/testsuite/go.test/test/ken/simpswitch.go
+++ b/gcc/testsuite/go.test/test/ken/simpswitch.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test simple switch.
+
package main
func main() {
diff --git a/gcc/testsuite/go.test/test/ken/simpvar.go b/gcc/testsuite/go.test/test/ken/simpvar.go
index fd060b0e2..c6eefbb5a 100644
--- a/gcc/testsuite/go.test/test/ken/simpvar.go
+++ b/gcc/testsuite/go.test/test/ken/simpvar.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test scoping of variables.
+
package main
diff --git a/gcc/testsuite/go.test/test/ken/slicearray.go b/gcc/testsuite/go.test/test/ken/slicearray.go
index 5c31270fc..6cf676c58 100644
--- a/gcc/testsuite/go.test/test/ken/slicearray.go
+++ b/gcc/testsuite/go.test/test/ken/slicearray.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test basic operations of slices and arrays.
+
package main
var bx [10]byte
diff --git a/gcc/testsuite/go.test/test/ken/sliceslice.go b/gcc/testsuite/go.test/test/ken/sliceslice.go
index 639042128..c07c59125 100644
--- a/gcc/testsuite/go.test/test/ken/sliceslice.go
+++ b/gcc/testsuite/go.test/test/ken/sliceslice.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test slicing and re-slicing.
+
package main
var bx []byte
diff --git a/gcc/testsuite/go.test/test/ken/string.go b/gcc/testsuite/go.test/test/ken/string.go
index e05108242..6df8dc4dd 100644
--- a/gcc/testsuite/go.test/test/ken/string.go
+++ b/gcc/testsuite/go.test/test/ken/string.go
@@ -1,9 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out 2>&1 | cmp - $D/$F.out
+// cmpout
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test string operations including printing.
package main
diff --git a/gcc/testsuite/go.test/test/ken/strvar.go b/gcc/testsuite/go.test/test/ken/strvar.go
index dfaaf1213..4d511fe67 100644
--- a/gcc/testsuite/go.test/test/ken/strvar.go
+++ b/gcc/testsuite/go.test/test/ken/strvar.go
@@ -1,9 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test struct-valued variables (not pointers).
package main
diff --git a/gcc/testsuite/go.test/test/label.go b/gcc/testsuite/go.test/test/label.go
index e3d853266..b30c27ec4 100644
--- a/gcc/testsuite/go.test/test/label.go
+++ b/gcc/testsuite/go.test/test/label.go
@@ -1,10 +1,12 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Pass 1 label errors.
+// Verify that erroneous labels are caught by the compiler.
+// This set is caught by pass 1.
+// Does not compile.
package main
diff --git a/gcc/testsuite/go.test/test/label1.go b/gcc/testsuite/go.test/test/label1.go
index 656daaeea..f923a1882 100644
--- a/gcc/testsuite/go.test/test/label1.go
+++ b/gcc/testsuite/go.test/test/label1.go
@@ -1,10 +1,13 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Pass 2 label errors.
+
+// Verify that erroneous labels are caught by the compiler.
+// This set is caught by pass 2. That's why this file is label1.go.
+// Does not compile.
package main
diff --git a/gcc/testsuite/go.test/test/linkx.go b/gcc/testsuite/go.test/test/linkx.go
new file mode 100644
index 000000000..12d446ffc
--- /dev/null
+++ b/gcc/testsuite/go.test/test/linkx.go
@@ -0,0 +1,20 @@
+// $G $D/$F.go && $L -X main.tbd hello $F.$A && ./$A.out
+
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Test the -X facility of the gc linker (6l etc.).
+
+package main
+
+var tbd string
+
+func main() {
+ if tbd != "hello" {
+ println("BUG: test/linkx", len(tbd), tbd)
+ }
+}
diff --git a/gcc/testsuite/go.test/test/literal.go b/gcc/testsuite/go.test/test/literal.go
index bf0538812..ba185fc9a 100644
--- a/gcc/testsuite/go.test/test/literal.go
+++ b/gcc/testsuite/go.test/test/literal.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test literal syntax for basic types.
+
package main
var nbad int
diff --git a/gcc/testsuite/go.test/test/mallocfin.go b/gcc/testsuite/go.test/test/mallocfin.go
index ff6239247..be6d79b2b 100644
--- a/gcc/testsuite/go.test/test/mallocfin.go
+++ b/gcc/testsuite/go.test/test/mallocfin.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// trivial finalizer test
+// Test basic operation of finalizers.
package main
diff --git a/gcc/testsuite/go.test/test/map.go b/gcc/testsuite/go.test/test/map.go
index c3963499b..6dec0dfd7 100644
--- a/gcc/testsuite/go.test/test/map.go
+++ b/gcc/testsuite/go.test/test/map.go
@@ -1,14 +1,18 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test maps, almost exhaustively.
+
package main
import (
"fmt"
+ "math"
"strconv"
+ "time"
)
const count = 100
@@ -26,6 +30,12 @@ func P(a []string) string {
}
func main() {
+ testbasic()
+ testfloat()
+ testnan()
+}
+
+func testbasic() {
// Test a map literal.
mlit := map[string]int{"0": 0, "1": 1, "2": 2, "3": 3, "4": 4}
for i := 0; i < len(mlit); i++ {
@@ -479,7 +489,7 @@ func main() {
mipM[i][i]++
if mipM[i][i] != (i+1)+1 {
- fmt.Printf("update mipM[%d][%d] = %i\n", i, i, mipM[i][i])
+ fmt.Printf("update mipM[%d][%d] = %d\n", i, i, mipM[i][i])
}
}
@@ -489,3 +499,195 @@ func main() {
panic("range mnil")
}
}
+
+func testfloat() {
+ // Test floating point numbers in maps.
+ // Two map keys refer to the same entry if the keys are ==.
+ // The special cases, then, are that +0 == -0 and that NaN != NaN.
+
+ {
+ var (
+ pz = float32(0)
+ nz = math.Float32frombits(1 << 31)
+ nana = float32(math.NaN())
+ nanb = math.Float32frombits(math.Float32bits(nana) ^ 2)
+ )
+
+ m := map[float32]string{
+ pz: "+0",
+ nana: "NaN",
+ nanb: "NaN",
+ }
+ if m[pz] != "+0" {
+ fmt.Println("float32 map cannot read back m[+0]:", m[pz])
+ }
+ if m[nz] != "+0" {
+ fmt.Println("float32 map does not treat", pz, "and", nz, "as equal for read")
+ fmt.Println("float32 map does not treat -0 and +0 as equal for read")
+ }
+ m[nz] = "-0"
+ if m[pz] != "-0" {
+ fmt.Println("float32 map does not treat -0 and +0 as equal for write")
+ }
+ if _, ok := m[nana]; ok {
+ fmt.Println("float32 map allows NaN lookup (a)")
+ }
+ if _, ok := m[nanb]; ok {
+ fmt.Println("float32 map allows NaN lookup (b)")
+ }
+ if len(m) != 3 {
+ fmt.Println("float32 map should have 3 entries:", m)
+ }
+ m[nana] = "NaN"
+ m[nanb] = "NaN"
+ if len(m) != 5 {
+ fmt.Println("float32 map should have 5 entries:", m)
+ }
+ }
+
+ {
+ var (
+ pz = float64(0)
+ nz = math.Float64frombits(1 << 63)
+ nana = float64(math.NaN())
+ nanb = math.Float64frombits(math.Float64bits(nana) ^ 2)
+ )
+
+ m := map[float64]string{
+ pz: "+0",
+ nana: "NaN",
+ nanb: "NaN",
+ }
+ if m[nz] != "+0" {
+ fmt.Println("float64 map does not treat -0 and +0 as equal for read")
+ }
+ m[nz] = "-0"
+ if m[pz] != "-0" {
+ fmt.Println("float64 map does not treat -0 and +0 as equal for write")
+ }
+ if _, ok := m[nana]; ok {
+ fmt.Println("float64 map allows NaN lookup (a)")
+ }
+ if _, ok := m[nanb]; ok {
+ fmt.Println("float64 map allows NaN lookup (b)")
+ }
+ if len(m) != 3 {
+ fmt.Println("float64 map should have 3 entries:", m)
+ }
+ m[nana] = "NaN"
+ m[nanb] = "NaN"
+ if len(m) != 5 {
+ fmt.Println("float64 map should have 5 entries:", m)
+ }
+ }
+
+ {
+ var (
+ pz = complex64(0)
+ nz = complex(0, math.Float32frombits(1<<31))
+ nana = complex(5, float32(math.NaN()))
+ nanb = complex(5, math.Float32frombits(math.Float32bits(float32(math.NaN()))^2))
+ )
+
+ m := map[complex64]string{
+ pz: "+0",
+ nana: "NaN",
+ nanb: "NaN",
+ }
+ if m[nz] != "+0" {
+ fmt.Println("complex64 map does not treat -0 and +0 as equal for read")
+ }
+ m[nz] = "-0"
+ if m[pz] != "-0" {
+ fmt.Println("complex64 map does not treat -0 and +0 as equal for write")
+ }
+ if _, ok := m[nana]; ok {
+ fmt.Println("complex64 map allows NaN lookup (a)")
+ }
+ if _, ok := m[nanb]; ok {
+ fmt.Println("complex64 map allows NaN lookup (b)")
+ }
+ if len(m) != 3 {
+ fmt.Println("complex64 map should have 3 entries:", m)
+ }
+ m[nana] = "NaN"
+ m[nanb] = "NaN"
+ if len(m) != 5 {
+ fmt.Println("complex64 map should have 5 entries:", m)
+ }
+ }
+
+ {
+ var (
+ pz = complex128(0)
+ nz = complex(0, math.Float64frombits(1<<63))
+ nana = complex(5, float64(math.NaN()))
+ nanb = complex(5, math.Float64frombits(math.Float64bits(float64(math.NaN()))^2))
+ )
+
+ m := map[complex128]string{
+ pz: "+0",
+ nana: "NaN",
+ nanb: "NaN",
+ }
+ if m[nz] != "+0" {
+ fmt.Println("complex128 map does not treat -0 and +0 as equal for read")
+ }
+ m[nz] = "-0"
+ if m[pz] != "-0" {
+ fmt.Println("complex128 map does not treat -0 and +0 as equal for write")
+ }
+ if _, ok := m[nana]; ok {
+ fmt.Println("complex128 map allows NaN lookup (a)")
+ }
+ if _, ok := m[nanb]; ok {
+ fmt.Println("complex128 map allows NaN lookup (b)")
+ }
+ if len(m) != 3 {
+ fmt.Println("complex128 map should have 3 entries:", m)
+ }
+ m[nana] = "NaN"
+ m[nanb] = "NaN"
+ if len(m) != 5 {
+ fmt.Println("complex128 map should have 5 entries:", m)
+ }
+ }
+}
+
+func testnan() {
+ // Test that NaNs in maps don't go quadratic.
+ t := func(n int) time.Duration {
+ t0 := time.Now()
+ m := map[float64]int{}
+ nan := math.NaN()
+ for i := 0; i < n; i++ {
+ m[nan] = 1
+ }
+ if len(m) != n {
+ panic("wrong size map after nan insertion")
+ }
+ return time.Since(t0)
+ }
+
+ // Depending on the machine and OS, this test might be too fast
+ // to measure with accurate enough granularity. On failure,
+ // make it run longer, hoping that the timing granularity
+ // is eventually sufficient.
+
+ n := 30000 // 0.02 seconds on a MacBook Air
+ fails := 0
+ for {
+ t1 := t(n)
+ t2 := t(2 * n)
+ // should be 2x (linear); allow up to 3x
+ if t2 < 3*t1 {
+ return
+ }
+ fails++
+ if fails == 4 {
+ fmt.Printf("too slow: %d inserts: %v; %d inserts: %v\n", n, t1, 2*n, t2)
+ return
+ }
+ n *= 2
+ }
+}
diff --git a/gcc/testsuite/go.test/test/map1.go b/gcc/testsuite/go.test/test/map1.go
index 6af10565c..6f1a1c8ac 100644
--- a/gcc/testsuite/go.test/test/map1.go
+++ b/gcc/testsuite/go.test/test/map1.go
@@ -1,9 +1,12 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test map declarations of many types, including erroneous ones.
+// Does not compile.
+
package main
func main() {}
@@ -38,4 +41,22 @@ var (
_ map[[]int]v // ERROR "invalid map key"
_ map[func()]v // ERROR "invalid map key"
_ map[map[int]int]v // ERROR "invalid map key"
+ _ map[T1]v // ERROR "invalid map key"
+ _ map[T2]v // ERROR "invalid map key"
+ _ map[T3]v // ERROR "invalid map key"
+ _ map[T4]v // ERROR "invalid map key"
+ _ map[T5]v
+ _ map[T6]v
+ _ map[T7]v
+ _ map[T8]v
)
+
+type T1 []int
+type T2 struct { F T1 }
+type T3 []T4
+type T4 struct { F T3 }
+
+type T5 *int
+type T6 struct { F T5 }
+type T7 *T4
+type T8 struct { F *T7 }
diff --git a/gcc/testsuite/go.test/test/method.go b/gcc/testsuite/go.test/test/method.go
index b5a02c687..0c239afbd 100644
--- a/gcc/testsuite/go.test/test/method.go
+++ b/gcc/testsuite/go.test/test/method.go
@@ -1,9 +1,12 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test simple methods of various types, with pointer and
+// value receivers.
+
package main
type S string
@@ -91,27 +94,27 @@ func main() {
}
if val(s) != 1 {
- println("s.val:", val(s))
+ println("val(s):", val(s))
panic("fail")
}
if val(ps) != 2 {
- println("ps.val:", val(ps))
+ println("val(ps):", val(ps))
panic("fail")
}
if val(i) != 3 {
- println("i.val:", val(i))
+ println("val(i):", val(i))
panic("fail")
}
if val(pi) != 4 {
- println("pi.val:", val(pi))
+ println("val(pi):", val(pi))
panic("fail")
}
if val(t) != 7 {
- println("t.val:", val(t))
+ println("val(t):", val(t))
panic("fail")
}
if val(pt) != 8 {
- println("pt.val:", val(pt))
+ println("val(pt):", val(pt))
panic("fail")
}
@@ -124,4 +127,124 @@ func main() {
println("Val.val(v):", Val.val(v))
panic("fail")
}
+
+ var zs struct { S }
+ var zps struct { *S1 }
+ var zi struct { I }
+ var zpi struct { *I1 }
+ var zpt struct { *T1 }
+ var zt struct { T }
+ var zv struct { Val }
+
+ if zs.val() != 1 {
+ println("zs.val:", zs.val())
+ panic("fail")
+ }
+ if zps.val() != 2 {
+ println("zps.val:", zps.val())
+ panic("fail")
+ }
+ if zi.val() != 3 {
+ println("zi.val:", zi.val())
+ panic("fail")
+ }
+ if zpi.val() != 4 {
+ println("zpi.val:", zpi.val())
+ panic("fail")
+ }
+ if zt.val() != 7 {
+ println("zt.val:", zt.val())
+ panic("fail")
+ }
+ if zpt.val() != 8 {
+ println("zpt.val:", zpt.val())
+ panic("fail")
+ }
+
+ if val(zs) != 1 {
+ println("val(zs):", val(zs))
+ panic("fail")
+ }
+ if val(zps) != 2 {
+ println("val(zps):", val(zps))
+ panic("fail")
+ }
+ if val(zi) != 3 {
+ println("val(zi):", val(zi))
+ panic("fail")
+ }
+ if val(zpi) != 4 {
+ println("val(zpi):", val(zpi))
+ panic("fail")
+ }
+ if val(zt) != 7 {
+ println("val(zt):", val(zt))
+ panic("fail")
+ }
+ if val(zpt) != 8 {
+ println("val(zpt):", val(zpt))
+ panic("fail")
+ }
+
+ zv.Val = zi
+ if zv.val() != 3 {
+ println("zv.val():", zv.val())
+ panic("fail")
+ }
+
+ if (&zs).val() != 1 {
+ println("(&zs).val:", (&zs).val())
+ panic("fail")
+ }
+ if (&zps).val() != 2 {
+ println("(&zps).val:", (&zps).val())
+ panic("fail")
+ }
+ if (&zi).val() != 3 {
+ println("(&zi).val:", (&zi).val())
+ panic("fail")
+ }
+ if (&zpi).val() != 4 {
+ println("(&zpi).val:", (&zpi).val())
+ panic("fail")
+ }
+ if (&zt).val() != 7 {
+ println("(&zt).val:", (&zt).val())
+ panic("fail")
+ }
+ if (&zpt).val() != 8 {
+ println("(&zpt).val:", (&zpt).val())
+ panic("fail")
+ }
+
+ if val(&zs) != 1 {
+ println("val(&zs):", val(&zs))
+ panic("fail")
+ }
+ if val(&zps) != 2 {
+ println("val(&zps):", val(&zps))
+ panic("fail")
+ }
+ if val(&zi) != 3 {
+ println("val(&zi):", val(&zi))
+ panic("fail")
+ }
+ if val(&zpi) != 4 {
+ println("val(&zpi):", val(&zpi))
+ panic("fail")
+ }
+ if val(&zt) != 7 {
+ println("val(&zt):", val(&zt))
+ panic("fail")
+ }
+ if val(&zpt) != 8 {
+ println("val(&zpt):", val(&zpt))
+ panic("fail")
+ }
+
+ zv.Val = &zi
+ if zv.val() != 3 {
+ println("zv.val():", zv.val())
+ panic("fail")
+ }
}
diff --git a/gcc/testsuite/go.test/test/method1.go b/gcc/testsuite/go.test/test/method1.go
index ec14ef9e4..365b8ca55 100644
--- a/gcc/testsuite/go.test/test/method1.go
+++ b/gcc/testsuite/go.test/test/method1.go
@@ -1,9 +1,12 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that method redeclarations are caught by the compiler.
+// Does not compile.
+
package main
type T struct { }
diff --git a/gcc/testsuite/go.test/test/method2.go b/gcc/testsuite/go.test/test/method2.go
index 039779efb..b63da10dc 100644
--- a/gcc/testsuite/go.test/test/method2.go
+++ b/gcc/testsuite/go.test/test/method2.go
@@ -1,9 +1,12 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that pointers and interface types cannot be method receivers.
+// Does not compile.
+
package main
type T struct {
diff --git a/gcc/testsuite/go.test/test/method3.go b/gcc/testsuite/go.test/test/method3.go
index 7946a8750..fd6477152 100644
--- a/gcc/testsuite/go.test/test/method3.go
+++ b/gcc/testsuite/go.test/test/method3.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG method3
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// test that methods on slices work
+// Test methods on slices.
package main
diff --git a/gcc/testsuite/go.test/test/method4.go b/gcc/testsuite/go.test/test/method4.go
new file mode 100644
index 000000000..7e7b1ff3b
--- /dev/null
+++ b/gcc/testsuite/go.test/test/method4.go
@@ -0,0 +1,109 @@
+// $G $D/method4a.go && $G $D/$F.go && $L $F.$A && ./$A.out
+
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Test method expressions with arguments.
+
+package main
+
+import "./method4a"
+
+type T1 int
+
+type T2 struct {
+ f int
+}
+
+type I1 interface {
+ Sum([]int, int) int
+}
+
+type I2 interface {
+ Sum(a []int, b int) int
+}
+
+func (i T1) Sum(a []int, b int) int {
+ r := int(i) + b
+ for _, v := range a {
+ r += v
+ }
+ return r
+}
+
+func (p *T2) Sum(a []int, b int) int {
+ r := p.f + b
+ for _, v := range a {
+ r += v
+ }
+ return r
+}
+
+func eq(v1, v2 int) {
+ if v1 != v2 {
+ panic(0)
+ }
+}
+
+func main() {
+ a := []int{1, 2, 3}
+ t1 := T1(4)
+ t2 := &T2{4}
+
+ eq(t1.Sum(a, 5), 15)
+ eq(t2.Sum(a, 6), 16)
+
+ eq(T1.Sum(t1, a, 7), 17)
+ eq((*T2).Sum(t2, a, 8), 18)
+
+ f1 := T1.Sum
+ eq(f1(t1, a, 9), 19)
+ f2 := (*T2).Sum
+ eq(f2(t2, a, 10), 20)
+
+ eq(I1.Sum(t1, a, 11), 21)
+ eq(I1.Sum(t2, a, 12), 22)
+
+ f3 := I1.Sum
+ eq(f3(t1, a, 13), 23)
+ eq(f3(t2, a, 14), 24)
+
+ eq(I2.Sum(t1, a, 15), 25)
+ eq(I2.Sum(t2, a, 16), 26)
+
+ f4 := I2.Sum
+ eq(f4(t1, a, 17), 27)
+ eq(f4(t2, a, 18), 28)
+
+ mt1 := method4a.T1(4)
+ mt2 := &method4a.T2{4}
+
+ eq(mt1.Sum(a, 30), 40)
+ eq(mt2.Sum(a, 31), 41)
+
+ eq(method4a.T1.Sum(mt1, a, 32), 42)
+ eq((*method4a.T2).Sum(mt2, a, 33), 43)
+
+ g1 := method4a.T1.Sum
+ eq(g1(mt1, a, 34), 44)
+ g2 := (*method4a.T2).Sum
+ eq(g2(mt2, a, 35), 45)
+
+ eq(method4a.I1.Sum(mt1, a, 36), 46)
+ eq(method4a.I1.Sum(mt2, a, 37), 47)
+
+ g3 := method4a.I1.Sum
+ eq(g3(mt1, a, 38), 48)
+ eq(g3(mt2, a, 39), 49)
+
+ eq(method4a.I2.Sum(mt1, a, 40), 50)
+ eq(method4a.I2.Sum(mt2, a, 41), 51)
+
+ g4 := method4a.I2.Sum
+ eq(g4(mt1, a, 42), 52)
+ eq(g4(mt2, a, 43), 53)
+}
diff --git a/gcc/testsuite/go.test/test/method4a.go b/gcc/testsuite/go.test/test/method4a.go
new file mode 100644
index 000000000..d23039bfa
--- /dev/null
+++ b/gcc/testsuite/go.test/test/method4a.go
@@ -0,0 +1,40 @@
+// skip
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Test method expressions with arguments.
+// This file is not tested by itself; it is imported by method4.go.
+
+package method4a
+
+type T1 int
+
+type T2 struct {
+ F int
+}
+
+type I1 interface {
+ Sum([]int, int) int
+}
+
+type I2 interface {
+ Sum(a []int, b int) int
+}
+
+func (i T1) Sum(a []int, b int) int {
+ r := int(i) + b
+ for _, v := range a {
+ r += v
+ }
+ return r
+}
+
+func (p *T2) Sum(a []int, b int) int {
+ r := p.F + b
+ for _, v := range a {
+ r += v
+ }
+ return r
+}
diff --git a/gcc/testsuite/go.test/test/named.go b/gcc/testsuite/go.test/test/named.go
index 5b6bb81fe..d0330ab23 100644
--- a/gcc/testsuite/go.test/test/named.go
+++ b/gcc/testsuite/go.test/test/named.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/named1.go b/gcc/testsuite/go.test/test/named1.go
index 561d84a43..62b874c5c 100644
--- a/gcc/testsuite/go.test/test/named1.go
+++ b/gcc/testsuite/go.test/test/named1.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
@@ -6,6 +6,7 @@
// Test that basic operations on named types are valid
// and preserve the type.
+// Does not compile.
package main
diff --git a/gcc/testsuite/go.test/test/nil.go b/gcc/testsuite/go.test/test/nil.go
index efcf4f782..9f7bcbb59 100644
--- a/gcc/testsuite/go.test/test/nil.go
+++ b/gcc/testsuite/go.test/test/nil.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test nil.
+
package main
import (
diff --git a/gcc/testsuite/go.test/test/nilptr.go b/gcc/testsuite/go.test/test/nilptr.go
index b0c1df2d9..b784914e5 100644
--- a/gcc/testsuite/go.test/test/nilptr.go
+++ b/gcc/testsuite/go.test/test/nilptr.go
@@ -1,9 +1,12 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test that the implementation catches nil ptr indirection
+// in a large address space.
+
package main
import "unsafe"
diff --git a/gcc/testsuite/go.test/test/nul1.go b/gcc/testsuite/go.test/test/nul1.go
index 142d4deb1..968c95295 100644
--- a/gcc/testsuite/go.test/test/nul1.go
+++ b/gcc/testsuite/go.test/test/nul1.go
@@ -3,6 +3,9 @@
// errchk $G -e tmp.go
// rm -f tmp.go
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
diff --git a/gcc/testsuite/go.test/test/parentype.go b/gcc/testsuite/go.test/test/parentype.go
index 1872cd0eb..eafa07648 100644
--- a/gcc/testsuite/go.test/test/parentype.go
+++ b/gcc/testsuite/go.test/test/parentype.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go
+// compile
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test that types can be parenthesized.
+
package main
func f(interface{})
diff --git a/gcc/testsuite/go.test/test/peano.go b/gcc/testsuite/go.test/test/peano.go
index dd4c36e0b..745f5153f 100644
--- a/gcc/testsuite/go.test/test/peano.go
+++ b/gcc/testsuite/go.test/test/peano.go
@@ -1,9 +1,12 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test that heavy recursion works. Simple torture test for
+// segmented stacks: do math in unary by recursion.
+
package main
type Number *Number
diff --git a/gcc/testsuite/go.test/test/printbig.go b/gcc/testsuite/go.test/test/printbig.go
index d867bdc64..5693c58d4 100644
--- a/gcc/testsuite/go.test/test/printbig.go
+++ b/gcc/testsuite/go.test/test/printbig.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out 2>&1 | cmp - $D/$F.out
+// cmpout
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test that big numbers work as constants and print can print them.
+
package main
func main() {
diff --git a/gcc/testsuite/go.test/test/range.go b/gcc/testsuite/go.test/test/range.go
index 84119450b..68b0c9a2f 100644
--- a/gcc/testsuite/go.test/test/range.go
+++ b/gcc/testsuite/go.test/test/range.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test the 'for range' construct.
+
package main
// test range over channels
@@ -56,6 +58,17 @@ func testslice() {
println("wrong sum ranging over makeslice")
panic("fail")
}
+
+ x := []int{10, 20}
+ y := []int{99}
+ i := 1
+ for i, x[i] = range y {
+ break
+ }
+ if i != 0 || x[0] != 10 || x[1] != 99 {
+ println("wrong parallel assignment", i, x[0], x[1])
+ panic("fail")
+ }
}
func testslice1() {
diff --git a/gcc/testsuite/go.test/test/recover.go b/gcc/testsuite/go.test/test/recover.go
index ca6f07288..eea655ec5 100644
--- a/gcc/testsuite/go.test/test/recover.go
+++ b/gcc/testsuite/go.test/test/recover.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
@@ -244,3 +244,30 @@ func test7() {
die()
}
}
+
+func varargs(s *int, a ...int) {
+ *s = 0
+ for _, v := range a {
+ *s += v
+ }
+ if recover() != nil {
+ *s += 100
+ }
+}
+
+func test8a() (r int) {
+ defer varargs(&r, 1, 2, 3)
+ panic(0)
+}
+
+func test8b() (r int) {
+ defer varargs(&r, 4, 5, 6)
+ return
+}
+
+func test8() {
+ if test8a() != 106 || test8b() != 15 {
+ println("wrong value")
+ die()
+ }
+}
diff --git a/gcc/testsuite/go.test/test/recover1.go b/gcc/testsuite/go.test/test/recover1.go
index db584738b..b763a1074 100644
--- a/gcc/testsuite/go.test/test/recover1.go
+++ b/gcc/testsuite/go.test/test/recover1.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/recover2.go b/gcc/testsuite/go.test/test/recover2.go
index b5db6f0d1..946d05ae6 100644
--- a/gcc/testsuite/go.test/test/recover2.go
+++ b/gcc/testsuite/go.test/test/recover2.go
@@ -1,4 +1,4 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/recover3.go b/gcc/testsuite/go.test/test/recover3.go
index 60ade9b61..98700231e 100644
--- a/gcc/testsuite/go.test/test/recover3.go
+++ b/gcc/testsuite/go.test/test/recover3.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test recovering from runtime errors.
+
package main
import (
diff --git a/gcc/testsuite/go.test/test/rename.go b/gcc/testsuite/go.test/test/rename.go
index f21ef015b..e54427455 100644
--- a/gcc/testsuite/go.test/test/rename.go
+++ b/gcc/testsuite/go.test/test/rename.go
@@ -1,73 +1,99 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test that predeclared names can be redeclared by the user.
+
package main
import "fmt"
func main() {
n :=
- bool +
+ append +
+ bool +
byte +
- float +
+ complex +
+ complex64 +
+ complex128 +
+ cap +
+ close +
+ delete +
+ error +
+ false +
float32 +
float64 +
+ imag +
int +
int8 +
int16 +
int32 +
int64 +
+ len +
+ make +
+ new +
+ nil +
+ panic +
+ print +
+ println +
+ real +
+ recover +
+ rune +
+ string +
+ true +
uint +
uint8 +
uint16 +
uint32 +
uint64 +
uintptr +
- true +
- false +
- iota +
- nil +
- cap +
- len +
- make +
- new +
- panic +
- print +
- println
- if n != 27*28/2 {
- fmt.Println("BUG: wrong n", n, 27*28/2)
+ iota
+ if n != NUM*(NUM-1)/2 {
+ fmt.Println("BUG: wrong n", n, NUM*(NUM-1)/2)
}
}
const (
- bool = 1
- byte = 2
- float = 3
- float32 = 4
- float64 = 5
- int = 6
- int8 = 7
- int16 = 8
- int32 = 9
- int64 = 10
- uint = 11
- uint8 = 12
- uint16 = 13
- uint32 = 14
- uint64 = 15
- uintptr = 16
- true = 17
- false = 18
- iota = 19
- nil = 20
- cap = 21
- len = 22
- make = 23
- new = 24
- panic = 25
- print = 26
- println = 27
+ // cannot use iota here, because iota = 38 below
+ append = 1
+ bool = 2
+ byte = 3
+ complex = 4
+ complex64 = 5
+ complex128 = 6
+ cap = 7
+ close = 8
+ delete = 9
+ error = 10
+ false = 11
+ float32 = 12
+ float64 = 13
+ imag = 14
+ int = 15
+ int8 = 16
+ int16 = 17
+ int32 = 18
+ int64 = 19
+ len = 20
+ make = 21
+ new = 22
+ nil = 23
+ panic = 24
+ print = 25
+ println = 26
+ real = 27
+ recover = 28
+ rune = 29
+ string = 30
+ true = 31
+ uint = 32
+ uint8 = 33
+ uint16 = 34
+ uint32 = 35
+ uint64 = 36
+ uintptr = 37
+ iota = 38
+ NUM = 39
)
diff --git a/gcc/testsuite/go.test/test/rename1.go b/gcc/testsuite/go.test/test/rename1.go
index 3e78bfca0..53db68de1 100644
--- a/gcc/testsuite/go.test/test/rename1.go
+++ b/gcc/testsuite/go.test/test/rename1.go
@@ -1,14 +1,17 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that renamed identifiers no longer have their old meaning.
+// Does not compile.
+
package main
func main() {
var n byte // ERROR "not a type|expected type"
- var y = float(0) // ERROR "cannot call|expected function"
+ var y = float32(0) // ERROR "cannot call|expected function"
const (
a = 1 + iota // ERROR "string|incompatible types" "convert iota"
)
@@ -16,31 +19,42 @@ func main() {
}
const (
- bool = 1
- byte = 2
- float = 3
- float32 = 4
- float64 = 5
- int = 6
- int8 = 7
- int16 = 8
- int32 = 9
- int64 = 10
- uint = 11
- uint8 = 12
- uint16 = 13
- uint32 = 14
- uint64 = 15
- uintptr = 16
- true = 17
- false = 18
- iota = "abc"
- nil = 20
- cap = 21
- len = 22
- make = 23
- new = 24
- panic = 25
- print = 26
- println = 27
+ append = 1
+ bool = 2
+ byte = 3
+ complex = 4
+ complex64 = 5
+ complex128 = 6
+ cap = 7
+ close = 8
+ delete = 9
+ error = 10
+ false = 11
+ float32 = 12
+ float64 = 13
+ imag = 14
+ int = 15
+ int8 = 16
+ int16 = 17
+ int32 = 18
+ int64 = 19
+ len = 20
+ make = 21
+ new = 22
+ nil = 23
+ panic = 24
+ print = 25
+ println = 26
+ real = 27
+ recover = 28
+ rune = 29
+ string = 30
+ true = 31
+ uint = 32
+ uint8 = 33
+ uint16 = 34
+ uint32 = 35
+ uint64 = 36
+ uintptr = 37
+ iota = "38"
)
diff --git a/gcc/testsuite/go.test/test/reorder.go b/gcc/testsuite/go.test/test/reorder.go
index 67d07523b..0cdeebd0f 100644
--- a/gcc/testsuite/go.test/test/reorder.go
+++ b/gcc/testsuite/go.test/test/reorder.go
@@ -1,10 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Check reordering of assignments.
+// Test reordering of assignments.
package main
@@ -19,6 +19,7 @@ func main() {
p6()
p7()
p8()
+ p9()
}
var gx []int
@@ -119,3 +120,11 @@ func p8() {
i := 0
i, x[i], x[5] = 1, 100, 500
}
+
+func p9() {
+ m := make(map[int]int)
+ m[0] = len(m)
+ if m[0] != 0 {
+ panic(m[0])
+ }
+}
diff --git a/gcc/testsuite/go.test/test/reorder2.go b/gcc/testsuite/go.test/test/reorder2.go
new file mode 100644
index 000000000..d91f1d895
--- /dev/null
+++ b/gcc/testsuite/go.test/test/reorder2.go
@@ -0,0 +1,174 @@
+// run
+
+// Copyright 2010 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Test reorderings; derived from fixedbugs/bug294.go.
+
+package main
+
+var log string
+
+type TT int
+
+func (t TT) a(s string) TT {
+ log += "a(" + s + ")"
+ return t
+}
+
+func (TT) b(s string) string {
+ log += "b(" + s + ")"
+ return s
+}
+
+type F func(s string) F
+
+func a(s string) F {
+ log += "a(" + s + ")"
+ return F(a)
+}
+
+func b(s string) string {
+ log += "b(" + s + ")"
+ return s
+}
+
+type I interface {
+ a(s string) I
+ b(s string) string
+}
+
+type T1 int
+
+func (t T1) a(s string) I {
+ log += "a(" + s + ")"
+ return t
+}
+
+func (T1) b(s string) string {
+ log += "b(" + s + ")"
+ return s
+}
+
+// f(g(), h()) where g is not inlinable but h is will have the same problem.
+// As will x := g() + h() (same conditions).
+// And g() <- h().
+func f(x, y string) {
+ log += "f(" + x + ", " + y + ")"
+}
+
+func ff(x, y string) {
+ for false {
+ } // prevent inl
+ log += "ff(" + x + ", " + y + ")"
+}
+
+func h(x string) string {
+ log += "h(" + x + ")"
+ return x
+}
+
+func g(x string) string {
+ for false {
+ } // prevent inl
+ log += "g(" + x + ")"
+ return x
+}
+
+func main() {
+ err := 0
+ var t TT
+ if a("1")("2")("3"); log != "a(1)a(2)a(3)" {
+ println("expecting a(1)a(2)a(3) , got ", log)
+ err++
+ }
+ log = ""
+
+ if t.a("1").a(t.b("2")); log != "a(1)b(2)a(2)" {
+ println("expecting a(1)b(2)a(2), got ", log)
+ err++
+ }
+ log = ""
+ if a("3")(b("4"))(b("5")); log != "a(3)b(4)a(4)b(5)a(5)" {
+ println("expecting a(3)b(4)a(4)b(5)a(5), got ", log)
+ err++
+ }
+ log = ""
+ var i I = T1(0)
+ if i.a("6").a(i.b("7")).a(i.b("8")).a(i.b("9")); log != "a(6)b(7)a(7)b(8)a(8)b(9)a(9)" {
+ println("expecting a(6)ba(7)ba(8)ba(9), got", log)
+ err++
+ }
+ log = ""
+
+ if s := t.a("1").b("3"); log != "a(1)b(3)" || s != "3" {
+ println("expecting a(1)b(3) and 3, got ", log, " and ", s)
+ err++
+ }
+ log = ""
+
+ if s := t.a("1").a(t.b("2")).b("3") + t.a("4").b("5"); log != "a(1)b(2)a(2)b(3)a(4)b(5)" || s != "35" {
+ println("expecting a(1)b(2)a(2)b(3)a(4)b(5) and 35, got ", log, " and ", s)
+ err++
+ }
+ log = ""
+
+ if s := t.a("4").b("5") + t.a("1").a(t.b("2")).b("3"); log != "a(4)b(5)a(1)b(2)a(2)b(3)" || s != "53" {
+ println("expecting a(4)b(5)a(1)b(2)a(2)b(3) and 35, got ", log, " and ", s)
+ err++
+ }
+ log = ""
+
+ if ff(g("1"), g("2")); log != "g(1)g(2)ff(1, 2)" {
+ println("expecting g(1)g(2)ff..., got ", log)
+ err++
+ }
+ log = ""
+
+ if ff(g("1"), h("2")); log != "g(1)h(2)ff(1, 2)" {
+ println("expecting g(1)h(2)ff..., got ", log)
+ err++
+ }
+ log = ""
+
+ if ff(h("1"), g("2")); log != "h(1)g(2)ff(1, 2)" {
+ println("expecting h(1)g(2)ff..., got ", log)
+ err++
+ }
+ log = ""
+
+ if ff(h("1"), h("2")); log != "h(1)h(2)ff(1, 2)" {
+ println("expecting h(1)h(2)ff..., got ", log)
+ err++
+ }
+ log = ""
+
+ if s := g("1") + g("2"); log != "g(1)g(2)" || s != "12" {
+ println("expecting g1g2 and 12, got ", log, " and ", s)
+ err++
+ }
+ log = ""
+
+ if s := g("1") + h("2"); log != "g(1)h(2)" || s != "12" {
+ println("expecting g1h2 and 12, got ", log, " and ", s)
+ err++
+ }
+ log = ""
+
+ if s := h("1") + g("2"); log != "h(1)g(2)" || s != "12" {
+ println("expecting h1g2 and 12, got ", log, " and ", s)
+ err++
+ }
+ log = ""
+
+ if s := h("1") + h("2"); log != "h(1)h(2)" || s != "12" {
+ println("expecting h1h2 and 12, got ", log, " and ", s)
+ err++
+ }
+ log = ""
+
+ if err > 0 {
+ panic("fail")
+ }
+}
diff --git a/gcc/testsuite/go.test/test/rotate.go b/gcc/testsuite/go.test/test/rotate.go
new file mode 100644
index 000000000..aa334b421
--- /dev/null
+++ b/gcc/testsuite/go.test/test/rotate.go
@@ -0,0 +1,171 @@
+// $G $D/$F.go && $L $F.$A &&
+// ./$A.out >tmp.go && $G tmp.go && $L -o $A.out1 tmp.$A && ./$A.out1
+// rm -f tmp.go $A.out1
+
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Generate test of shift and rotate by constants.
+// The output is compiled and run.
+//
+// The output takes around a gigabyte of memory to compile, link, and run
+// but it is only done during ./run, not in normal builds using run.go.
+
+package main
+
+import (
+ "bufio"
+ "flag"
+ "fmt"
+ "os"
+ "strings"
+)
+
+func main() {
+ flag.Parse()
+
+ b := bufio.NewWriter(os.Stdout)
+ defer b.Flush()
+
+ fmt.Fprintf(b, "%s\n", prolog)
+
+ for logBits := uint(3); logBits <= 6; logBits++ {
+ typ := fmt.Sprintf("int%d", 1<<logBits)
+ fmt.Fprint(b, strings.Replace(checkFunc, "XXX", typ, -1))
+ fmt.Fprint(b, strings.Replace(checkFunc, "XXX", "u"+typ, -1))
+ for mode := 0; mode < 1<<2; mode++ {
+ gentest(b, 1<<logBits, mode&1 != 0, mode&2 != 0)
+ }
+ }
+}
+
+const prolog = `
+
+package main
+
+import (
+ "fmt"
+ "os"
+)
+
+var (
+ i8 int8 = 0x12
+ i16 int16 = 0x1234
+ i32 int32 = 0x12345678
+ i64 int64 = 0x123456789abcdef0
+ ui8 uint8 = 0x12
+ ui16 uint16 = 0x1234
+ ui32 uint32 = 0x12345678
+ ui64 uint64 = 0x123456789abcdef0
+
+ ni8 = ^i8
+ ni16 = ^i16
+ ni32 = ^i32
+ ni64 = ^i64
+ nui8 = ^ui8
+ nui16 = ^ui16
+ nui32 = ^ui32
+ nui64 = ^ui64
+)
+
+var nfail = 0
+
+func main() {
+ if nfail > 0 {
+ fmt.Printf("BUG\n")
+ }
+}
+
+`
+
+const checkFunc = `
+func check_XXX(desc string, have, want XXX) {
+ if have != want {
+ nfail++
+ fmt.Printf("%s = %T(%#x), want %T(%#x)\n", desc, have, have, want, want)
+ if nfail >= 100 {
+ fmt.Printf("BUG: stopping after 100 failures\n")
+ os.Exit(0)
+ }
+ }
+}
+`
+
+var (
+ uop = [2]func(x, y uint64) uint64{
+ func(x, y uint64) uint64 {
+ return x | y
+ },
+ func(x, y uint64) uint64 {
+ return x ^ y
+ },
+ }
+ iop = [2]func(x, y int64) int64{
+ func(x, y int64) int64 {
+ return x | y
+ },
+ func(x, y int64) int64 {
+ return x ^ y
+ },
+ }
+ cop = [2]byte{'|', '^'}
+)
+
+func gentest(b *bufio.Writer, bits uint, unsigned, inverted bool) {
+ fmt.Fprintf(b, "func init() {\n")
+ defer fmt.Fprintf(b, "}\n")
+ n := 0
+
+ // Generate tests for left/right and right/left.
+ for l := uint(0); l <= bits; l++ {
+ for r := uint(0); r <= bits; r++ {
+ for o, op := range cop {
+ typ := fmt.Sprintf("int%d", bits)
+ v := fmt.Sprintf("i%d", bits)
+ if unsigned {
+ typ = "u" + typ
+ v = "u" + v
+ }
+ v0 := int64(0x123456789abcdef0)
+ if inverted {
+ v = "n" + v
+ v0 = ^v0
+ }
+ expr1 := fmt.Sprintf("%s<<%d %c %s>>%d", v, l, op, v, r)
+ expr2 := fmt.Sprintf("%s>>%d %c %s<<%d", v, r, op, v, l)
+
+ var result string
+ if unsigned {
+ v := uint64(v0) >> (64 - bits)
+ v = uop[o](v<<l, v>>r)
+ v <<= 64 - bits
+ v >>= 64 - bits
+ result = fmt.Sprintf("%#x", v)
+ } else {
+ v := int64(v0) >> (64 - bits)
+ v = iop[o](v<<l, v>>r)
+ v <<= 64 - bits
+ v >>= 64 - bits
+ result = fmt.Sprintf("%#x", v)
+ }
+
+ fmt.Fprintf(b, "\tcheck_%s(%q, %s, %s(%s))\n", typ, expr1, expr1, typ, result)
+ fmt.Fprintf(b, "\tcheck_%s(%q, %s, %s(%s))\n", typ, expr2, expr2, typ, result)
+
+ // Chop test into multiple functions so that there's not one
+ // enormous function to compile/link.
+ // All the functions are named init so we don't have to do
+ // anything special to call them. ☺
+ if n++; n >= 50 {
+ fmt.Fprintf(b, "}\n")
+ fmt.Fprintf(b, "func init() {\n")
+ n = 0
+ }
+ }
+ }
+ }
+}
diff --git a/gcc/testsuite/go.test/test/run b/gcc/testsuite/go.test/test/run
index 03c91ee30..d206312a2 100755
--- a/gcc/testsuite/go.test/test/run
+++ b/gcc/testsuite/go.test/test/run
@@ -3,8 +3,8 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-eval $(gomake --no-print-directory -f ../src/Make.inc go-env)
-
+eval $(go tool dist env)
+export GOARCH GOOS GOROOT
export E=
case X"$GOARCH" in
@@ -29,13 +29,18 @@ export GOTRACEBACK=0
export LANG=C
unset GREP_OPTIONS # in case user has a non-standard set
+unset GOROOT_FINAL # breaks ./ imports
+
failed=0
PATH=${GOBIN:-$GOROOT/bin}:`pwd`:/bin:/usr/bin:/usr/local/bin
-RUNFILE="/tmp/gorun-$$-$USER"
-TMP1FILE="/tmp/gotest1-$$-$USER"
-TMP2FILE="/tmp/gotest2-$$-$USER"
+# TODO: We add the tool directory to the PATH to avoid thinking about a better way.
+PATH="$GOTOOLDIR:$PATH"
+
+RUNFILE="${TMPDIR:-/tmp}/gorun-$$-$USER"
+TMP1FILE="${TMPDIR:-/tmp}/gotest1-$$-$USER"
+TMP2FILE="${TMPDIR:-/tmp}/gotest2-$$-$USER"
# don't run the machine out of memory: limit individual processes to 4GB.
# on thresher, 3GB suffices to run the tests; with 2GB, peano fails.
@@ -49,11 +54,13 @@ true >pass.out >times.out
exclude=false # exclude nothing
golden=golden.out
+rm -f tmp.go # generated by some tests, left behind if interrupted
+
filterout() {
grep '^'"$2"'$' $1 >/dev/null
}
-for dir in . ken chan interface syntax dwarf fixedbugs bugs
+for dir in . ken chan interface syntax dwarf safe fixedbugs bugs
do
echo
echo '==' $dir'/'
@@ -64,7 +71,8 @@ do
fi
export F=$(basename $i .go)
export D=$dir
- sed '/^\/\//!q' $i | sed 's@//@@; $d' |sed 's|./\$A.out|$E &|g' >"$RUNFILE"
+ echo '. ./testlib' >"$RUNFILE"
+ sed '/^\/\//!q' $i | sed 's@//@@; $d' |sed 's|./\$A.out|$E &|g' >>"$RUNFILE"
if ! { time -p bash -c "bash '$RUNFILE' >'$TMP1FILE' 2>&1" ; } 2>"$TMP2FILE"
then
echo
@@ -94,7 +102,7 @@ do
echo $i >>pass.out
fi
echo $(awk 'NR==1{print $2}' "$TMP2FILE") $D/$F >>times.out
- rm -f $F.$A $A.out
+ rm -f $F.$A $A.out tmp.go
) done
done | # clean up some stack noise
egrep -v '^(r[0-9a-z]+|[cfg]s) +0x' |
diff --git a/gcc/testsuite/go.test/test/run.go b/gcc/testsuite/go.test/test/run.go
new file mode 100644
index 000000000..10dbceff5
--- /dev/null
+++ b/gcc/testsuite/go.test/test/run.go
@@ -0,0 +1,607 @@
+// skip
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Run runs tests in the test directory.
+//
+// TODO(bradfitz): docs of some sort, once we figure out how we're changing
+// headers of files
+package main
+
+import (
+ "bytes"
+ "errors"
+ "flag"
+ "fmt"
+ "go/build"
+ "io/ioutil"
+ "log"
+ "os"
+ "os/exec"
+ "path"
+ "path/filepath"
+ "regexp"
+ "runtime"
+ "sort"
+ "strconv"
+ "strings"
+)
+
+var (
+ verbose = flag.Bool("v", false, "verbose. if set, parallelism is set to 1.")
+ numParallel = flag.Int("n", runtime.NumCPU(), "number of parallel tests to run")
+ summary = flag.Bool("summary", false, "show summary of results")
+ showSkips = flag.Bool("show_skips", false, "show skipped tests")
+)
+
+var (
+ // gc and ld are [568][gl].
+ gc, ld string
+
+ // letter is the build.ArchChar
+ letter string
+
+ // dirs are the directories to look for *.go files in.
+ // TODO(bradfitz): just use all directories?
+ dirs = []string{".", "ken", "chan", "interface", "syntax", "dwarf", "fixedbugs", "bugs"}
+
+ // ratec controls the max number of tests running at a time.
+ ratec chan bool
+
+ // toRun is the channel of tests to run.
+ // It is nil until the first test is started.
+ toRun chan *test
+)
+
+// maxTests is an upper bound on the total number of tests.
+// It is used as a channel buffer size to make sure sends don't block.
+const maxTests = 5000
+
+func main() {
+ flag.Parse()
+
+ // Disable parallelism if printing
+ if *verbose {
+ *numParallel = 1
+ }
+
+ ratec = make(chan bool, *numParallel)
+ var err error
+ letter, err = build.ArchChar(build.Default.GOARCH)
+ check(err)
+ gc = letter + "g"
+ ld = letter + "l"
+
+ var tests []*test
+ if flag.NArg() > 0 {
+ for _, arg := range flag.Args() {
+ if arg == "-" || arg == "--" {
+ // Permit running:
+ // $ go run run.go - env.go
+ // $ go run run.go -- env.go
+ // $ go run run.go - ./fixedbugs
+ // $ go run run.go -- ./fixedbugs
+ continue
+ }
+ if fi, err := os.Stat(arg); err == nil && fi.IsDir() {
+ for _, baseGoFile := range goFiles(arg) {
+ tests = append(tests, startTest(arg, baseGoFile))
+ }
+ } else if strings.HasSuffix(arg, ".go") {
+ dir, file := filepath.Split(arg)
+ tests = append(tests, startTest(dir, file))
+ } else {
+ log.Fatalf("can't yet deal with non-directory and non-go file %q", arg)
+ }
+ }
+ } else {
+ for _, dir := range dirs {
+ for _, baseGoFile := range goFiles(dir) {
+ tests = append(tests, startTest(dir, baseGoFile))
+ }
+ }
+ }
+
+ failed := false
+ resCount := map[string]int{}
+ for _, test := range tests {
+ <-test.donec
+ _, isSkip := test.err.(skipError)
+ errStr := "pass"
+ if test.err != nil {
+ errStr = test.err.Error()
+ if !isSkip {
+ failed = true
+ }
+ }
+ if isSkip && !skipOkay[path.Join(test.dir, test.gofile)] {
+ errStr = "unexpected skip for " + path.Join(test.dir, test.gofile) + ": " + errStr
+ isSkip = false
+ failed = true
+ }
+ resCount[errStr]++
+ if isSkip && !*verbose && !*showSkips {
+ continue
+ }
+ if !*verbose && test.err == nil {
+ continue
+ }
+ fmt.Printf("%-10s %-20s: %s\n", test.action, test.goFileName(), errStr)
+ }
+
+ if *summary {
+ for k, v := range resCount {
+ fmt.Printf("%5d %s\n", v, k)
+ }
+ }
+
+ if failed {
+ os.Exit(1)
+ }
+}
+
+func toolPath(name string) string {
+ p := filepath.Join(os.Getenv("GOROOT"), "bin", "tool", name)
+ if _, err := os.Stat(p); err != nil {
+ log.Fatalf("didn't find binary at %s", p)
+ }
+ return p
+}
+
+func goFiles(dir string) []string {
+ f, err := os.Open(dir)
+ check(err)
+ dirnames, err := f.Readdirnames(-1)
+ check(err)
+ names := []string{}
+ for _, name := range dirnames {
+ if !strings.HasPrefix(name, ".") && strings.HasSuffix(name, ".go") {
+ names = append(names, name)
+ }
+ }
+ sort.Strings(names)
+ return names
+}
+
+// skipError describes why a test was skipped.
+type skipError string
+
+func (s skipError) Error() string { return string(s) }
+
+func check(err error) {
+ if err != nil {
+ log.Fatal(err)
+ }
+}
+
+// test holds the state of a test.
+type test struct {
+ dir, gofile string
+ donec chan bool // closed when done
+
+ src string
+ action string // "compile", "build", "run", "errorcheck", "skip", "runoutput", "compiledir"
+
+ tempDir string
+ err error
+}
+
+// startTest
+func startTest(dir, gofile string) *test {
+ t := &test{
+ dir: dir,
+ gofile: gofile,
+ donec: make(chan bool, 1),
+ }
+ if toRun == nil {
+ toRun = make(chan *test, maxTests)
+ go runTests()
+ }
+ select {
+ case toRun <- t:
+ default:
+ panic("toRun buffer size (maxTests) is too small")
+ }
+ return t
+}
+
+// runTests runs tests in parallel, but respecting the order they
+// were enqueued on the toRun channel.
+func runTests() {
+ for {
+ ratec <- true
+ t := <-toRun
+ go func() {
+ t.run()
+ <-ratec
+ }()
+ }
+}
+
+var cwd, _ = os.Getwd()
+
+func (t *test) goFileName() string {
+ return filepath.Join(t.dir, t.gofile)
+}
+
+func (t *test) goDirName() string {
+ return filepath.Join(t.dir, strings.Replace(t.gofile, ".go", ".dir", -1))
+}
+
+// run runs a test.
+func (t *test) run() {
+ defer close(t.donec)
+
+ srcBytes, err := ioutil.ReadFile(t.goFileName())
+ if err != nil {
+ t.err = err
+ return
+ }
+ t.src = string(srcBytes)
+ if t.src[0] == '\n' {
+ t.err = skipError("starts with newline")
+ return
+ }
+ pos := strings.Index(t.src, "\n\n")
+ if pos == -1 {
+ t.err = errors.New("double newline not found")
+ return
+ }
+ action := t.src[:pos]
+ if strings.HasPrefix(action, "//") {
+ action = action[2:]
+ }
+
+ var args, flags []string
+ wantError := false
+ f := strings.Fields(action)
+ if len(f) > 0 {
+ action = f[0]
+ args = f[1:]
+ }
+
+ switch action {
+ case "cmpout":
+ action = "run" // the run case already looks for <dir>/<test>.out files
+ fallthrough
+ case "compile", "compiledir", "build", "run", "runoutput":
+ t.action = action
+ case "errorcheck":
+ t.action = action
+ wantError = true
+ for len(args) > 0 && strings.HasPrefix(args[0], "-") {
+ if args[0] == "-0" {
+ wantError = false
+ } else {
+ flags = append(flags, args[0])
+ }
+ args = args[1:]
+ }
+ case "skip":
+ t.action = "skip"
+ return
+ default:
+ t.err = skipError("skipped; unknown pattern: " + action)
+ t.action = "??"
+ return
+ }
+
+ t.makeTempDir()
+ defer os.RemoveAll(t.tempDir)
+
+ err = ioutil.WriteFile(filepath.Join(t.tempDir, t.gofile), srcBytes, 0644)
+ check(err)
+
+ // A few tests (of things like the environment) require these to be set.
+ os.Setenv("GOOS", runtime.GOOS)
+ os.Setenv("GOARCH", runtime.GOARCH)
+
+ useTmp := true
+ runcmd := func(args ...string) ([]byte, error) {
+ cmd := exec.Command(args[0], args[1:]...)
+ var buf bytes.Buffer
+ cmd.Stdout = &buf
+ cmd.Stderr = &buf
+ if useTmp {
+ cmd.Dir = t.tempDir
+ }
+ err := cmd.Run()
+ return buf.Bytes(), err
+ }
+
+ long := filepath.Join(cwd, t.goFileName())
+ switch action {
+ default:
+ t.err = fmt.Errorf("unimplemented action %q", action)
+
+ case "errorcheck":
+ cmdline := []string{"go", "tool", gc, "-e", "-o", "a." + letter}
+ cmdline = append(cmdline, flags...)
+ cmdline = append(cmdline, long)
+ out, err := runcmd(cmdline...)
+ if wantError {
+ if err == nil {
+ t.err = fmt.Errorf("compilation succeeded unexpectedly\n%s", out)
+ return
+ }
+ } else {
+ if err != nil {
+ t.err = fmt.Errorf("%s\n%s", err, out)
+ return
+ }
+ }
+ t.err = t.errorCheck(string(out), long, t.gofile)
+ return
+
+ case "compile":
+ out, err := runcmd("go", "tool", gc, "-e", "-o", "a."+letter, long)
+ if err != nil {
+ t.err = fmt.Errorf("%s\n%s", err, out)
+ }
+
+ case "compiledir":
+ // Compile all files in the directory in lexicographic order.
+ longdir := filepath.Join(cwd, t.goDirName())
+ files, dirErr := ioutil.ReadDir(longdir)
+ if dirErr != nil {
+ t.err = dirErr
+ return
+ }
+ for _, gofile := range files {
+ if filepath.Ext(gofile.Name()) != ".go" {
+ continue
+ }
+ afile := strings.Replace(gofile.Name(), ".go", "."+letter, -1)
+ out, err := runcmd("go", "tool", gc, "-e", "-D.", "-I.", "-o", afile, filepath.Join(longdir, gofile.Name()))
+ if err != nil {
+ t.err = fmt.Errorf("%s\n%s", err, out)
+ break
+ }
+ }
+
+ case "build":
+ out, err := runcmd("go", "build", "-o", "a.exe", long)
+ if err != nil {
+ t.err = fmt.Errorf("%s\n%s", err, out)
+ }
+
+ case "run":
+ useTmp = false
+ out, err := runcmd(append([]string{"go", "run", t.goFileName()}, args...)...)
+ if err != nil {
+ t.err = fmt.Errorf("%s\n%s", err, out)
+ }
+ if strings.Replace(string(out), "\r\n", "\n", -1) != t.expectedOutput() {
+ t.err = fmt.Errorf("incorrect output\n%s", out)
+ }
+
+ case "runoutput":
+ useTmp = false
+ out, err := runcmd("go", "run", t.goFileName())
+ if err != nil {
+ t.err = fmt.Errorf("%s\n%s", err, out)
+ }
+ tfile := filepath.Join(t.tempDir, "tmp__.go")
+ err = ioutil.WriteFile(tfile, out, 0666)
+ if err != nil {
+ t.err = fmt.Errorf("write tempfile:%s", err)
+ return
+ }
+ out, err = runcmd("go", "run", tfile)
+ if err != nil {
+ t.err = fmt.Errorf("%s\n%s", err, out)
+ }
+ if string(out) != t.expectedOutput() {
+ t.err = fmt.Errorf("incorrect output\n%s", out)
+ }
+ }
+}
+
+func (t *test) String() string {
+ return filepath.Join(t.dir, t.gofile)
+}
+
+func (t *test) makeTempDir() {
+ var err error
+ t.tempDir, err = ioutil.TempDir("", "")
+ check(err)
+}
+
+func (t *test) expectedOutput() string {
+ filename := filepath.Join(t.dir, t.gofile)
+ filename = filename[:len(filename)-len(".go")]
+ filename += ".out"
+ b, _ := ioutil.ReadFile(filename)
+ return string(b)
+}
+
+func (t *test) errorCheck(outStr string, full, short string) (err error) {
+ defer func() {
+ if *verbose && err != nil {
+ log.Printf("%s gc output:\n%s", t, outStr)
+ }
+ }()
+ var errs []error
+
+ var out []string
+ // 6g error messages continue onto additional lines with leading tabs.
+ // Split the output at the beginning of each line that doesn't begin with a tab.
+ for _, line := range strings.Split(outStr, "\n") {
+ if strings.HasSuffix(line, "\r") { // remove '\r', output by compiler on windows
+ line = line[:len(line)-1]
+ }
+ if strings.HasPrefix(line, "\t") {
+ out[len(out)-1] += "\n" + line
+ } else {
+ out = append(out, line)
+ }
+ }
+
+ // Cut directory name.
+ for i := range out {
+ out[i] = strings.Replace(out[i], full, short, -1)
+ }
+
+ for _, we := range t.wantedErrors() {
+ var errmsgs []string
+ errmsgs, out = partitionStrings(we.filterRe, out)
+ if len(errmsgs) == 0 {
+ errs = append(errs, fmt.Errorf("%s:%d: missing error %q", we.file, we.lineNum, we.reStr))
+ continue
+ }
+ matched := false
+ for _, errmsg := range errmsgs {
+ if we.re.MatchString(errmsg) {
+ matched = true
+ } else {
+ out = append(out, errmsg)
+ }
+ }
+ if !matched {
+ errs = append(errs, fmt.Errorf("%s:%d: no match for %q in%s", we.file, we.lineNum, we.reStr, strings.Join(out, "\n")))
+ continue
+ }
+ }
+
+ if len(errs) == 0 {
+ return nil
+ }
+ if len(errs) == 1 {
+ return errs[0]
+ }
+ var buf bytes.Buffer
+ fmt.Fprintf(&buf, "\n")
+ for _, err := range errs {
+ fmt.Fprintf(&buf, "%s\n", err.Error())
+ }
+ return errors.New(buf.String())
+
+}
+
+func partitionStrings(rx *regexp.Regexp, strs []string) (matched, unmatched []string) {
+ for _, s := range strs {
+ if rx.MatchString(s) {
+ matched = append(matched, s)
+ } else {
+ unmatched = append(unmatched, s)
+ }
+ }
+ return
+}
+
+type wantedError struct {
+ reStr string
+ re *regexp.Regexp
+ lineNum int
+ file string
+ filterRe *regexp.Regexp // /^file:linenum\b/m
+}
+
+var (
+ errRx = regexp.MustCompile(`// (?:GC_)?ERROR (.*)`)
+ errQuotesRx = regexp.MustCompile(`"([^"]*)"`)
+ lineRx = regexp.MustCompile(`LINE(([+-])([0-9]+))?`)
+)
+
+func (t *test) wantedErrors() (errs []wantedError) {
+ for i, line := range strings.Split(t.src, "\n") {
+ lineNum := i + 1
+ if strings.Contains(line, "////") {
+ // double comment disables ERROR
+ continue
+ }
+ m := errRx.FindStringSubmatch(line)
+ if m == nil {
+ continue
+ }
+ all := m[1]
+ mm := errQuotesRx.FindAllStringSubmatch(all, -1)
+ if mm == nil {
+ log.Fatalf("invalid errchk line in %s: %s", t.goFileName(), line)
+ }
+ for _, m := range mm {
+ rx := lineRx.ReplaceAllStringFunc(m[1], func(m string) string {
+ n := lineNum
+ if strings.HasPrefix(m, "LINE+") {
+ delta, _ := strconv.Atoi(m[5:])
+ n += delta
+ } else if strings.HasPrefix(m, "LINE-") {
+ delta, _ := strconv.Atoi(m[5:])
+ n -= delta
+ }
+ return fmt.Sprintf("%s:%d", t.gofile, n)
+ })
+ filterPattern := fmt.Sprintf(`^(\w+/)?%s:%d[:[]`, t.gofile, lineNum)
+ errs = append(errs, wantedError{
+ reStr: rx,
+ re: regexp.MustCompile(rx),
+ filterRe: regexp.MustCompile(filterPattern),
+ lineNum: lineNum,
+ file: t.gofile,
+ })
+ }
+ }
+
+ return
+}
+
+var skipOkay = map[string]bool{
+ "args.go": true,
+ "ddd3.go": true,
+ "import3.go": true,
+ "import4.go": true,
+ "index.go": true,
+ "linkx.go": true,
+ "method4.go": true,
+ "nul1.go": true,
+ "rotate.go": true,
+ "sigchld.go": true,
+ "sinit.go": true,
+ "interface/embed1.go": true,
+ "interface/private.go": true,
+ "interface/recursive2.go": true,
+ "dwarf/main.go": true,
+ "dwarf/z1.go": true,
+ "dwarf/z10.go": true,
+ "dwarf/z11.go": true,
+ "dwarf/z12.go": true,
+ "dwarf/z13.go": true,
+ "dwarf/z14.go": true,
+ "dwarf/z15.go": true,
+ "dwarf/z16.go": true,
+ "dwarf/z17.go": true,
+ "dwarf/z18.go": true,
+ "dwarf/z19.go": true,
+ "dwarf/z2.go": true,
+ "dwarf/z20.go": true,
+ "dwarf/z3.go": true,
+ "dwarf/z4.go": true,
+ "dwarf/z5.go": true,
+ "dwarf/z6.go": true,
+ "dwarf/z7.go": true,
+ "dwarf/z8.go": true,
+ "dwarf/z9.go": true,
+ "fixedbugs/bug083.go": true,
+ "fixedbugs/bug133.go": true,
+ "fixedbugs/bug160.go": true,
+ "fixedbugs/bug191.go": true,
+ "fixedbugs/bug248.go": true,
+ "fixedbugs/bug302.go": true,
+ "fixedbugs/bug313.go": true,
+ "fixedbugs/bug322.go": true,
+ "fixedbugs/bug324.go": true,
+ "fixedbugs/bug345.go": true,
+ "fixedbugs/bug367.go": true,
+ "fixedbugs/bug369.go": true,
+ "fixedbugs/bug382.go": true,
+ "fixedbugs/bug385_32.go": true,
+ "fixedbugs/bug385_64.go": true,
+ "fixedbugs/bug414.go": true,
+ "fixedbugs/bug424.go": true,
+ "fixedbugs/bug429.go": true,
+ "fixedbugs/bug437.go": true,
+ "bugs/bug395.go": true,
+ "bugs/bug434.go": true,
+}
diff --git a/gcc/testsuite/go.test/test/rune.go b/gcc/testsuite/go.test/test/rune.go
index 3386972b6..c013c471d 100644
--- a/gcc/testsuite/go.test/test/rune.go
+++ b/gcc/testsuite/go.test/test/rune.go
@@ -1,10 +1,13 @@
-// $G $D/$F.go
+// compile
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-package main
+// Test rune constants, expressions and types.
+// Compiles but does not run.
+
+package rune
var (
r0 = 'a'
diff --git a/gcc/testsuite/go.test/test/runtime.go b/gcc/testsuite/go.test/test/runtime.go
index 4be1d055b..89f59e3ed 100644
--- a/gcc/testsuite/go.test/test/runtime.go
+++ b/gcc/testsuite/go.test/test/runtime.go
@@ -1,15 +1,16 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// make sure that even if a file imports runtime,
+// Test that even if a file imports runtime,
// it cannot get at the low-level runtime definitions
-// known to the compiler. for normal packages
+// known to the compiler. For normal packages
// the compiler doesn't even record the lower case
// functions in its symbol table, but some functions
// in runtime are hard-coded into the compiler.
+// Does not compile.
package main
diff --git a/gcc/testsuite/go.test/test/safe/main.go b/gcc/testsuite/go.test/test/safe/main.go
new file mode 100644
index 000000000..d173ed926
--- /dev/null
+++ b/gcc/testsuite/go.test/test/safe/main.go
@@ -0,0 +1,14 @@
+// true
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package main
+
+// can't use local path with -u, use -I. instead
+import "pkg" // ERROR "import unsafe package"
+
+func main() {
+ print(pkg.Float32bits(1.0))
+}
diff --git a/gcc/testsuite/go.test/test/safe/nousesafe.go b/gcc/testsuite/go.test/test/safe/nousesafe.go
new file mode 100644
index 000000000..f61e7fe4f
--- /dev/null
+++ b/gcc/testsuite/go.test/test/safe/nousesafe.go
@@ -0,0 +1,8 @@
+// $G $D/pkg.go && pack grc pkg.a pkg.$A 2> /dev/null && rm pkg.$A && errchk $G -I. -u $D/main.go
+// rm -f pkg.a
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package ignored
diff --git a/gcc/testsuite/go.test/test/safe/pkg.go b/gcc/testsuite/go.test/test/safe/pkg.go
new file mode 100644
index 000000000..bebc43a21
--- /dev/null
+++ b/gcc/testsuite/go.test/test/safe/pkg.go
@@ -0,0 +1,16 @@
+// true
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// a package that uses unsafe on the inside but not in it's api
+
+package pkg
+
+import "unsafe"
+
+// this should be inlinable
+func Float32bits(f float32) uint32 {
+ return *(*uint32)(unsafe.Pointer(&f))
+} \ No newline at end of file
diff --git a/gcc/testsuite/go.test/test/safe/usesafe.go b/gcc/testsuite/go.test/test/safe/usesafe.go
new file mode 100644
index 000000000..07c13c1c3
--- /dev/null
+++ b/gcc/testsuite/go.test/test/safe/usesafe.go
@@ -0,0 +1,8 @@
+// $G $D/pkg.go && pack grcS pkg.a pkg.$A 2> /dev/null && rm pkg.$A && $G -I. -u $D/main.go
+// rm -f pkg.a
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package ignored
diff --git a/gcc/testsuite/go.test/test/shift1.go b/gcc/testsuite/go.test/test/shift1.go
index c197eef66..b33d22ff8 100644
--- a/gcc/testsuite/go.test/test/shift1.go
+++ b/gcc/testsuite/go.test/test/shift1.go
@@ -1,10 +1,12 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test illegal shifts.
// Issue 1708, illegal cases.
+// Does not compile.
package p
diff --git a/gcc/testsuite/go.test/test/shift2.go b/gcc/testsuite/go.test/test/shift2.go
index ec4c7addc..88ef3c40f 100644
--- a/gcc/testsuite/go.test/test/shift2.go
+++ b/gcc/testsuite/go.test/test/shift2.go
@@ -1,10 +1,12 @@
-// $G $D/$F.go || echo BUG: shift2
+// compile
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test legal shifts.
// Issue 1708, legal cases.
+// Compiles but does not run.
package p
diff --git a/gcc/testsuite/go.test/test/sieve.go b/gcc/testsuite/go.test/test/sieve.go
index 4fa111582..0cd120c54 100644
--- a/gcc/testsuite/go.test/test/sieve.go
+++ b/gcc/testsuite/go.test/test/sieve.go
@@ -1,9 +1,12 @@
-// $G $F.go && $L $F.$A # don't run it - goes forever
+// build
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test basic concurrency: the classic prime sieve.
+// Do not run - loops forever.
+
package main
// Send the sequence 2, 3, 4, ... to channel 'ch'.
diff --git a/gcc/testsuite/go.test/test/sigchld.go b/gcc/testsuite/go.test/test/sigchld.go
index e7c3d5abb..c1cfc2a8d 100644
--- a/gcc/testsuite/go.test/test/sigchld.go
+++ b/gcc/testsuite/go.test/test/sigchld.go
@@ -1,10 +1,15 @@
// [ "$GOOS" == windows ] ||
// ($G $D/$F.go && $L $F.$A && ./$A.out 2>&1 | cmp - $D/$F.out)
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test that a program can survive SIGCHLD.
+
package main
import "syscall"
diff --git a/gcc/testsuite/go.test/test/simassign.go b/gcc/testsuite/go.test/test/simassign.go
index 28408abc2..6ba5c783e 100644
--- a/gcc/testsuite/go.test/test/simassign.go
+++ b/gcc/testsuite/go.test/test/simassign.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test simultaneous assignment.
+
package main
var a, b, c, d, e, f, g, h, i int
diff --git a/gcc/testsuite/go.test/test/sinit.go b/gcc/testsuite/go.test/test/sinit.go
index 5cd3a4567..ffb8ef751 100644
--- a/gcc/testsuite/go.test/test/sinit.go
+++ b/gcc/testsuite/go.test/test/sinit.go
@@ -1,9 +1,15 @@
// $G -S $D/$F.go | egrep initdone >/dev/null && echo BUG sinit || true
+// NOTE: This test is not run by 'run.go' and so not run by all.bash.
+// To run this test you must use the ./run shell script.
+
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test that many initializations can be done at link time and
+// generate no executable init functions.
+
package p
// Should be no init func in the assembly.
diff --git a/gcc/testsuite/go.test/test/sizeof.go b/gcc/testsuite/go.test/test/sizeof.go
index 544e4c52c..a6abdd5c6 100644
--- a/gcc/testsuite/go.test/test/sizeof.go
+++ b/gcc/testsuite/go.test/test/sizeof.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go
+// compile
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test unsafe.Sizeof, unsafe.Alignof, and unsafe.Offsetof all return uintptr.
+
package main
import "unsafe"
diff --git a/gcc/testsuite/go.test/test/solitaire.go b/gcc/testsuite/go.test/test/solitaire.go
index 473a1d12d..ac54cec0a 100644
--- a/gcc/testsuite/go.test/test/solitaire.go
+++ b/gcc/testsuite/go.test/test/solitaire.go
@@ -1,9 +1,13 @@
-// $G $F.go && $L $F.$A # don't run it - produces too much output
+// build
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test general operation by solving a peg solitaire game.
+// A version of this is in the Go playground.
+// Don't run it - produces too much output.
+
// This program solves the (English) peg solitaire board game.
// See also: http://en.wikipedia.org/wiki/Peg_solitaire
diff --git a/gcc/testsuite/go.test/test/stack.go b/gcc/testsuite/go.test/test/stack.go
index 1fd57161f..b62febd48 100644
--- a/gcc/testsuite/go.test/test/stack.go
+++ b/gcc/testsuite/go.test/test/stack.go
@@ -1,9 +1,10 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test stack splitting code.
// Try to tickle stack splitting bugs by doing
// go, defer, and closure calls at different stack depths.
diff --git a/gcc/testsuite/go.test/test/string_lit.go b/gcc/testsuite/go.test/test/string_lit.go
index c702a05e9..457faaa88 100644
--- a/gcc/testsuite/go.test/test/string_lit.go
+++ b/gcc/testsuite/go.test/test/string_lit.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test string literal syntax.
+
package main
import "os"
@@ -91,7 +93,7 @@ func main() {
"backslashes 2 (backquote)")
assert("\\x\\u\\U\\", `\x\u\U\`, "backslash 3 (backquote)")
- // test large runes. perhaps not the most logical place for this test.
+ // test large and surrogate-half runes. perhaps not the most logical place for these tests.
var r int32
r = 0x10ffff // largest rune value
s = string(r)
@@ -99,6 +101,28 @@ func main() {
r = 0x10ffff + 1
s = string(r)
assert(s, "\xef\xbf\xbd", "too-large rune")
+ r = 0xD800
+ s = string(r)
+ assert(s, "\xef\xbf\xbd", "surrogate rune min")
+ r = 0xDFFF
+ s = string(r)
+ assert(s, "\xef\xbf\xbd", "surrogate rune max")
+ r = -1
+ s = string(r)
+ assert(s, "\xef\xbf\xbd", "negative rune")
+
+ // the large rune tests again, this time using constants instead of a variable.
+ // these conversions will be done at compile time.
+ s = string(0x10ffff) // largest rune value
+ assert(s, "\xf4\x8f\xbf\xbf", "largest rune constant")
+ s = string(0x10ffff + 1)
+ assert(s, "\xef\xbf\xbd", "too-large rune constant")
+ s = string(0xD800)
+ assert(s, "\xef\xbf\xbd", "surrogate rune min constant")
+ s = string(0xDFFF)
+ assert(s, "\xef\xbf\xbd", "surrogate rune max constant")
+ s = string(-1)
+ assert(s, "\xef\xbf\xbd", "negative rune")
assert(string(gr1), gx1, "global ->[]rune")
assert(string(gr2), gx2fix, "global invalid ->[]rune")
diff --git a/gcc/testsuite/go.test/test/stringrange.go b/gcc/testsuite/go.test/test/stringrange.go
index 6a7063e23..99e5edb5a 100644
--- a/gcc/testsuite/go.test/test/stringrange.go
+++ b/gcc/testsuite/go.test/test/stringrange.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test range over strings.
+
package main
import (
@@ -55,6 +57,13 @@ func main() {
ok = false
}
+ for _, c := range "a\xed\xa0\x80a" {
+ if c != 'a' && c != utf8.RuneError {
+ fmt.Printf("surrogate UTF-8 does not error: %U\n", c)
+ ok = false
+ }
+ }
+
if !ok {
fmt.Println("BUG: stringrange")
os.Exit(1)
diff --git a/gcc/testsuite/go.test/test/struct0.go b/gcc/testsuite/go.test/test/struct0.go
index 2398c4117..e29eb30f5 100644
--- a/gcc/testsuite/go.test/test/struct0.go
+++ b/gcc/testsuite/go.test/test/struct0.go
@@ -1,12 +1,12 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// zero length structs.
-// used to not be evaluated.
-// issue 2232.
+// Test zero length structs.
+// Used to not be evaluated.
+// Issue 2232.
package main
diff --git a/gcc/testsuite/go.test/test/switch.go b/gcc/testsuite/go.test/test/switch.go
index bed027ce8..fd8748b9b 100644
--- a/gcc/testsuite/go.test/test/switch.go
+++ b/gcc/testsuite/go.test/test/switch.go
@@ -1,11 +1,15 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test switch statements.
+
package main
+import "os"
+
func assert(cond bool, msg string) {
if !cond {
print("assertion fail: ", msg, "\n")
@@ -279,4 +283,56 @@ func main() {
assert(false, "m should not be nil")
default:
}
+
+ // switch on interface.
+ switch i := interface{}("hello"); i {
+ case 42:
+ assert(false, `i should be "hello"`)
+ case "hello":
+ assert(true, "hello")
+ default:
+ assert(false, `i should be "hello"`)
+ }
+
+ // switch on implicit bool converted to interface
+ // was broken: see issue 3980
+ switch i := interface{}(true); {
+ case i:
+ assert(true, "true")
+ case false:
+ assert(false, "i should be true")
+ default:
+ assert(false, "i should be true")
+ }
+
+ // switch on array.
+ switch ar := [3]int{1, 2, 3}; ar {
+ case [3]int{1,2,3}:
+ assert(true, "[1 2 3]")
+ case [3]int{4,5,6}:
+ assert(false, "ar should be [1 2 3]")
+ default:
+ assert(false, "ar should be [1 2 3]")
+ }
+
+ // switch on channel
+ switch c1, c2 := make(chan int), make(chan int); c1 {
+ case nil:
+ assert(false, "c1 did not match itself")
+ case c2:
+ assert(false, "c1 did not match itself")
+ case c1:
+ assert(true, "chan")
+ default:
+ assert(false, "c1 did not match itself")
+ }
+
+ i := 0
+ switch x := 5; {
+ case i < x:
+ os.Exit(0)
+ case i == x:
+ case i > x:
+ os.Exit(1)
+ }
}
diff --git a/gcc/testsuite/go.test/test/switch1.go b/gcc/testsuite/go.test/test/switch1.go
deleted file mode 100644
index 5bd9d7c5d..000000000
--- a/gcc/testsuite/go.test/test/switch1.go
+++ /dev/null
@@ -1,20 +0,0 @@
-// $G $F.go && $L $F.$A && ./$A.out
-
-// Copyright 2009 The Go Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style
-// license that can be found in the LICENSE file.
-
-package main
-
-import "os"
-
-func main() {
- i := 0
- switch x := 5; {
- case i < x:
- os.Exit(0)
- case i == x:
- case i > x:
- os.Exit(1)
- }
-}
diff --git a/gcc/testsuite/go.test/test/switch3.go b/gcc/testsuite/go.test/test/switch3.go
index 6c9ebfe6d..28705e464 100644
--- a/gcc/testsuite/go.test/test/switch3.go
+++ b/gcc/testsuite/go.test/test/switch3.go
@@ -1,9 +1,12 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that erroneous switch statements are detected by the compiler.
+// Does not compile.
+
package main
type I interface {
@@ -42,6 +45,17 @@ func bad() {
case f1: // ERROR "can only compare func f to nil|func can only be compared to nil"
default:
}
+
+ var ar, ar1 [4]func()
+ switch ar { // ERROR "cannot switch on"
+ case ar1:
+ default:
+ }
+
+ var st, st1 struct{ f func() }
+ switch st { // ERROR "cannot switch on"
+ case st1:
+ }
}
func good() {
diff --git a/gcc/testsuite/go.test/test/syntax/chan.go b/gcc/testsuite/go.test/test/syntax/chan.go
index ff3577502..3b68bda35 100644
--- a/gcc/testsuite/go.test/test/syntax/chan.go
+++ b/gcc/testsuite/go.test/test/syntax/chan.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/syntax/chan1.go b/gcc/testsuite/go.test/test/syntax/chan1.go
index 9c12e5e6f..868a1226d 100644
--- a/gcc/testsuite/go.test/test/syntax/chan1.go
+++ b/gcc/testsuite/go.test/test/syntax/chan1.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/syntax/composite.go b/gcc/testsuite/go.test/test/syntax/composite.go
new file mode 100644
index 000000000..656533493
--- /dev/null
+++ b/gcc/testsuite/go.test/test/syntax/composite.go
@@ -0,0 +1,11 @@
+// errorcheck
+
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package main
+
+var a = []int{
+ 3 // ERROR "need trailing comma before newline in composite literal"
+}
diff --git a/gcc/testsuite/go.test/test/syntax/else.go b/gcc/testsuite/go.test/test/syntax/else.go
index 99595254f..e985a9c09 100644
--- a/gcc/testsuite/go.test/test/syntax/else.go
+++ b/gcc/testsuite/go.test/test/syntax/else.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/syntax/forvar.go b/gcc/testsuite/go.test/test/syntax/forvar.go
index f12ce55ca..dc592d2b6 100644
--- a/gcc/testsuite/go.test/test/syntax/forvar.go
+++ b/gcc/testsuite/go.test/test/syntax/forvar.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/syntax/if.go b/gcc/testsuite/go.test/test/syntax/if.go
index a3b51f0c0..b2a65f9a5 100644
--- a/gcc/testsuite/go.test/test/syntax/if.go
+++ b/gcc/testsuite/go.test/test/syntax/if.go
@@ -1,4 +1,4 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/syntax/import.go b/gcc/testsuite/go.test/test/syntax/import.go
index dd1f26134..f0a792126 100644
--- a/gcc/testsuite/go.test/test/syntax/import.go
+++ b/gcc/testsuite/go.test/test/syntax/import.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/syntax/interface.go b/gcc/testsuite/go.test/test/syntax/interface.go
index a7f43533a..0b76b5416 100644
--- a/gcc/testsuite/go.test/test/syntax/interface.go
+++ b/gcc/testsuite/go.test/test/syntax/interface.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/syntax/semi1.go b/gcc/testsuite/go.test/test/syntax/semi1.go
index 547d9bf79..8fbfb206a 100644
--- a/gcc/testsuite/go.test/test/syntax/semi1.go
+++ b/gcc/testsuite/go.test/test/syntax/semi1.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/syntax/semi2.go b/gcc/testsuite/go.test/test/syntax/semi2.go
index 28d1d3906..cfb0ed17b 100644
--- a/gcc/testsuite/go.test/test/syntax/semi2.go
+++ b/gcc/testsuite/go.test/test/syntax/semi2.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/syntax/semi3.go b/gcc/testsuite/go.test/test/syntax/semi3.go
index ab5941bda..645af7354 100644
--- a/gcc/testsuite/go.test/test/syntax/semi3.go
+++ b/gcc/testsuite/go.test/test/syntax/semi3.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/syntax/semi4.go b/gcc/testsuite/go.test/test/syntax/semi4.go
index 7a9c2956e..e192348aa 100644
--- a/gcc/testsuite/go.test/test/syntax/semi4.go
+++ b/gcc/testsuite/go.test/test/syntax/semi4.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/syntax/semi5.go b/gcc/testsuite/go.test/test/syntax/semi5.go
index 5f8ccc688..cf690f084 100644
--- a/gcc/testsuite/go.test/test/syntax/semi5.go
+++ b/gcc/testsuite/go.test/test/syntax/semi5.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/syntax/semi6.go b/gcc/testsuite/go.test/test/syntax/semi6.go
index b6279ed30..c1e1cc363 100644
--- a/gcc/testsuite/go.test/test/syntax/semi6.go
+++ b/gcc/testsuite/go.test/test/syntax/semi6.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/syntax/semi7.go b/gcc/testsuite/go.test/test/syntax/semi7.go
index 5a7b3ff4c..6c9ade8bc 100644
--- a/gcc/testsuite/go.test/test/syntax/semi7.go
+++ b/gcc/testsuite/go.test/test/syntax/semi7.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/syntax/topexpr.go b/gcc/testsuite/go.test/test/syntax/topexpr.go
index 93d86fbe9..c5958f5dd 100644
--- a/gcc/testsuite/go.test/test/syntax/topexpr.go
+++ b/gcc/testsuite/go.test/test/syntax/topexpr.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/syntax/typesw.go b/gcc/testsuite/go.test/test/syntax/typesw.go
index 47f683cdf..cd8cf3523 100644
--- a/gcc/testsuite/go.test/test/syntax/typesw.go
+++ b/gcc/testsuite/go.test/test/syntax/typesw.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/syntax/vareq.go b/gcc/testsuite/go.test/test/syntax/vareq.go
index 8525be8cf..f08955e91 100644
--- a/gcc/testsuite/go.test/test/syntax/vareq.go
+++ b/gcc/testsuite/go.test/test/syntax/vareq.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/syntax/vareq1.go b/gcc/testsuite/go.test/test/syntax/vareq1.go
index 9d70bea39..e900eabeb 100644
--- a/gcc/testsuite/go.test/test/syntax/vareq1.go
+++ b/gcc/testsuite/go.test/test/syntax/vareq1.go
@@ -1,4 +1,4 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
diff --git a/gcc/testsuite/go.test/test/test0.go b/gcc/testsuite/go.test/test/test0.go
deleted file mode 100644
index d8d86c427..000000000
--- a/gcc/testsuite/go.test/test/test0.go
+++ /dev/null
@@ -1,92 +0,0 @@
-// $G $F.go && $L $F.$A && ./$A.out
-
-// Copyright 2009 The Go Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style
-// license that can be found in the LICENSE file.
-
-package main
-
-const a_const = 0
-
-const (
- pi = /* the usual */ 3.14159265358979323
- e = 2.718281828
- mask1 int = 1 << iota
- mask2 = 1 << iota
- mask3 = 1 << iota
- mask4 = 1 << iota
-)
-
-type (
- Empty interface{}
- Point struct {
- x, y int
- }
- Point2 Point
-)
-
-func (p *Point) Initialize(x, y int) *Point {
- p.x, p.y = x, y
- return p
-}
-
-func (p *Point) Distance() int {
- return p.x*p.x + p.y*p.y
-}
-
-var (
- x1 int
- x2 int
- u, v, w float32
-)
-
-func foo() {}
-
-func min(x, y int) int {
- if x < y {
- return x
- }
- return y
-}
-
-func swap(x, y int) (u, v int) {
- u = y
- v = x
- return
-}
-
-func control_structs() {
- var p *Point = new(Point).Initialize(2, 3)
- i := p.Distance()
- var f float32 = 0.3
- _ = f
- for {
- }
- for {
- }
- for j := 0; j < i; j++ {
- if i == 0 {
- } else {
- i = 0
- }
- var x float32
- _ = x
- }
-foo: // a label
- var j int
- switch y := 0; true {
- case i < y:
- fallthrough
- case i < j:
- case i == 0, i == 1, i == j:
- i++
- i++
- goto foo
- default:
- i = -+-+i
- break
- }
-}
-
-func main() {
-}
diff --git a/gcc/testsuite/go.test/test/testlib b/gcc/testsuite/go.test/test/testlib
new file mode 100644
index 000000000..29de7672c
--- /dev/null
+++ b/gcc/testsuite/go.test/test/testlib
@@ -0,0 +1,61 @@
+# Copyright 2012 The Go Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style
+# license that can be found in the LICENSE file.
+
+# These function names are also known to
+# (and are the plan for transitioning to) run.go.
+
+compile() {
+ $G $D/$F.go
+}
+
+compiledir() {
+ for gofile in $D/$F.dir/*.go
+ do
+ $G -I. "$gofile" || return 1
+ done
+}
+
+build() {
+ $G $D/$F.go && $L $F.$A
+}
+
+runoutput() {
+ go run "$D/$F.go" > tmp.go
+ go run tmp.go
+}
+
+run() {
+ gofiles=""
+ ingo=true
+ while $ingo; do
+ case "$1" in
+ *.go)
+ gofiles="$gofiles $1"
+ shift
+ ;;
+ *)
+ ingo=false
+ ;;
+ esac
+ done
+
+ $G $D/$F.go $gofiles && $L $F.$A && ./$A.out "$@"
+}
+
+cmpout() {
+ $G $D/$F.go && $L $F.$A && ./$A.out 2>&1 | cmp - $D/$F.out
+}
+
+errorcheck() {
+ zero=""
+ if [ "$1" = "-0" ]; then
+ zero="-0"
+ shift
+ fi
+ errchk $zero $G -e $* $D/$F.go
+}
+
+skip() {
+ true
+}
diff --git a/gcc/testsuite/go.test/test/times.out b/gcc/testsuite/go.test/test/times.out
deleted file mode 100644
index 841fab9ef..000000000
--- a/gcc/testsuite/go.test/test/times.out
+++ /dev/null
@@ -1,632 +0,0 @@
-0.04 ./235
-1.72 ./64bit
-0.03 ./alias
-0.03 ./alias1
-0.30 ./append
-0.07 ./args
-0.02 ./assign
-0.04 ./assign1
-0.04 ./bigalg
-0.03 ./bigmap
-0.14 ./blank
-0.03 ./blank1
-0.03 ./chancap
-0.07 ./char_lit
-0.03 ./char_lit1
-0.09 ./closedchan
-0.05 ./closure
-0.06 ./cmp
-0.02 ./cmp6
-0.03 ./cmplx
-0.60 ./cmplxdivide
-0.00 ./cmplxdivide1
-0.04 ./complit
-0.02 ./complit1
-0.03 ./compos
-0.04 ./const
-0.03 ./const1
-0.03 ./const2
-0.13 ./const3
-0.08 ./convert
-0.03 ./convert1
-0.02 ./convert3
-0.04 ./convlit
-0.02 ./convlit1
-0.34 ./copy
-0.27 ./crlf
-0.05 ./ddd
-0.02 ./ddd1
-0.00 ./ddd2
-0.04 ./ddd3
-0.03 ./decl
-0.03 ./declbad
-0.14 ./defer
-0.03 ./deferprint
-0.14 ./divide
-0.00 ./empty
-0.08 ./env
-0.00 ./eof
-0.00 ./eof1
-0.04 ./escape
-0.12 ./escape2
-0.03 ./escape3
-0.05 ./float_lit
-0.14 ./floatcmp
-0.03 ./for
-0.04 ./func
-0.03 ./func1
-0.00 ./func2
-0.03 ./func3
-0.03 ./func4
-0.03 ./func5
-0.00 ./func6
-0.04 ./func7
-0.03 ./gc
-0.04 ./gc1
-0.26 ./gc2
-0.06 ./goprint
-0.04 ./goto
-0.04 ./hashmap
-0.03 ./helloworld
-0.03 ./if
-0.02 ./import
-0.15 ./import1
-0.00 ./import2
-0.01 ./import3
-0.14 ./import4
-1.70 ./index
-0.03 ./indirect
-0.02 ./indirect1
-0.02 ./init
-0.25 ./init1
-0.03 ./initcomma
-0.15 ./initialize
-0.02 ./initializerr
-0.06 ./initsyscall
-0.07 ./int_lit
-0.03 ./intcvt
-0.03 ./iota
-0.03 ./label
-0.03 ./label1
-0.04 ./literal
-0.15 ./malloc1
-0.06 ./mallocfin
-0.19 ./mallocrand
-0.21 ./mallocrep
-0.52 ./mallocrep1
-0.17 ./map
-0.02 ./map1
-0.05 ./method
-0.02 ./method1
-0.03 ./method2
-0.04 ./method3
-0.06 ./named
-0.03 ./named1
-0.18 ./nil
-0.15 ./nilptr
-0.16 ./nul1
-0.00 ./parentype
-0.11 ./peano
-0.02 ./printbig
-0.05 ./range
-0.04 ./recover
-0.04 ./recover1
-0.08 ./recover2
-0.06 ./recover3
-0.14 ./rename
-0.02 ./rename1
-0.16 ./reorder
-0.00 ./rune
-0.03 ./runtime
-0.03 ./shift1
-0.01 ./shift2
-0.03 ./sieve
-0.06 ./sigchld
-0.03 ./simassign
-0.02 ./sinit
-0.00 ./sizeof
-0.03 ./solitaire
-0.06 ./stack
-0.08 ./string_lit
-0.14 ./stringrange
-0.04 ./struct0
-0.04 ./switch
-0.08 ./switch1
-0.02 ./switch3
-0.04 ./test0
-0.03 ./turing
-0.07 ./typeswitch
-0.15 ./typeswitch1
-0.02 ./typeswitch2
-0.03 ./typeswitch3
-0.02 ./undef
-0.04 ./utf
-0.03 ./varerr
-0.03 ./varinit
-0.26 ./zerodivide
-0.04 ken/array
-0.11 ken/chan
-0.04 ken/chan1
-0.04 ken/complit
-0.07 ken/convert
-0.03 ken/cplx0
-0.02 ken/cplx1
-0.06 ken/cplx2
-0.09 ken/cplx3
-0.14 ken/cplx4
-0.03 ken/cplx5
-0.31 ken/divconst
-0.05 ken/divmod
-0.04 ken/embed
-0.03 ken/for
-0.04 ken/interbasic
-0.03 ken/interfun
-0.04 ken/intervar
-0.03 ken/label
-0.03 ken/litfun
-0.03 ken/mfunc
-0.34 ken/modconst
-0.03 ken/ptrfun
-0.03 ken/ptrvar
-0.04 ken/range
-0.03 ken/rob1
-0.18 ken/rob2
-0.04 ken/robfor
-0.04 ken/robfunc
-0.03 ken/shift
-0.03 ken/simparray
-0.04 ken/simpbool
-0.03 ken/simpconv
-0.03 ken/simpfun
-0.03 ken/simpswitch
-0.03 ken/simpvar
-0.02 ken/slicearray
-0.03 ken/sliceslice
-0.03 ken/string
-0.03 ken/strvar
-0.32 chan/doubleselect
-0.06 chan/fifo
-0.12 chan/goroutines
-0.07 chan/nonblock
-0.02 chan/perm
-0.10 chan/powser1
-0.09 chan/powser2
-0.03 chan/select
-0.15 chan/select2
-0.97 chan/select3
-0.03 chan/select4
-0.72 chan/select5
-0.03 chan/select6
-0.04 chan/select7
-0.03 chan/sendstmt
-0.03 chan/sieve1
-0.04 chan/sieve2
-0.02 chan/zerosize
-0.04 interface/bigdata
-0.04 interface/convert
-0.03 interface/convert1
-0.03 interface/convert2
-0.09 interface/embed
-0.00 interface/embed0
-0.03 interface/embed1
-0.02 interface/embed2
-0.02 interface/explicit
-0.03 interface/fail
-0.09 interface/fake
-0.03 interface/noeq
-0.03 interface/pointer
-0.03 interface/private
-0.00 interface/private1
-0.04 interface/receiver
-0.03 interface/receiver1
-0.00 interface/recursive
-0.03 interface/returntype
-0.09 interface/struct
-0.02 syntax/chan
-0.03 syntax/chan1
-0.02 syntax/else
-0.02 syntax/forvar
-0.03 syntax/if
-0.03 syntax/import
-0.03 syntax/interface
-0.03 syntax/semi1
-0.02 syntax/semi2
-0.03 syntax/semi3
-0.03 syntax/semi4
-0.02 syntax/semi5
-0.03 syntax/semi6
-0.02 syntax/semi7
-0.02 syntax/topexpr
-0.03 syntax/typesw
-0.02 syntax/vareq
-0.03 syntax/vareq1
-0.04 dwarf/linedirectives
-0.05 dwarf/main
-0.00 dwarf/z1
-0.00 dwarf/z10
-0.00 dwarf/z11
-0.00 dwarf/z12
-0.00 dwarf/z13
-0.00 dwarf/z14
-0.00 dwarf/z15
-0.00 dwarf/z16
-0.00 dwarf/z17
-0.00 dwarf/z18
-0.00 dwarf/z19
-0.00 dwarf/z2
-0.00 dwarf/z20
-0.00 dwarf/z3
-0.00 dwarf/z4
-0.00 dwarf/z5
-0.00 dwarf/z6
-0.00 dwarf/z7
-0.00 dwarf/z8
-0.00 dwarf/z9
-0.03 fixedbugs/bug000
-0.03 fixedbugs/bug002
-0.03 fixedbugs/bug003
-0.03 fixedbugs/bug004
-0.04 fixedbugs/bug005
-0.08 fixedbugs/bug006
-0.03 fixedbugs/bug007
-0.03 fixedbugs/bug008
-0.02 fixedbugs/bug009
-0.03 fixedbugs/bug010
-0.03 fixedbugs/bug011
-0.03 fixedbugs/bug012
-0.03 fixedbugs/bug013
-0.03 fixedbugs/bug014
-0.02 fixedbugs/bug015
-0.02 fixedbugs/bug016
-0.03 fixedbugs/bug017
-0.00 fixedbugs/bug020
-0.03 fixedbugs/bug021
-0.02 fixedbugs/bug022
-0.03 fixedbugs/bug023
-0.03 fixedbugs/bug024
-0.03 fixedbugs/bug026
-0.14 fixedbugs/bug027
-0.03 fixedbugs/bug028
-0.02 fixedbugs/bug030
-0.03 fixedbugs/bug031
-0.02 fixedbugs/bug035
-0.00 fixedbugs/bug036
-0.02 fixedbugs/bug037
-0.00 fixedbugs/bug038
-0.03 fixedbugs/bug039
-0.00 fixedbugs/bug040
-0.03 fixedbugs/bug045
-0.03 fixedbugs/bug046
-0.03 fixedbugs/bug047
-0.02 fixedbugs/bug048
-0.03 fixedbugs/bug049
-0.03 fixedbugs/bug050
-0.02 fixedbugs/bug051
-0.03 fixedbugs/bug052
-0.03 fixedbugs/bug053
-0.03 fixedbugs/bug054
-0.03 fixedbugs/bug055
-0.03 fixedbugs/bug056
-0.00 fixedbugs/bug057
-0.04 fixedbugs/bug058
-0.08 fixedbugs/bug059
-0.08 fixedbugs/bug060
-0.03 fixedbugs/bug061
-0.03 fixedbugs/bug062
-0.00 fixedbugs/bug063
-0.00 fixedbugs/bug064
-0.03 fixedbugs/bug065
-0.00 fixedbugs/bug066
-0.03 fixedbugs/bug067
-0.03 fixedbugs/bug068
-0.00 fixedbugs/bug069
-0.15 fixedbugs/bug070
-0.00 fixedbugs/bug071
-0.03 fixedbugs/bug072
-0.03 fixedbugs/bug073
-0.03 fixedbugs/bug074
-0.03 fixedbugs/bug075
-0.03 fixedbugs/bug076
-0.00 fixedbugs/bug077
-0.03 fixedbugs/bug078
-0.00 fixedbugs/bug080
-0.02 fixedbugs/bug081
-0.03 fixedbugs/bug082
-0.03 fixedbugs/bug083
-0.04 fixedbugs/bug084
-0.02 fixedbugs/bug085
-0.03 fixedbugs/bug086
-0.00 fixedbugs/bug087
-0.01 fixedbugs/bug088
-0.00 fixedbugs/bug089
-0.03 fixedbugs/bug090
-0.02 fixedbugs/bug091
-0.03 fixedbugs/bug092
-0.03 fixedbugs/bug093
-0.00 fixedbugs/bug094
-0.00 fixedbugs/bug096
-0.03 fixedbugs/bug097
-0.00 fixedbugs/bug098
-0.03 fixedbugs/bug099
-0.03 fixedbugs/bug101
-0.03 fixedbugs/bug102
-0.02 fixedbugs/bug103
-0.03 fixedbugs/bug104
-0.01 fixedbugs/bug106
-0.03 fixedbugs/bug107
-0.03 fixedbugs/bug108
-0.00 fixedbugs/bug109
-0.03 fixedbugs/bug110
-0.03 fixedbugs/bug111
-0.00 fixedbugs/bug112
-0.03 fixedbugs/bug113
-0.03 fixedbugs/bug114
-0.00 fixedbugs/bug115
-0.03 fixedbugs/bug116
-0.02 fixedbugs/bug117
-0.00 fixedbugs/bug118
-0.03 fixedbugs/bug119
-0.11 fixedbugs/bug120
-0.02 fixedbugs/bug121
-0.03 fixedbugs/bug122
-0.03 fixedbugs/bug123
-0.02 fixedbugs/bug126
-0.02 fixedbugs/bug127
-0.03 fixedbugs/bug128
-0.01 fixedbugs/bug129
-0.08 fixedbugs/bug130
-0.02 fixedbugs/bug131
-0.02 fixedbugs/bug132
-0.03 fixedbugs/bug133
-0.00 fixedbugs/bug135
-0.02 fixedbugs/bug136
-0.00 fixedbugs/bug137
-0.00 fixedbugs/bug139
-0.00 fixedbugs/bug140
-0.07 fixedbugs/bug141
-0.03 fixedbugs/bug142
-0.00 fixedbugs/bug143
-0.00 fixedbugs/bug144
-0.00 fixedbugs/bug145
-0.03 fixedbugs/bug146
-0.06 fixedbugs/bug147
-0.03 fixedbugs/bug148
-0.00 fixedbugs/bug149
-0.00 fixedbugs/bug150
-0.00 fixedbugs/bug151
-0.03 fixedbugs/bug1515
-0.03 fixedbugs/bug152
-0.14 fixedbugs/bug154
-0.03 fixedbugs/bug155
-0.00 fixedbugs/bug156
-0.00 fixedbugs/bug157
-0.00 fixedbugs/bug158
-0.07 fixedbugs/bug159
-0.09 fixedbugs/bug160
-0.00 fixedbugs/bug161
-0.02 fixedbugs/bug163
-0.00 fixedbugs/bug164
-0.03 fixedbugs/bug165
-0.03 fixedbugs/bug167
-0.03 fixedbugs/bug168
-0.02 fixedbugs/bug169
-0.03 fixedbugs/bug170
-0.03 fixedbugs/bug171
-0.02 fixedbugs/bug172
-0.00 fixedbugs/bug173
-0.00 fixedbugs/bug174
-0.03 fixedbugs/bug175
-0.03 fixedbugs/bug176
-0.09 fixedbugs/bug177
-0.03 fixedbugs/bug178
-0.03 fixedbugs/bug179
-0.03 fixedbugs/bug180
-0.03 fixedbugs/bug181
-0.02 fixedbugs/bug182
-0.03 fixedbugs/bug183
-0.15 fixedbugs/bug184
-0.04 fixedbugs/bug185
-0.02 fixedbugs/bug186
-0.08 fixedbugs/bug187
-0.03 fixedbugs/bug188
-0.03 fixedbugs/bug189
-0.00 fixedbugs/bug190
-0.04 fixedbugs/bug191
-0.03 fixedbugs/bug192
-0.03 fixedbugs/bug193
-0.03 fixedbugs/bug194
-0.02 fixedbugs/bug195
-0.04 fixedbugs/bug196
-0.02 fixedbugs/bug197
-0.03 fixedbugs/bug198
-0.03 fixedbugs/bug199
-0.03 fixedbugs/bug200
-0.03 fixedbugs/bug201
-0.03 fixedbugs/bug202
-0.03 fixedbugs/bug203
-0.03 fixedbugs/bug204
-0.02 fixedbugs/bug205
-0.21 fixedbugs/bug206
-0.14 fixedbugs/bug207
-0.02 fixedbugs/bug208
-0.02 fixedbugs/bug209
-0.03 fixedbugs/bug211
-0.03 fixedbugs/bug212
-0.03 fixedbugs/bug213
-0.00 fixedbugs/bug214
-0.02 fixedbugs/bug215
-0.00 fixedbugs/bug216
-0.03 fixedbugs/bug217
-0.00 fixedbugs/bug218
-0.00 fixedbugs/bug219
-0.04 fixedbugs/bug221
-0.01 fixedbugs/bug222
-0.00 fixedbugs/bug223
-0.03 fixedbugs/bug224
-0.03 fixedbugs/bug225
-0.03 fixedbugs/bug227
-0.03 fixedbugs/bug228
-0.03 fixedbugs/bug229
-0.03 fixedbugs/bug230
-0.02 fixedbugs/bug231
-0.00 fixedbugs/bug232
-0.01 fixedbugs/bug233
-0.04 fixedbugs/bug234
-0.00 fixedbugs/bug235
-0.04 fixedbugs/bug236
-0.15 fixedbugs/bug237
-0.03 fixedbugs/bug238
-0.00 fixedbugs/bug239
-0.03 fixedbugs/bug240
-0.03 fixedbugs/bug241
-0.04 fixedbugs/bug242
-0.04 fixedbugs/bug243
-0.03 fixedbugs/bug244
-0.00 fixedbugs/bug245
-0.03 fixedbugs/bug246
-0.03 fixedbugs/bug247
-0.11 fixedbugs/bug248
-0.03 fixedbugs/bug249
-0.00 fixedbugs/bug250
-0.03 fixedbugs/bug251
-0.03 fixedbugs/bug252
-0.03 fixedbugs/bug253
-0.03 fixedbugs/bug254
-0.03 fixedbugs/bug255
-0.03 fixedbugs/bug256
-0.47 fixedbugs/bug257
-0.14 fixedbugs/bug258
-0.16 fixedbugs/bug259
-0.16 fixedbugs/bug260
-0.03 fixedbugs/bug261
-0.10 fixedbugs/bug262
-0.03 fixedbugs/bug263
-0.03 fixedbugs/bug264
-0.07 fixedbugs/bug265
-0.03 fixedbugs/bug266
-0.00 fixedbugs/bug267
-0.03 fixedbugs/bug269
-0.13 fixedbugs/bug271
-0.02 fixedbugs/bug272
-0.04 fixedbugs/bug273
-0.02 fixedbugs/bug274
-0.00 fixedbugs/bug275
-0.03 fixedbugs/bug276
-0.00 fixedbugs/bug277
-0.03 fixedbugs/bug278
-0.04 fixedbugs/bug279
-0.02 fixedbugs/bug280
-0.04 fixedbugs/bug281
-0.00 fixedbugs/bug282
-0.00 fixedbugs/bug283
-0.03 fixedbugs/bug284
-0.05 fixedbugs/bug285
-0.04 fixedbugs/bug286
-0.02 fixedbugs/bug287
-0.00 fixedbugs/bug288
-0.02 fixedbugs/bug289
-0.04 fixedbugs/bug290
-0.04 fixedbugs/bug291
-0.03 fixedbugs/bug292
-0.04 fixedbugs/bug293
-0.03 fixedbugs/bug294
-0.16 fixedbugs/bug295
-0.04 fixedbugs/bug296
-0.03 fixedbugs/bug297
-0.03 fixedbugs/bug298
-0.03 fixedbugs/bug299
-0.03 fixedbugs/bug300
-0.00 fixedbugs/bug301
-0.04 fixedbugs/bug302
-0.05 fixedbugs/bug303
-0.00 fixedbugs/bug304
-0.03 fixedbugs/bug305
-0.01 fixedbugs/bug306
-0.00 fixedbugs/bug307
-0.01 fixedbugs/bug308
-0.00 fixedbugs/bug309
-0.04 fixedbugs/bug311
-0.03 fixedbugs/bug312
-0.04 fixedbugs/bug313
-0.04 fixedbugs/bug314
-0.00 fixedbugs/bug315
-0.00 fixedbugs/bug316
-0.03 fixedbugs/bug317
-0.03 fixedbugs/bug318
-0.00 fixedbugs/bug319
-0.03 fixedbugs/bug320
-0.14 fixedbugs/bug321
-0.04 fixedbugs/bug322
-0.03 fixedbugs/bug323
-0.04 fixedbugs/bug324
-0.03 fixedbugs/bug325
-0.02 fixedbugs/bug326
-0.04 fixedbugs/bug327
-0.03 fixedbugs/bug328
-0.04 fixedbugs/bug329
-0.02 fixedbugs/bug330
-0.04 fixedbugs/bug331
-0.02 fixedbugs/bug332
-0.03 fixedbugs/bug333
-0.01 fixedbugs/bug334
-0.01 fixedbugs/bug335
-0.04 fixedbugs/bug336
-0.03 fixedbugs/bug337
-0.00 fixedbugs/bug338
-0.03 fixedbugs/bug339
-0.02 fixedbugs/bug340
-0.03 fixedbugs/bug341
-0.02 fixedbugs/bug342
-0.04 fixedbugs/bug343
-0.02 fixedbugs/bug344
-0.03 fixedbugs/bug345
-0.08 fixedbugs/bug346
-0.04 fixedbugs/bug347
-0.06 fixedbugs/bug348
-0.03 fixedbugs/bug349
-0.03 fixedbugs/bug350
-0.02 fixedbugs/bug351
-0.03 fixedbugs/bug352
-0.03 fixedbugs/bug353
-0.00 fixedbugs/bug354
-0.03 fixedbugs/bug355
-0.03 fixedbugs/bug356
-0.02 fixedbugs/bug357
-0.04 fixedbugs/bug358
-0.00 fixedbugs/bug361
-0.03 fixedbugs/bug362
-0.03 fixedbugs/bug363
-0.15 fixedbugs/bug364
-0.02 fixedbugs/bug365
-0.03 fixedbugs/bug366
-0.03 fixedbugs/bug367
-0.03 fixedbugs/bug368
-0.51 fixedbugs/bug369
-0.03 fixedbugs/bug370
-0.02 fixedbugs/bug371
-0.03 fixedbugs/bug372
-0.03 fixedbugs/bug373
-0.03 fixedbugs/bug374
-0.03 fixedbugs/bug375
-0.03 fixedbugs/bug376
-0.01 fixedbugs/bug377
-0.03 fixedbugs/bug378
-0.02 fixedbugs/bug379
-0.00 fixedbugs/bug380
-0.03 fixedbugs/bug381
-0.01 fixedbugs/bug382
-0.03 fixedbugs/bug383
-0.03 fixedbugs/bug384
-0.00 fixedbugs/bug385_32
-0.03 fixedbugs/bug385_64
-0.03 fixedbugs/bug386
-0.01 fixedbugs/bug387
-0.02 fixedbugs/bug388
-0.03 fixedbugs/bug389
-0.03 fixedbugs/bug390
-0.00 fixedbugs/bug391
-0.01 fixedbugs/bug392
-0.00 fixedbugs/bug393
-0.03 fixedbugs/bug394
-0.00 fixedbugs/bug395
-0.01 fixedbugs/bug396
diff --git a/gcc/testsuite/go.test/test/turing.go b/gcc/testsuite/go.test/test/turing.go
index 366982e67..acbe85b64 100644
--- a/gcc/testsuite/go.test/test/turing.go
+++ b/gcc/testsuite/go.test/test/turing.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test simulating a Turing machine, sort of.
+
package main
// brainfuck
diff --git a/gcc/testsuite/go.test/test/typeswitch.go b/gcc/testsuite/go.test/test/typeswitch.go
index aa911f9b6..30a4b4975 100644
--- a/gcc/testsuite/go.test/test/typeswitch.go
+++ b/gcc/testsuite/go.test/test/typeswitch.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test simple type switches, including chans, maps etc.
+
package main
import "os"
diff --git a/gcc/testsuite/go.test/test/typeswitch1.go b/gcc/testsuite/go.test/test/typeswitch1.go
index 9613b166f..a980ce4c0 100644
--- a/gcc/testsuite/go.test/test/typeswitch1.go
+++ b/gcc/testsuite/go.test/test/typeswitch1.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test simple type switches on basic types.
+
package main
import "fmt"
diff --git a/gcc/testsuite/go.test/test/typeswitch2.go b/gcc/testsuite/go.test/test/typeswitch2.go
index 3e3acdae3..6c703076a 100644
--- a/gcc/testsuite/go.test/test/typeswitch2.go
+++ b/gcc/testsuite/go.test/test/typeswitch2.go
@@ -1,9 +1,12 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that various erroneous type switches are caught be the compiler.
+// Does not compile.
+
package main
import "io"
diff --git a/gcc/testsuite/go.test/test/typeswitch3.go b/gcc/testsuite/go.test/test/typeswitch3.go
index 99d08a20f..287e32e71 100644
--- a/gcc/testsuite/go.test/test/typeswitch3.go
+++ b/gcc/testsuite/go.test/test/typeswitch3.go
@@ -1,20 +1,43 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that erroneous type switches are caught be the compiler.
+// Issue 2700, among other things.
+// Does not compile.
+
package main
+import (
+ "io"
+)
type I interface {
- M()
+ M()
}
func main(){
- var x I
- switch x.(type) {
- case string: // ERROR "impossible"
- println("FAIL")
- }
+ var x I
+ switch x.(type) {
+ case string: // ERROR "impossible"
+ println("FAIL")
+ }
+
+ // Issue 2700: if the case type is an interface, nothing is impossible
+
+ var r io.Reader
+
+ _, _ = r.(io.Writer)
+
+ switch r.(type) {
+ case io.Writer:
+ }
+
+ // Issue 2827.
+ switch _ := r.(type) { // ERROR "invalid variable name _|no new variables"
+ }
}
+
+
diff --git a/gcc/testsuite/go.test/test/undef.go b/gcc/testsuite/go.test/test/undef.go
index 7ef07882a..0a77e5937 100644
--- a/gcc/testsuite/go.test/test/undef.go
+++ b/gcc/testsuite/go.test/test/undef.go
@@ -1,10 +1,11 @@
-// errchk $G -e $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-// Check line numbers in error messages.
+// Test line numbers in error messages.
+// Does not compile.
package main
diff --git a/gcc/testsuite/go.test/test/utf.go b/gcc/testsuite/go.test/test/utf.go
index 9fba58156..3ac79447e 100644
--- a/gcc/testsuite/go.test/test/utf.go
+++ b/gcc/testsuite/go.test/test/utf.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test UTF-8 in strings and character constants.
+
package main
import "unicode/utf8"
diff --git a/gcc/testsuite/go.test/test/varerr.go b/gcc/testsuite/go.test/test/varerr.go
index ddd718f5b..22aa9324f 100644
--- a/gcc/testsuite/go.test/test/varerr.go
+++ b/gcc/testsuite/go.test/test/varerr.go
@@ -1,9 +1,12 @@
-// errchk $G $D/$F.go
+// errorcheck
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Verify that a couple of illegal variable declarations are caught by the compiler.
+// Does not compile.
+
package main
func main() {
diff --git a/gcc/testsuite/go.test/test/varinit.go b/gcc/testsuite/go.test/test/varinit.go
index c76877793..84a4a1aa5 100644
--- a/gcc/testsuite/go.test/test/varinit.go
+++ b/gcc/testsuite/go.test/test/varinit.go
@@ -1,9 +1,11 @@
-// $G $D/$F.go && $L $F.$A && ./$A.out || echo BUG wrong result
+// run
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test var x = x + 1 works.
+
package main
func main() {
diff --git a/gcc/testsuite/go.test/test/zerodivide.go b/gcc/testsuite/go.test/test/zerodivide.go
index 3b08e774c..673d1d18d 100644
--- a/gcc/testsuite/go.test/test/zerodivide.go
+++ b/gcc/testsuite/go.test/test/zerodivide.go
@@ -1,9 +1,11 @@
-// $G $F.go && $L $F.$A && ./$A.out
+// run
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+// Test that zero division causes a panic.
+
package main
import (