2021-07-02 14:41:38 -07:00
|
|
|
/* Copyright (c) 2008 - 2021 Advanced Micro Devices, Inc.
|
2020-02-04 09:26:14 -08:00
|
|
|
|
|
|
|
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
|
|
|
of this software and associated documentation files (the "Software"), to deal
|
|
|
|
|
in the Software without restriction, including without limitation the rights
|
|
|
|
|
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
|
|
|
copies of the Software, and to permit persons to whom the Software is
|
|
|
|
|
furnished to do so, subject to the following conditions:
|
|
|
|
|
|
|
|
|
|
The above copyright notice and this permission notice shall be included in
|
|
|
|
|
all copies or substantial portions of the Software.
|
|
|
|
|
|
|
|
|
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
|
|
|
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
|
|
|
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
|
|
|
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
|
|
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
|
|
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
|
|
|
THE SOFTWARE. */
|
|
|
|
|
|
2016-07-21 12:41:26 -04:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
#ifndef WITHOUT_HSA_BACKEND
|
|
|
|
|
|
|
|
|
|
namespace roc {
|
|
|
|
|
|
2021-01-10 00:07:13 +00:00
|
|
|
//! Alignment restriction for the pinned memory
|
2020-07-14 20:10:24 -04:00
|
|
|
static constexpr size_t PinnedMemoryAlignment = 4 * Ki;
|
2017-01-23 11:59:51 -05:00
|
|
|
|
2018-06-12 16:17:29 -04:00
|
|
|
//! Specific defines for images for Dynamic Parallelism
|
2020-07-14 20:10:24 -04:00
|
|
|
static constexpr uint DeviceQueueMaskSize = 32;
|
2018-06-12 16:17:29 -04:00
|
|
|
|
2021-01-10 01:21:59 +00:00
|
|
|
//! Set to match the number of pipes, which is 8.
|
|
|
|
|
static constexpr uint kMaxAsyncQueues = 8;
|
|
|
|
|
|
2021-01-22 16:42:35 -05:00
|
|
|
constexpr bool kSkipCpuWait = true;
|
|
|
|
|
|
2021-01-19 18:06:08 -05:00
|
|
|
enum HwQueueEngine : uint32_t {
|
|
|
|
|
Compute = 0,
|
|
|
|
|
SdmaRead = 1,
|
|
|
|
|
SdmaWrite = 2,
|
2021-01-22 16:42:35 -05:00
|
|
|
Unknown = 3,
|
|
|
|
|
External = 4
|
2021-01-19 18:06:08 -05:00
|
|
|
};
|
|
|
|
|
|
2021-01-10 00:07:13 +00:00
|
|
|
} // namespace roc
|
2017-10-04 16:45:05 -04:00
|
|
|
|
2016-07-21 12:41:26 -04:00
|
|
|
#endif
|