From dfce56d6348328c79b56fe81a1280a05ca80950c Mon Sep 17 00:00:00 2001 From: Mateusz Hoppe Date: Wed, 4 Dec 2019 10:31:40 +0100 Subject: [PATCH] Cleanup headers in print_formatter and move to core Change-Id: I2ef5498927b02e0371dc4e484f94b00b4f86721c Signed-off-by: Mateusz Hoppe --- core/program/CMakeLists.txt | 13 +++++++++++++ {runtime => core}/program/print_formatter.cpp | 1 - {runtime => core}/program/print_formatter.h | 1 - runtime/core_files.cmake | 1 + runtime/program/CMakeLists.txt | 2 -- runtime/program/printf_handler.cpp | 2 +- unit_tests/program/printf_helper_tests.cpp | 2 +- 7 files changed, 16 insertions(+), 6 deletions(-) create mode 100644 core/program/CMakeLists.txt rename {runtime => core}/program/print_formatter.cpp (99%) rename {runtime => core}/program/print_formatter.h (99%) diff --git a/core/program/CMakeLists.txt b/core/program/CMakeLists.txt new file mode 100644 index 0000000000..2a102955b0 --- /dev/null +++ b/core/program/CMakeLists.txt @@ -0,0 +1,13 @@ +# +# Copyright (C) 2019 Intel Corporation +# +# SPDX-License-Identifier: MIT +# + +set(NEO_CORE_PROGRAM + ${CMAKE_CURRENT_SOURCE_DIR}/CMakeLists.txt + ${CMAKE_CURRENT_SOURCE_DIR}/print_formatter.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/print_formatter.h +) + +set_property(GLOBAL PROPERTY NEO_CORE_PROGRAM ${NEO_CORE_PROGRAM}) diff --git a/runtime/program/print_formatter.cpp b/core/program/print_formatter.cpp similarity index 99% rename from runtime/program/print_formatter.cpp rename to core/program/print_formatter.cpp index a801e23ad0..ddccbb44e0 100644 --- a/runtime/program/print_formatter.cpp +++ b/core/program/print_formatter.cpp @@ -8,7 +8,6 @@ #include "print_formatter.h" #include "core/helpers/string.h" -#include "core/memory_manager/graphics_allocation.h" #include diff --git a/runtime/program/print_formatter.h b/core/program/print_formatter.h similarity index 99% rename from runtime/program/print_formatter.h rename to core/program/print_formatter.h index ea4a928ff9..f1a17f098e 100644 --- a/runtime/program/print_formatter.h +++ b/core/program/print_formatter.h @@ -9,7 +9,6 @@ #include "core/helpers/aligned_memory.h" #include "core/os_interface/print.h" -#include "runtime/kernel/kernel.h" #include #include diff --git a/runtime/core_files.cmake b/runtime/core_files.cmake index 03ad0a738a..3cc1bd35e5 100644 --- a/runtime/core_files.cmake +++ b/runtime/core_files.cmake @@ -17,6 +17,7 @@ append_sources_from_properties(NEO_CORE_SOURCES NEO_CORE_MEMORY_MANAGER NEO_CORE_OS_INTERFACE NEO_CORE_PAGE_FAULT_MANAGER + NEO_CORE_PROGRAM NEO_CORE_SKU_INFO_BASE NEO_CORE_UTILITIES NEO_UNIFIED_MEMORY diff --git a/runtime/program/CMakeLists.txt b/runtime/program/CMakeLists.txt index 81323f7b46..ed0ec043dc 100644 --- a/runtime/program/CMakeLists.txt +++ b/runtime/program/CMakeLists.txt @@ -23,8 +23,6 @@ set(RUNTIME_SRCS_PROGRAM ${CMAKE_CURRENT_SOURCE_DIR}/kernel_info_from_patchtokens.h ${CMAKE_CURRENT_SOURCE_DIR}/link.cpp ${CMAKE_CURRENT_SOURCE_DIR}/patch_info.h - ${CMAKE_CURRENT_SOURCE_DIR}/print_formatter.cpp - ${CMAKE_CURRENT_SOURCE_DIR}/print_formatter.h ${CMAKE_CURRENT_SOURCE_DIR}/printf_handler.cpp ${CMAKE_CURRENT_SOURCE_DIR}/printf_handler.h ${CMAKE_CURRENT_SOURCE_DIR}/process_elf_binary.cpp diff --git a/runtime/program/printf_handler.cpp b/runtime/program/printf_handler.cpp index be3d20223b..e8677117f4 100644 --- a/runtime/program/printf_handler.cpp +++ b/runtime/program/printf_handler.cpp @@ -9,12 +9,12 @@ #include "core/helpers/aligned_memory.h" #include "core/helpers/ptr_math.h" +#include "core/program/print_formatter.h" #include "runtime/device/device.h" #include "runtime/helpers/dispatch_info.h" #include "runtime/kernel/kernel.h" #include "runtime/mem_obj/buffer.h" #include "runtime/memory_manager/memory_manager.h" -#include "runtime/program/print_formatter.h" namespace NEO { diff --git a/unit_tests/program/printf_helper_tests.cpp b/unit_tests/program/printf_helper_tests.cpp index 7314ca6e80..2ecf615646 100644 --- a/unit_tests/program/printf_helper_tests.cpp +++ b/unit_tests/program/printf_helper_tests.cpp @@ -7,7 +7,7 @@ #include "core/helpers/aligned_memory.h" #include "core/helpers/string.h" -#include "runtime/program/print_formatter.h" +#include "core/program/print_formatter.h" #include "unit_tests/mocks/mock_device.h" #include "unit_tests/mocks/mock_graphics_allocation.h" #include "unit_tests/mocks/mock_kernel.h"