Nios® V Processor Software Developer Handbook

ID 743810
Date 7/08/2024
Public
Document Table of Contents

16.1.1.64. sbrk()

Prototype

caddr_t sbrk(int incr)

Commonly Called By

newlib C library

Thread-safe

No.

Available from ISR

No.

Include

<unistd.h>

Description

The sbrk() function dynamically extends the data segment for the application. The input argument incr is the size of the block to allocate. Do not call sbrk() directly. If you want to dynamically allocate memory, use the newlib malloc() function.

Return

--