---
name: "store"
section: "9"
platform: "freebsd"
package: "base"
version: "16.0-CURRENT-20261027-61c70dc16a79"
release: "FreeBSD 16.0-CURRENT (2026-10-27)"
platforms: ["linux", "freebsd", "macos"]
url: "https://new.carta.tech/store/9"
---

# store(9)

store data to user-space

## NAME

**store**, **subyte**, **suptr**, **suword** – store data to user-space

## SYNOPSIS

**#include \<sys/types.h\>**

**#include \<sys/time.h\>**

**#include \<sys/systm.h\>**

*int*\

**subyte**(*volatile void \*base*, *int byte*);

*int*\

**suptr**(*volatile void \*base*, *intptr\_t ptr*);

*int*\

**suword**(*volatile void \*base*, *long word*);

*int*\

**suword16**(*volatile void \*base*, *int word*);

*int*\

**suword32**(*volatile void \*base*, *int32\_t word*);

*int*\

**suword64**(*volatile void \*base*, *int64\_t word*);

## DESCRIPTION

The **store** functions are designed to copy small amounts of data to user-space. If the user address is naturally aligned, then the operation will be performed atomically. Otherwise it may fail or be performed non-atomically, depending on the platform.

The **store** routines provide the following functionality:

- **subyte**()

  Stores a byte of data to the user-space address *base*.

- **suptr**()

  Stores a pointer to the user-space address *base* preserving the provenance of that pointer (see [memory\_model(7)](/memory_model/7.md) for further information).

- **suword**()

  Stores a word of data to the user-space address *base*.

- **suword16**()

  Stores 16 bits of data to the user-space address *base*.

- **suword32**()

  Stores 32 bits of data to the user-space address *base*.

- **suword64**()

  Stores 64 bits of data to the user-space address *base*.

## RETURN VALUES

The **store** functions return 0 on success or -1 on failure.

## SEE ALSO

[copy(9)](/copy/9.md), [fetch(9)](/fetch/9.md)
