Map represents a Map file descriptor. It is not safe to close a Map which is used by other goroutines. Map operations taking `any` arguments are encoded using [sysenc.Marshal], which is zero-copy for fixed-size types without padding as well as slices of bytes, but may involve allocations for other
| 322 | // Implement encoding.BinaryMarshaler or encoding.BinaryUnmarshaler if you |
| 323 | // require custom encoding or decoding. |
| 324 | type Map struct { |
| 325 | name string |
| 326 | fd *sys.FD |
| 327 | typ MapType |
| 328 | keySize uint32 |
| 329 | valueSize uint32 |
| 330 | maxEntries uint32 |
| 331 | flags uint32 |
| 332 | pinnedPath string |
| 333 | // Per CPU maps return values larger than the size in the spec |
| 334 | fullValueSize int |
| 335 | |
| 336 | memory *Memory |
| 337 | } |
| 338 | |
| 339 | // NewMapFromFD creates a [Map] around a raw fd. |
| 340 | // |
nothing calls this directly
no outgoing calls
no test coverage detected