...

Source file src/cmd/cgo/internal/testshared/testdata/globallib/global.go

Documentation: cmd/cgo/internal/testshared/testdata/globallib

     1  // Copyright 2017 The Go Authors. All rights reserved.
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  package globallib
     6  
     7  // Data is large enough to that offsets into it do not fit into
     8  // 16-bit or 20-bit immediates. Ideally we'd also try and overrun
     9  // 32-bit immediates, but that requires the test machine to have
    10  // too much memory.
    11  var Data [1<<20 + 10]int64
    12  
    13  func init() {
    14  	for i := range Data {
    15  		Data[i] = int64(i)
    16  	}
    17  }
    18  

View as plain text