Skip to content

Commit c941c6e

Browse files
committed
Fix IR representation section
Signed-off-by: Steffen Larsen <[email protected]>
1 parent 9abc31a commit c941c6e

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

sycl/doc/design/CompileTimeProperties.md

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -603,18 +603,20 @@ types listed above.
603603

604604
Properties that are implemented using
605605
`[[__sycl_detail__::add_ir_annotations_member()]]`, are represented in LLVM IR
606-
as the fifth metadata parameter to the `@llvm.ptr.annotation` intrinsic
607-
function. This parameter is a tuple of metadata values with the following
608-
sequence:
606+
as the fifth parameter to the `@llvm.ptr.annotation` intrinsic function. This
607+
parameter is a pointer to a global variable with fields corresponding to the
608+
names and values of the properties in the following sequence:
609609

610610
* Name of the first property
611611
* Value of the first property
612612
* Name of the second property
613613
* Value of the second property
614614
* Etc.
615615

616-
Since metadata types are not limited to strings, there is no need to convert
617-
the property values to strings.
616+
Every field in the global variable pointed to by this parameter are string
617+
literals in seperate global variables. If the value of a property is either an
618+
empty string or a `nullptr`, the corresponding field will have a null-pointer
619+
value.
618620

619621

620622
## Filtering properties

0 commit comments

Comments
 (0)