Skip to content

Commit

Permalink
Merge branch 'main' into steffen/record_event
Browse files Browse the repository at this point in the history
  • Loading branch information
steffenlarsen authored Mar 5, 2024
2 parents 2f0e050 + b183740 commit 32abd74
Show file tree
Hide file tree
Showing 11 changed files with 958 additions and 237 deletions.
12 changes: 12 additions & 0 deletions cmake/match.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,18 @@ def main():
print_incorrect_match(match_idx + 1, input_lines[input_idx].strip(), "");
print_content(input_lines, match_lines, ignored_lines)
sys.exit(1)
elif status == Status.INPUT_END:
# If we get to the end of the input, but still have pending matches,
# then that's a failure unless all pending matches are optional -
# otherwise we're done
while match_idx < len(match_lines):
if not (match_lines[match_idx].startswith(Tag.OPT.value) or
match_lines[match_idx].startswith(Tag.IGNORE.value)):
print_incorrect_match(match_idx + 1, "", match_lines[match_idx]);
print_content(input_lines, match_lines, ignored_lines)
sys.exit(1)
match_idx += 1
sys.exit(0)

input_line = input_lines[input_idx].strip() if input_idx < len(input_lines) else ""
match_line = match_lines[match_idx]
Expand Down
5 changes: 3 additions & 2 deletions include/ur_api.h
Original file line number Diff line number Diff line change
Expand Up @@ -4338,8 +4338,9 @@ typedef enum ur_program_info_t {
///< provided for identifying memory leaks.
UR_PROGRAM_INFO_CONTEXT = 1, ///< [::ur_context_handle_t] Program context info.
UR_PROGRAM_INFO_NUM_DEVICES = 2, ///< [uint32_t] Return number of devices associated with Program.
UR_PROGRAM_INFO_DEVICES = 3, ///< [::ur_device_handle_t[]] Return list of devices associated with
///< Program.
UR_PROGRAM_INFO_DEVICES = 3, ///< [::ur_device_handle_t[]] Return list of devices associated with a program.
///< This is either the list of devices associated with the context or a
///< subset of those devices when the program is created using ::urProgramCreateWithBinary.
UR_PROGRAM_INFO_SOURCE = 4, ///< [char[]] Return program source associated with Program.
UR_PROGRAM_INFO_BINARY_SIZES = 5, ///< [size_t[]] Return program binary sizes for each device.
UR_PROGRAM_INFO_BINARIES = 6, ///< [unsigned char[]] Return program binaries for all devices for this
Expand Down
4 changes: 4 additions & 0 deletions scripts/YaML.md
Original file line number Diff line number Diff line change
Expand Up @@ -314,6 +314,10 @@ class ur_name_handle_t(c_void_p):
</table>

#### type: enum

In the following section the word *enumerator* is abbreviated to `etor` and the
plural form *enumerators* is abbreviated to `etors`.

* An enum initiates the creation of a C/C++ `enum` declaration in the specification
* An enum requires the following scalar fields: {`desc`, `name`}
- `desc` will be used as the enum's description comment
Expand Down
4 changes: 3 additions & 1 deletion scripts/core/program.yml
Original file line number Diff line number Diff line change
Expand Up @@ -327,7 +327,9 @@ etors:
- name: NUM_DEVICES
desc: "[uint32_t] Return number of devices associated with Program."
- name: DEVICES
desc: "[$x_device_handle_t[]] Return list of devices associated with Program."
desc: |
[$x_device_handle_t[]] Return list of devices associated with a program.
This is either the list of devices associated with the context or a subset of those devices when the program is created using $xProgramCreateWithBinary.
- name: SOURCE
desc: "[char[]] Return program source associated with Program."
- name: BINARY_SIZES
Expand Down
2 changes: 1 addition & 1 deletion source/adapters/level_zero/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ if (NOT DEFINED LEVEL_ZERO_LIBRARY OR NOT DEFINED LEVEL_ZERO_INCLUDE_DIR)
endif()

set(LEVEL_ZERO_LOADER_REPO "https://github.com/oneapi-src/level-zero.git")
set(LEVEL_ZERO_LOADER_TAG v1.15.1)
set(LEVEL_ZERO_LOADER_TAG v1.16.1)

# Disable due to a bug https://github.com/oneapi-src/level-zero/issues/104
set(CMAKE_INCLUDE_CURRENT_DIR OFF)
Expand Down
25 changes: 25 additions & 0 deletions source/adapters/level_zero/device.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -922,6 +922,31 @@ UR_APIEXPORT ur_result_t UR_APICALL urDeviceGetInfo(
return ReturnValue(true);
case UR_DEVICE_INFO_COMMAND_BUFFER_UPDATE_SUPPORT_EXP:
return ReturnValue(false);
case UR_DEVICE_INFO_BINDLESS_IMAGES_SUPPORT_EXP:
return ReturnValue(true);
case UR_DEVICE_INFO_BINDLESS_IMAGES_SHARED_USM_SUPPORT_EXP:
return ReturnValue(true);
case UR_DEVICE_INFO_BINDLESS_IMAGES_1D_USM_SUPPORT_EXP:
return ReturnValue(false);
case UR_DEVICE_INFO_BINDLESS_IMAGES_2D_USM_SUPPORT_EXP:
return ReturnValue(true);
case UR_DEVICE_INFO_IMAGE_PITCH_ALIGN_EXP:
case UR_DEVICE_INFO_MAX_IMAGE_LINEAR_WIDTH_EXP:
case UR_DEVICE_INFO_MAX_IMAGE_LINEAR_HEIGHT_EXP:
case UR_DEVICE_INFO_MAX_IMAGE_LINEAR_PITCH_EXP:
urPrint("Unsupported ParamName in urGetDeviceInfo\n");
urPrint("ParamName=%d(0x%x)\n", ParamName, ParamName);
return UR_RESULT_ERROR_INVALID_VALUE;
case UR_DEVICE_INFO_MIPMAP_SUPPORT_EXP:
return ReturnValue(true);
case UR_DEVICE_INFO_MIPMAP_ANISOTROPY_SUPPORT_EXP:
return ReturnValue(true);
case UR_DEVICE_INFO_MIPMAP_MAX_ANISOTROPY_EXP:
case UR_DEVICE_INFO_MIPMAP_LEVEL_REFERENCE_SUPPORT_EXP:
case UR_DEVICE_INFO_INTEROP_MEMORY_IMPORT_SUPPORT_EXP:
case UR_DEVICE_INFO_INTEROP_MEMORY_EXPORT_SUPPORT_EXP:
case UR_DEVICE_INFO_INTEROP_SEMAPHORE_IMPORT_SUPPORT_EXP:
case UR_DEVICE_INFO_INTEROP_SEMAPHORE_EXPORT_SUPPORT_EXP:
default:
urPrint("Unsupported ParamName in urGetDeviceInfo\n");
urPrint("ParamName=%d(0x%x)\n", ParamName, ParamName);
Expand Down
Loading

0 comments on commit 32abd74

Please sign in to comment.