dataset¶
| Source (upstream pre-purge) | Current | |
|---|---|---|
| File | consensus/ethash/ethash.go |
ethash.go |
| Symbol | dataset |
dataset |
| Ref | dde2da0ef~1 |
etc/v1.17.3-full-node |
3-way merge — purge → getc ← upstream¶
pre-purgecore-geth
↗// dataset wraps an ethash dataset with some metadata to allow easier concurrent use.
type dataset struct {
↗ epoch uint64 // Epoch for which this cache is relevant
epochLength uint64 // Epoch length (ECIP-1099)
dump *os.File // File descriptor of the memory mapped cache
mmap mmap.MMap // Memory map itself to unmap before releasing
dataset []uint32 // The actual cache data content
once sync.Once // Ensures the cache is generated only once
done atomic.Bool // Atomic flag to determine generation status
↗}