fix: Add asserts to ensure NonCopyable and NonMovable 3/n

Related-To: NEO-14068

Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
This commit is contained in:
Filip Hazubski
2025-02-18 14:35:36 +00:00
committed by Compute-Runtime-Automation
parent ff9d0d7ea0
commit 6b6202446b
33 changed files with 191 additions and 164 deletions

View File

@@ -1,11 +1,12 @@
/*
* Copyright (C) 2020-2024 Intel Corporation
* Copyright (C) 2020-2025 Intel Corporation
*
* SPDX-License-Identifier: MIT
*
*/
#pragma once
#include "shared/source/helpers/non_copyable_or_moveable.h"
#include "shared/source/utilities/arrayref.h"
#include <cstddef>
@@ -20,12 +21,10 @@ struct ExternalFunctionInfo;
struct LinkerInput;
struct KernelInfo;
struct ProgramInfo {
struct ProgramInfo : NEO::NonCopyableClass {
ProgramInfo() = default;
ProgramInfo(ProgramInfo &&) = default;
ProgramInfo &operator=(ProgramInfo &&) = default;
ProgramInfo(const ProgramInfo &) = delete;
ProgramInfo &operator=(const ProgramInfo &) = delete;
~ProgramInfo();
struct GlobalSurfaceInfo {
@@ -50,6 +49,8 @@ struct ProgramInfo {
size_t kernelMiscInfoPos = std::string::npos;
};
static_assert(NEO::NonCopyable<ProgramInfo>);
size_t getMaxInlineSlmNeeded(const ProgramInfo &programInfo);
bool requiresLocalMemoryWindowVA(const ProgramInfo &programInfo);
bool isRebuiltToPatchtokensRequired(Device *neoDevice, ArrayRef<const uint8_t> archive, std::string &optionsString, bool isBuiltin, bool isVmeUsed);