> For the complete documentation index, see [llms.txt](https://docs.hyperdbg.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.hyperdbg.org/commands/debugging-commands/gu.md).

# gu (step-out or go up)

Description of the 'gu' command in HyperDbg.

### Command

> gu

### Syntax

> gu
>
> gu \[Count (hex)]

### Description

Executes instructions one by one until one **RET** instruction is executed (step-out or go up).

### Parameters

**\[Count (hex)] (optional)**

The number of **instructions** to perform the instrumentation (The execution might not meet a RET instruction if not enough number is specified).

### Examples

If you want to step-out or go up from the current function.

```
4: kHyperDbg> gu
ntkrnlmp!KiSystemServiceCopyEnd+0x25:
fffff802`2d045fe5    0F 1F 00                            nop dword ptr ds:[rax], eax
```

### SDK

To step-out or go up in the target debuggee, you need to use the following function in `libhyperdbg`:

```clike
BOOLEAN
hyperdbg_u_stepping_step_over_for_gu(BOOLEAN last_instruction);
```

### Remarks

Starting from **v0.6**, this command was added to the HyperDbg debugger.

This command is the same as the '[p (step-over)](https://docs.hyperdbg.org/commands/debugging-commands/p)' except it checks whether the instruction is equal to **RET** or not.

All cores and threads (except the currently executing thread) find a chance to be executed between each step in this command.

### Requirements

None

### Related

[k, kd, kq (display stack backtrace)](https://docs.hyperdbg.org/commands/debugging-commands/k)

[p (step-over)](https://docs.hyperdbg.org/commands/debugging-commands/p)

[t (step-in)](https://docs.hyperdbg.org/commands/debugging-commands/t)

[i (instrumentation step-in)](https://docs.hyperdbg.org/commands/debugging-commands/i)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.hyperdbg.org/commands/debugging-commands/gu.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
