You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: hashmap.go
    path of file: ./repos/gotosocial/vendor/github.com/cornelk/hashmap
    
    the code of the file until where you have to start completion: // Package hashmap provides a lock-free and thread-safe HashMap.
package hashmap

import (
	"bytes"
	"fmt"
	"reflect"
	"strconv"
	"sync/atomic"
	"unsafe"
)

// Map implements a read optimized hash map.
type Map[Key hashable, Value any] struct {
	hasher     func(Key) uintptr
	store      atomic.Pointer[store[Key, Value]] // pointer to a map instance
    
func (m *Map[Key, Value]) GetOrInsert(key Key, value Value) (Value, bool) {
	hash := m.hasher(key)
	var newElement *ListElement[Key, Value]

	for {
		for element := m.store.Load().item(hash); element != nil; element = element.Next() {
			if element.keyHash == hash && element.key == key {
				actual := element.Value()
				return actual, true
			}

			if element.keyHash > hash {
				break
			}
		}

		if newElement == nil { // allocate only once
			newElement = &ListElement[Key, Value]{
				key:     key,
				keyHash: hash,
			}
			newElement.value.Store(&value)
		}

		if m.insertElement(newElement, hash, key, value) {
			return value, false
		}
	}
}