Skip to content

Commit

Permalink
Merge pull request #2049 from aarongreig/aaron/v0.10.2
Browse files Browse the repository at this point in the history
  Candidate for the v0.10.2 release tag
  • Loading branch information
callumfare authored Sep 6, 2024
2 parents 46f5a40 + b4d2783 commit f68966e
Show file tree
Hide file tree
Showing 5 changed files with 270 additions and 2 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception

cmake_minimum_required(VERSION 3.20.0 FATAL_ERROR)
project(unified-runtime VERSION 0.10.1)
project(unified-runtime VERSION 0.10.2)

# Check if unified runtime is built as a standalone project.
if(CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR OR UR_STANDALONE_BUILD)
Expand Down
212 changes: 212 additions & 0 deletions include/ur_api_funcs.def
Original file line number Diff line number Diff line change
@@ -0,0 +1,212 @@

/*
*
* Copyright (C) 2024 Intel Corporation
*
* Part of the Unified-Runtime Project, under the Apache License v2.0 with LLVM Exceptions.
* See LICENSE.TXT
* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
*
* @file ur_api_funcs.def
* @version v0.10-r0
*
*/

// Auto-generated file, do not edit.

_UR_API(urPlatformGet)
_UR_API(urPlatformGetInfo)
_UR_API(urPlatformGetNativeHandle)
_UR_API(urPlatformCreateWithNativeHandle)
_UR_API(urPlatformGetApiVersion)
_UR_API(urPlatformGetBackendOption)
_UR_API(urContextCreate)
_UR_API(urContextRetain)
_UR_API(urContextRelease)
_UR_API(urContextGetInfo)
_UR_API(urContextGetNativeHandle)
_UR_API(urContextCreateWithNativeHandle)
_UR_API(urContextSetExtendedDeleter)
_UR_API(urEventGetInfo)
_UR_API(urEventGetProfilingInfo)
_UR_API(urEventWait)
_UR_API(urEventRetain)
_UR_API(urEventRelease)
_UR_API(urEventGetNativeHandle)
_UR_API(urEventCreateWithNativeHandle)
_UR_API(urEventSetCallback)
_UR_API(urProgramCreateWithIL)
_UR_API(urProgramCreateWithBinary)
_UR_API(urProgramBuild)
_UR_API(urProgramCompile)
_UR_API(urProgramLink)
_UR_API(urProgramRetain)
_UR_API(urProgramRelease)
_UR_API(urProgramGetFunctionPointer)
_UR_API(urProgramGetGlobalVariablePointer)
_UR_API(urProgramGetInfo)
_UR_API(urProgramGetBuildInfo)
_UR_API(urProgramSetSpecializationConstants)
_UR_API(urProgramGetNativeHandle)
_UR_API(urProgramCreateWithNativeHandle)
_UR_API(urProgramBuildExp)
_UR_API(urProgramCompileExp)
_UR_API(urProgramLinkExp)
_UR_API(urKernelCreate)
_UR_API(urKernelGetInfo)
_UR_API(urKernelGetGroupInfo)
_UR_API(urKernelGetSubGroupInfo)
_UR_API(urKernelRetain)
_UR_API(urKernelRelease)
_UR_API(urKernelGetNativeHandle)
_UR_API(urKernelCreateWithNativeHandle)
_UR_API(urKernelGetSuggestedLocalWorkSize)
_UR_API(urKernelSetArgValue)
_UR_API(urKernelSetArgLocal)
_UR_API(urKernelSetArgPointer)
_UR_API(urKernelSetExecInfo)
_UR_API(urKernelSetArgSampler)
_UR_API(urKernelSetArgMemObj)
_UR_API(urKernelSetSpecializationConstants)
_UR_API(urKernelSuggestMaxCooperativeGroupCountExp)
_UR_API(urQueueGetInfo)
_UR_API(urQueueCreate)
_UR_API(urQueueRetain)
_UR_API(urQueueRelease)
_UR_API(urQueueGetNativeHandle)
_UR_API(urQueueCreateWithNativeHandle)
_UR_API(urQueueFinish)
_UR_API(urQueueFlush)
_UR_API(urSamplerCreate)
_UR_API(urSamplerRetain)
_UR_API(urSamplerRelease)
_UR_API(urSamplerGetInfo)
_UR_API(urSamplerGetNativeHandle)
_UR_API(urSamplerCreateWithNativeHandle)
_UR_API(urMemImageCreate)
_UR_API(urMemBufferCreate)
_UR_API(urMemRetain)
_UR_API(urMemRelease)
_UR_API(urMemBufferPartition)
_UR_API(urMemGetNativeHandle)
_UR_API(urMemBufferCreateWithNativeHandle)
_UR_API(urMemImageCreateWithNativeHandle)
_UR_API(urMemGetInfo)
_UR_API(urMemImageGetInfo)
_UR_API(urPhysicalMemCreate)
_UR_API(urPhysicalMemRetain)
_UR_API(urPhysicalMemRelease)
_UR_API(urAdapterGet)
_UR_API(urAdapterRelease)
_UR_API(urAdapterRetain)
_UR_API(urAdapterGetLastError)
_UR_API(urAdapterGetInfo)
_UR_API(urEnqueueKernelLaunch)
_UR_API(urEnqueueEventsWait)
_UR_API(urEnqueueEventsWaitWithBarrier)
_UR_API(urEnqueueMemBufferRead)
_UR_API(urEnqueueMemBufferWrite)
_UR_API(urEnqueueMemBufferReadRect)
_UR_API(urEnqueueMemBufferWriteRect)
_UR_API(urEnqueueMemBufferCopy)
_UR_API(urEnqueueMemBufferCopyRect)
_UR_API(urEnqueueMemBufferFill)
_UR_API(urEnqueueMemImageRead)
_UR_API(urEnqueueMemImageWrite)
_UR_API(urEnqueueMemImageCopy)
_UR_API(urEnqueueMemBufferMap)
_UR_API(urEnqueueMemUnmap)
_UR_API(urEnqueueUSMFill)
_UR_API(urEnqueueUSMMemcpy)
_UR_API(urEnqueueUSMPrefetch)
_UR_API(urEnqueueUSMAdvise)
_UR_API(urEnqueueUSMFill2D)
_UR_API(urEnqueueUSMMemcpy2D)
_UR_API(urEnqueueDeviceGlobalVariableWrite)
_UR_API(urEnqueueDeviceGlobalVariableRead)
_UR_API(urEnqueueReadHostPipe)
_UR_API(urEnqueueWriteHostPipe)
_UR_API(urEnqueueKernelLaunchCustomExp)
_UR_API(urEnqueueCooperativeKernelLaunchExp)
_UR_API(urEnqueueTimestampRecordingExp)
_UR_API(urEnqueueNativeCommandExp)
_UR_API(urBindlessImagesUnsampledImageHandleDestroyExp)
_UR_API(urBindlessImagesSampledImageHandleDestroyExp)
_UR_API(urBindlessImagesImageAllocateExp)
_UR_API(urBindlessImagesImageFreeExp)
_UR_API(urBindlessImagesUnsampledImageCreateExp)
_UR_API(urBindlessImagesSampledImageCreateExp)
_UR_API(urBindlessImagesImageCopyExp)
_UR_API(urBindlessImagesImageGetInfoExp)
_UR_API(urBindlessImagesMipmapGetLevelExp)
_UR_API(urBindlessImagesMipmapFreeExp)
_UR_API(urBindlessImagesImportExternalMemoryExp)
_UR_API(urBindlessImagesMapExternalArrayExp)
_UR_API(urBindlessImagesMapExternalLinearMemoryExp)
_UR_API(urBindlessImagesReleaseExternalMemoryExp)
_UR_API(urBindlessImagesImportExternalSemaphoreExp)
_UR_API(urBindlessImagesReleaseExternalSemaphoreExp)
_UR_API(urBindlessImagesWaitExternalSemaphoreExp)
_UR_API(urBindlessImagesSignalExternalSemaphoreExp)
_UR_API(urUSMHostAlloc)
_UR_API(urUSMDeviceAlloc)
_UR_API(urUSMSharedAlloc)
_UR_API(urUSMFree)
_UR_API(urUSMGetMemAllocInfo)
_UR_API(urUSMPoolCreate)
_UR_API(urUSMPoolRetain)
_UR_API(urUSMPoolRelease)
_UR_API(urUSMPoolGetInfo)
_UR_API(urUSMPitchedAllocExp)
_UR_API(urUSMImportExp)
_UR_API(urUSMReleaseExp)
_UR_API(urCommandBufferCreateExp)
_UR_API(urCommandBufferRetainExp)
_UR_API(urCommandBufferReleaseExp)
_UR_API(urCommandBufferFinalizeExp)
_UR_API(urCommandBufferAppendKernelLaunchExp)
_UR_API(urCommandBufferAppendUSMMemcpyExp)
_UR_API(urCommandBufferAppendUSMFillExp)
_UR_API(urCommandBufferAppendMemBufferCopyExp)
_UR_API(urCommandBufferAppendMemBufferWriteExp)
_UR_API(urCommandBufferAppendMemBufferReadExp)
_UR_API(urCommandBufferAppendMemBufferCopyRectExp)
_UR_API(urCommandBufferAppendMemBufferWriteRectExp)
_UR_API(urCommandBufferAppendMemBufferReadRectExp)
_UR_API(urCommandBufferAppendMemBufferFillExp)
_UR_API(urCommandBufferAppendUSMPrefetchExp)
_UR_API(urCommandBufferAppendUSMAdviseExp)
_UR_API(urCommandBufferEnqueueExp)
_UR_API(urCommandBufferRetainCommandExp)
_UR_API(urCommandBufferReleaseCommandExp)
_UR_API(urCommandBufferUpdateKernelLaunchExp)
_UR_API(urCommandBufferGetInfoExp)
_UR_API(urCommandBufferCommandGetInfoExp)
_UR_API(urUsmP2PEnablePeerAccessExp)
_UR_API(urUsmP2PDisablePeerAccessExp)
_UR_API(urUsmP2PPeerAccessGetInfoExp)
_UR_API(urVirtualMemGranularityGetInfo)
_UR_API(urVirtualMemReserve)
_UR_API(urVirtualMemFree)
_UR_API(urVirtualMemMap)
_UR_API(urVirtualMemUnmap)
_UR_API(urVirtualMemSetAccess)
_UR_API(urVirtualMemGetInfo)
_UR_API(urDeviceGet)
_UR_API(urDeviceGetInfo)
_UR_API(urDeviceRetain)
_UR_API(urDeviceRelease)
_UR_API(urDevicePartition)
_UR_API(urDeviceSelectBinary)
_UR_API(urDeviceGetNativeHandle)
_UR_API(urDeviceCreateWithNativeHandle)
_UR_API(urDeviceGetGlobalTimestamps)
_UR_API(urLoaderConfigCreate)
_UR_API(urLoaderConfigEnableLayer)
_UR_API(urLoaderConfigGetInfo)
_UR_API(urLoaderConfigRelease)
_UR_API(urLoaderConfigRetain)
_UR_API(urLoaderConfigSetCodeLocationCallback)
_UR_API(urLoaderConfigSetMockingEnabled)
_UR_API(urLoaderInit)
_UR_API(urLoaderTearDown)
21 changes: 21 additions & 0 deletions scripts/generate_code.py
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,26 @@ def _mako_print_cpp(path, namespace, tags, version, specs, meta):
specs=specs,
meta=meta)


def _mako_api_funcs(path, namespace, tags, version, revision, specs, meta):
template = "api_funcs.def.mako"
fin = os.path.join(templates_dir, template)

name = "%s_api_funcs"%(namespace)
filename = "%s.def"%(name)
fout = os.path.join(path, filename)

print("Generating %s..."%fout)
return util.makoWrite(
fin, fout,
name=name,
ver=version,
rev=revision,
namespace=namespace,
tags=tags,
specs=specs,
meta=meta)

"""
generates c/c++ files from the specification documents
"""
Expand All @@ -116,6 +136,7 @@ def _generate_api_cpp(incpath, srcpath, namespace, tags, version, revision, spec
loc += _mako_api_cpp(srcpath, namespace, tags, version, revision, specs, meta)
loc += _mako_ddi_h(incpath, namespace, tags, version, revision, specs, meta)
loc += _mako_print_hpp(incpath, namespace, tags, version, revision, specs, meta)
loc += _mako_api_funcs(incpath, namespace, tags, version, revision, specs, meta)

return loc

Expand Down
35 changes: 35 additions & 0 deletions scripts/templates/api_funcs.def.mako
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
<%!
import re
from templates import helper as th
%><%
n=namespace
N=n.upper()
x=tags['$x']
X=x.upper()
%>
/*
*
* Copyright (C) 2024 Intel Corporation
*
* Part of the Unified-Runtime Project, under the Apache License v2.0 with LLVM Exceptions.
* See LICENSE.TXT
* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
*
* @file ${name}.def
* @version v${ver}-r${rev}
*
*/

// Auto-generated file, do not edit.

%for tbl in th.get_pfntables(specs, meta, n, tags):
%for obj in tbl['functions']:
_UR_API(${th.make_func_name(n, tags, obj)})
%endfor
%endfor
%for obj in th.get_loader_functions(specs, meta, n, tags):
%if n + "Loader" in obj:
_UR_API(${obj})
%endif
%endfor
2 changes: 1 addition & 1 deletion source/adapters/opencl/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ if(UR_OPENCL_INCLUDE_DIR)
else()
FetchContent_Declare(OpenCL-Headers
GIT_REPOSITORY "https://github.com/KhronosGroup/OpenCL-Headers.git"
GIT_TAG main
GIT_TAG 1e193332d02e27e15812d24ff2a3a7a908eb92a3
)
FetchContent_MakeAvailable(OpenCL-Headers)
FetchContent_GetProperties(OpenCL-Headers
Expand Down

0 comments on commit f68966e

Please sign in to comment.