2018-09-26 15:28:11 +02:00
|
|
|
/*
|
2022-11-23 09:14:27 +00:00
|
|
|
* Copyright (C) 2018-2022 Intel Corporation
|
2018-09-26 15:28:11 +02:00
|
|
|
*
|
|
|
|
|
* SPDX-License-Identifier: MIT
|
|
|
|
|
*
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
#pragma once
|
2020-10-16 12:10:52 +02:00
|
|
|
#include "shared/source/aub/aub_stream_provider.h"
|
|
|
|
|
#include "shared/source/aub/aub_subcapture.h"
|
2020-02-23 22:44:01 +01:00
|
|
|
#include "shared/source/helpers/options.h"
|
2020-10-14 19:22:01 +02:00
|
|
|
#include "shared/source/memory_manager/address_mapper.h"
|
|
|
|
|
#include "shared/source/memory_manager/physical_address_allocator.h"
|
2020-02-24 10:22:30 +01:00
|
|
|
|
2022-11-23 09:14:27 +00:00
|
|
|
#include "aubstream/aub_manager.h"
|
2018-10-30 18:29:32 +01:00
|
|
|
|
2019-03-26 11:59:46 +01:00
|
|
|
namespace NEO {
|
2022-11-25 07:58:15 +00:00
|
|
|
struct RootDeviceEnvironment;
|
2018-09-26 15:28:11 +02:00
|
|
|
|
|
|
|
|
class AubCenter {
|
|
|
|
|
public:
|
2022-11-25 07:58:15 +00:00
|
|
|
AubCenter(const RootDeviceEnvironment &rootDeviceEnvironment, bool localMemoryEnabled, const std::string &aubFileName, CommandStreamReceiverType csrType);
|
2019-02-05 14:16:37 +01:00
|
|
|
|
2018-12-10 17:12:32 +01:00
|
|
|
AubCenter();
|
2020-10-15 16:49:28 +02:00
|
|
|
virtual ~AubCenter() = default;
|
2018-09-26 15:28:11 +02:00
|
|
|
|
|
|
|
|
void initPhysicalAddressAllocator(PhysicalAddressAllocator *pPhysicalAddressAllocator) {
|
|
|
|
|
physicalAddressAllocator = std::unique_ptr<PhysicalAddressAllocator>(pPhysicalAddressAllocator);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
PhysicalAddressAllocator *getPhysicalAddressAllocator() const {
|
|
|
|
|
return physicalAddressAllocator.get();
|
|
|
|
|
}
|
|
|
|
|
|
2018-10-02 10:37:17 +02:00
|
|
|
AddressMapper *getAddressMapper() const {
|
|
|
|
|
return addressMapper.get();
|
|
|
|
|
}
|
|
|
|
|
|
2018-09-26 15:28:11 +02:00
|
|
|
AubStreamProvider *getStreamProvider() const {
|
|
|
|
|
return streamProvider.get();
|
|
|
|
|
}
|
|
|
|
|
|
2019-06-03 09:57:27 +02:00
|
|
|
AubSubCaptureCommon *getSubCaptureCommon() const {
|
|
|
|
|
return subCaptureCommon.get();
|
2019-02-19 22:50:52 +01:00
|
|
|
}
|
|
|
|
|
|
2019-01-18 21:44:23 +01:00
|
|
|
aub_stream::AubManager *getAubManager() const {
|
2018-11-26 18:17:57 -08:00
|
|
|
return aubManager.get();
|
|
|
|
|
}
|
|
|
|
|
|
2019-02-05 14:16:37 +01:00
|
|
|
static uint32_t getAubStreamMode(const std::string &aubFileName, uint32_t csrType);
|
|
|
|
|
|
2018-09-26 15:28:11 +02:00
|
|
|
protected:
|
|
|
|
|
std::unique_ptr<PhysicalAddressAllocator> physicalAddressAllocator;
|
2018-10-02 10:37:17 +02:00
|
|
|
std::unique_ptr<AddressMapper> addressMapper;
|
2018-09-26 15:28:11 +02:00
|
|
|
std::unique_ptr<AubStreamProvider> streamProvider;
|
2018-10-30 18:29:32 +01:00
|
|
|
|
2019-06-03 09:57:27 +02:00
|
|
|
std::unique_ptr<AubSubCaptureCommon> subCaptureCommon;
|
2019-01-18 21:44:23 +01:00
|
|
|
std::unique_ptr<aub_stream::AubManager> aubManager;
|
2019-02-08 15:08:35 +01:00
|
|
|
uint32_t aubStreamMode = 0;
|
2021-02-11 14:25:48 +00:00
|
|
|
uint32_t stepping = 0;
|
2018-09-26 15:28:11 +02:00
|
|
|
};
|
2019-03-26 11:59:46 +01:00
|
|
|
} // namespace NEO
|