2018-09-05 16:10:26 +08:00
|
|
|
/*
|
2021-05-21 21:32:24 +08:00
|
|
|
* Copyright (C) 2018-2021 Intel Corporation
|
2018-09-05 16:10:26 +08:00
|
|
|
*
|
2018-09-17 20:03:37 +08:00
|
|
|
* SPDX-License-Identifier: MIT
|
2018-09-05 16:10:26 +08:00
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
2021-05-21 21:32:24 +08:00
|
|
|
#include "opencl/source/context/context.h"
|
2020-02-23 05:50:57 +08:00
|
|
|
#include "opencl/source/mem_obj/mem_obj_helper_common.inl"
|
|
|
|
|
2019-08-09 18:20:05 +08:00
|
|
|
#include "memory_properties_flags.h"
|
|
|
|
|
2019-03-26 18:59:46 +08:00
|
|
|
namespace NEO {
|
2018-09-05 16:10:26 +08:00
|
|
|
|
2020-04-22 20:37:30 +08:00
|
|
|
bool MemObjHelper::isSuitableForRenderCompression(bool renderCompressed, const MemoryProperties &properties, Context &context, bool preferCompression) {
|
2021-05-21 21:32:24 +08:00
|
|
|
if (context.getRootDeviceIndices().size() > 1u) {
|
|
|
|
return false;
|
|
|
|
}
|
2019-09-19 01:32:33 +08:00
|
|
|
return renderCompressed && preferCompression;
|
2019-01-28 22:27:15 +08:00
|
|
|
}
|
|
|
|
|
2020-04-22 20:37:30 +08:00
|
|
|
bool MemObjHelper::validateExtraMemoryProperties(const MemoryProperties &memoryProperties, cl_mem_flags flags, cl_mem_flags_intel flagsIntel, const Context &context) {
|
2019-01-09 19:56:38 +08:00
|
|
|
return true;
|
|
|
|
}
|
|
|
|
|
2019-08-29 14:59:15 +08:00
|
|
|
const uint64_t MemObjHelper::extraFlags = 0;
|
|
|
|
|
|
|
|
const uint64_t MemObjHelper::extraFlagsIntel = 0;
|
2019-01-09 19:56:38 +08:00
|
|
|
|
2019-03-26 18:59:46 +08:00
|
|
|
} // namespace NEO
|