-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Specify aliasing and address space for vk::BufferPointer (#53)
* Specify aliasing and address space for vk::BufferPointer Fixes #42. * Refer to C99 for definition of restrict pointer. * Explicitly specify buffer pointers point into host memory address space.
- Loading branch information
1 parent
6a92f4d
commit cbd3fdb
Showing
1 changed file
with
10 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -180,6 +180,16 @@ A vk::BufferPointer can otherwise be used whereever the HLSL spec does not other | |
|
||
Applying HLSL semantic annotations to objects of type vk::BufferPointer is disallowed. | ||
|
||
### Buffer Pointers and Aliasing | ||
|
||
By default, buffer pointers are assumed to be restrict pointers as defined by the C99 standard. | ||
|
||
An attribute vk::aliased_pointer can be attached to a variable, function parameter or a block member of buffer pointer type. It is assumed that the pointee of an object with this attribute can overlap with the pointee of any other object with this attribute. | ||
|
||
### Buffer Pointers and Address Space | ||
|
||
All buffer pointers are presumed to point into the host memory address space. No new address space attributes are proposed. | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
llvm-beanz
Collaborator
|
||
|
||
### Buffer Pointer Availability | ||
|
||
The following can be used at pre-processor time to determine if the current compiler supports vk::BufferPointer: __has_feature(hlsl_vk_buffer_pointer). | ||
|
isn't "host" the address space of the CPU, and "device" of the GPU?
Or does DX + HLSL use some different reverse terminology?
BDA
uint64_t
address AFAIK cannot be just casted into avoid*