> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# ApuIsVirtualAddressValid

> ApuIsVirtualAddressValid

# ApuIsVirtualAddressValid

Verifies a virtual address.

## Syntax

```cpp theme={null}
bool ApuIsVirtualAddressValid(  
         const void* virtualAddress,  
         UINT32 physicalAlignmentInBytes  
)  
```

### Parameters

*virtualAddress*   \_In\_\
Type: void\*

Virtual address to verify.

*physicalAlignmentInBytes*   \
Type: UINT32

Expected alignment of the physical address.

### Return value

Type: bool

Returns true if the virtual address is valid, false otherwise.

## Remarks

This function verifies that the specified virtual address is valid, that it was allocated with [ApuAlloc](/reference/audio/apu/functions/apualloc), and that the associated APU physical address has the specified alignment.

To determine the associated physical address, call [ApuMapVirtualAddress](/reference/audio/apu/functions/apumapvirtualaddress). If the physical address is known, call [ApuMapApuAddress](/reference/audio/apu/functions/apumapapuaddress) to determine the associated virtual address.

## Requirements

**Header:** apu.h

**Library:** acphal.lib

**Supported platforms:** XBOX One family consoles and XBOX Series consoles

## See also

[ApuMapVirtualAddress](/reference/audio/apu/functions/apumapvirtualaddress)\
[ApuMapApuAddress](/reference/audio/apu/functions/apumapapuaddress)\
[APU](/reference/audio/apu/apu_members)


## Related topics

- [ApuMapVirtualAddress](/reference/audio/apu/functions/apumapvirtualaddress.md)
- [APU (Audio Processing Unit)](/reference/audio/apu/apu_members.md)
- [ApuMapApuAddress](/reference/audio/apu/functions/apumapapuaddress.md)
- [ApuFree](/reference/audio/apu/functions/apufree.md)
- [ApuAlloc](/reference/audio/apu/functions/apualloc.md)
