Skip to content

Commit 6096263

Browse files
Process extra tokens when create command queue with properties
Change-Id: I8f7d1aeaa7ed1a21e9c35794e5453ffa1ab67d5f Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
1 parent 551ed7f commit 6096263

File tree

5 files changed

+34
-2
lines changed

5 files changed

+34
-2
lines changed

Jenkinsfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
#!groovy
22
neoDependenciesRev='794280-1087'
33
strategy='EQUAL'
4-
allowedCD=272
4+
allowedCD=273

runtime/api/api.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3879,7 +3879,8 @@ cl_command_queue CL_API_CALL clCreateCommandQueueWithProperties(cl_context conte
38793879
if (tokenValue != CL_QUEUE_PROPERTIES &&
38803880
tokenValue != CL_QUEUE_SIZE &&
38813881
tokenValue != CL_QUEUE_PRIORITY_KHR &&
3882-
tokenValue != CL_QUEUE_THROTTLE_KHR) {
3882+
tokenValue != CL_QUEUE_THROTTLE_KHR &&
3883+
!processExtraTokens(pDevice, propertiesAddress)) {
38833884
err.set(CL_INVALID_VALUE);
38843885
return commandQueue;
38853886
}

runtime/helpers/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@ set(RUNTIME_SRCS_HELPERS_BASE
7575
${CMAKE_CURRENT_SOURCE_DIR}/properties_helper.h
7676
${CMAKE_CURRENT_SOURCE_DIR}/properties_helper.cpp
7777
${CMAKE_CURRENT_SOURCE_DIR}/ptr_math.h
78+
${CMAKE_CURRENT_SOURCE_DIR}${BRANCH_DIR_SUFFIX}/queue_helpers.cpp
7879
${CMAKE_CURRENT_SOURCE_DIR}/queue_helpers.h
7980
${CMAKE_CURRENT_SOURCE_DIR}/sampler_helpers.h
8081
${CMAKE_CURRENT_SOURCE_DIR}/selectors.h

runtime/helpers/queue_helpers.cpp

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
/*
2+
* Copyright (c) 2018, Intel Corporation
3+
*
4+
* Permission is hereby granted, free of charge, to any person obtaining a
5+
* copy of this software and associated documentation files (the "Software"),
6+
* to deal in the Software without restriction, including without limitation
7+
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
8+
* and/or sell copies of the Software, and to permit persons to whom the
9+
* Software is furnished to do so, subject to the following conditions:
10+
*
11+
* The above copyright notice and this permission notice shall be included
12+
* in all copies or substantial portions of the Software.
13+
*
14+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
15+
* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
17+
* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR
18+
* OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
19+
* ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
20+
* OTHER DEALINGS IN THE SOFTWARE.
21+
*/
22+
23+
#include "runtime/helpers/queue_helpers.h"
24+
25+
namespace OCLRT {
26+
bool processExtraTokens(Device *&device, const cl_queue_properties *property) {
27+
return false;
28+
}
29+
} // namespace OCLRT

runtime/helpers/queue_helpers.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,4 +117,5 @@ returnType getCmdQueueProperties(const cl_queue_properties *properties,
117117
}
118118
return retVal;
119119
}
120+
bool processExtraTokens(Device *&device, const cl_queue_properties *property);
120121
} // namespace OCLRT

0 commit comments

Comments
 (0)