2017-12-21 07:45:38 +08:00
|
|
|
/*
|
2021-05-17 02:51:16 +08:00
|
|
|
* Copyright (C) 2018-2021 Intel Corporation
|
2017-12-21 07:45:38 +08:00
|
|
|
*
|
2018-09-18 15:11:08 +08:00
|
|
|
* SPDX-License-Identifier: MIT
|
2017-12-21 07:45:38 +08:00
|
|
|
*
|
|
|
|
*/
|
2018-09-18 15:11:08 +08:00
|
|
|
|
2017-12-21 07:45:38 +08:00
|
|
|
#pragma once
|
2020-02-23 05:50:57 +08:00
|
|
|
#include "opencl/source/kernel/kernel.h"
|
|
|
|
#include "opencl/source/mem_obj/buffer.h"
|
2020-05-28 20:05:12 +08:00
|
|
|
#include "opencl/test/unit_test/fixtures/cl_device_fixture.h"
|
2020-02-23 22:20:22 +08:00
|
|
|
#include "opencl/test/unit_test/fixtures/context_fixture.h"
|
|
|
|
#include "opencl/test/unit_test/mocks/mock_buffer.h"
|
|
|
|
#include "opencl/test/unit_test/mocks/mock_context.h"
|
|
|
|
#include "opencl/test/unit_test/mocks/mock_kernel.h"
|
|
|
|
#include "opencl/test/unit_test/mocks/mock_program.h"
|
2019-02-27 18:39:32 +08:00
|
|
|
#include "test.h"
|
|
|
|
|
|
|
|
#include "CL/cl.h"
|
2017-12-21 07:45:38 +08:00
|
|
|
#include "gtest/gtest.h"
|
|
|
|
|
|
|
|
#include <memory>
|
|
|
|
|
2019-03-26 18:59:46 +08:00
|
|
|
using namespace NEO;
|
2017-12-21 07:45:38 +08:00
|
|
|
|
2020-05-28 20:05:12 +08:00
|
|
|
class KernelArgBufferFixture : public ContextFixture, public ClDeviceFixture {
|
2017-12-21 07:45:38 +08:00
|
|
|
|
|
|
|
using ContextFixture::SetUp;
|
|
|
|
|
|
|
|
public:
|
2018-03-29 06:38:41 +08:00
|
|
|
void SetUp();
|
2020-03-13 16:17:01 +08:00
|
|
|
void TearDown() override;
|
|
|
|
|
|
|
|
cl_int retVal = CL_SUCCESS;
|
|
|
|
MockProgram *pProgram = nullptr;
|
|
|
|
MockKernel *pKernel = nullptr;
|
2021-04-08 17:05:45 +08:00
|
|
|
std::unique_ptr<MockKernelInfo> pKernelInfo = nullptr;
|
2020-03-13 16:17:01 +08:00
|
|
|
char pSshLocal[64]{};
|
|
|
|
char pCrossThreadData[64]{};
|
2017-12-21 07:45:38 +08:00
|
|
|
};
|