This is the mail archive of the gcc-cvs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

r249594 - in /trunk/gcc/go/gofrontend: MERGE ex...


Author: ian
Date: Fri Jun 23 16:03:49 2017
New Revision: 249594

URL: https://gcc.gnu.org/viewcvs?rev=249594&root=gcc&view=rev
Log:
    compiler: add go:notinheap magic comment
    
    Implement go:notinheap as the gc compiler does. A type marked as
    go:notinheap may not live in the heap, and does not require a write
    barrier. Struct and array types that incorporate notinheap types are
    themselves notinheap. Allocating a value of a notinheap type on the
    heap is an error.
    
    This is not just an optimization. There is code where a write barrier
    may not occur that was getting a write barrier with gccgo but not gc,
    because the types in question were notinheap. The case I found was
    setting the mcache field in exitsyscallfast.
    
    Reviewed-on: https://go-review.googlesource.com/46490

Modified:
    trunk/gcc/go/gofrontend/MERGE
    trunk/gcc/go/gofrontend/expressions.cc
    trunk/gcc/go/gofrontend/expressions.h
    trunk/gcc/go/gofrontend/lex.cc
    trunk/gcc/go/gofrontend/lex.h
    trunk/gcc/go/gofrontend/parse.cc
    trunk/gcc/go/gofrontend/parse.h
    trunk/gcc/go/gofrontend/types.cc
    trunk/gcc/go/gofrontend/types.h
    trunk/gcc/go/gofrontend/wb.cc


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]