From f050d94f49dfe4e70deabb3ff9deb87b8f72c178 Mon Sep 17 00:00:00 2001 From: James Newling Date: Fri, 1 Nov 2024 14:57:26 -0700 Subject: [PATCH] retain header orders --- .../iree-amd-aie/aie_runtime/iree_aie_configure.cc | 5 ----- .../src/iree-amd-aie/aie_runtime/iree_aie_runtime.cc | 2 -- .../src/iree-amd-aie/aie_runtime/iree_aie_runtime.h | 11 ++++++++++- .../aie_runtime/test/test_control_packets.cc | 2 +- .../aie_runtime/test/test_packet_switch_mode.cc | 2 +- .../iree-amd-aie/aie_runtime/test/test_transaction.cc | 3 --- runtime/src/iree-amd-aie/aie_runtime/test/utest.cc | 1 - 7 files changed, 12 insertions(+), 14 deletions(-) diff --git a/runtime/src/iree-amd-aie/aie_runtime/iree_aie_configure.cc b/runtime/src/iree-amd-aie/aie_runtime/iree_aie_configure.cc index 71eb03741..cae09da23 100644 --- a/runtime/src/iree-amd-aie/aie_runtime/iree_aie_configure.cc +++ b/runtime/src/iree-amd-aie/aie_runtime/iree_aie_configure.cc @@ -20,11 +20,6 @@ using Path = std::filesystem::path; -extern "C" { -#include "xaie_hwcfg.h" -#include "xaiengine.h" -} - namespace mlir::iree_compiler::AMDAIE { FailureOr initDMADesc(const AMDAIEDeviceModel &deviceModel, diff --git a/runtime/src/iree-amd-aie/aie_runtime/iree_aie_runtime.cc b/runtime/src/iree-amd-aie/aie_runtime/iree_aie_runtime.cc index 996df1f8c..6ffc1b11a 100644 --- a/runtime/src/iree-amd-aie/aie_runtime/iree_aie_runtime.cc +++ b/runtime/src/iree-amd-aie/aie_runtime/iree_aie_runtime.cc @@ -14,7 +14,6 @@ extern "C" { #include "xaiengine.h" -#include "xaie_hwcfg.h" #undef s8 #undef u8 #undef u16 @@ -169,7 +168,6 @@ int AMDAIEDeviceModel::rows() const { return MLIRAIELegacy::rows(*this); assert(isNPUDevice(device) && "expected NPU device"); return devInst.NumRows; - } int AMDAIEDeviceModel::columns() const { diff --git a/runtime/src/iree-amd-aie/aie_runtime/iree_aie_runtime.h b/runtime/src/iree-amd-aie/aie_runtime/iree_aie_runtime.h index c1ab78200..b00c184e7 100644 --- a/runtime/src/iree-amd-aie/aie_runtime/iree_aie_runtime.h +++ b/runtime/src/iree-amd-aie/aie_runtime/iree_aie_runtime.h @@ -8,16 +8,25 @@ #define IREE_AIE_RUNTIME_H #include +#include +#include #include #include -#include "iree-amd-aie/aie_runtime/AMDAIEEnums.h" #include "llvm/ADT/Twine.h" #include "llvm/Support/Debug.h" +#include "llvm/Support/FormattedStream.h" #include "macros.h" +// clang-format off +#include "iree-amd-aie/aie_runtime/AMDAIEEnums.h" +// clang-format on + extern "C" { + +#include "xaie_hwcfg.h" #include "xaiengine.h" +#include "xaiengine/xaie_device_aieml.h" #undef s8 #undef u8 #undef u16 diff --git a/runtime/src/iree-amd-aie/aie_runtime/test/test_control_packets.cc b/runtime/src/iree-amd-aie/aie_runtime/test/test_control_packets.cc index afed69c3b..f9c204a1b 100644 --- a/runtime/src/iree-amd-aie/aie_runtime/test/test_control_packets.cc +++ b/runtime/src/iree-amd-aie/aie_runtime/test/test_control_packets.cc @@ -47,7 +47,7 @@ clang-format on #include #include "interpreter_op_impl.h" -#include "iree-amd-aie/aie_runtime/xaie_hwcfg.h" +#include "iree-amd-aie/aie_runtime/iree_aie_runtime.h" #define DATA_SIZE 17 #define WRRD_DATA_SIZE 0x02 diff --git a/runtime/src/iree-amd-aie/aie_runtime/test/test_packet_switch_mode.cc b/runtime/src/iree-amd-aie/aie_runtime/test/test_packet_switch_mode.cc index 039d6d1e1..75afaaa10 100644 --- a/runtime/src/iree-amd-aie/aie_runtime/test/test_packet_switch_mode.cc +++ b/runtime/src/iree-amd-aie/aie_runtime/test/test_packet_switch_mode.cc @@ -129,7 +129,7 @@ clang-format on #include #include "interpreter_op_impl.h" -#include "iree-amd-aie/aie_runtime/xaie_hwcfg.h" +#include "iree-amd-aie/aie_runtime/iree_aie_runtime.h" using namespace mlir::iree_compiler; using namespace mlir::iree_compiler::AMDAIE; diff --git a/runtime/src/iree-amd-aie/aie_runtime/test/test_transaction.cc b/runtime/src/iree-amd-aie/aie_runtime/test/test_transaction.cc index 1cbad20b0..7af4fc9be 100644 --- a/runtime/src/iree-amd-aie/aie_runtime/test/test_transaction.cc +++ b/runtime/src/iree-amd-aie/aie_runtime/test/test_transaction.cc @@ -46,9 +46,6 @@ clang-format on #include "interpreter_op_impl.h" #include "iree-amd-aie/aie_runtime/iree_aie_runtime.h" -#include "iree-amd-aie/aie_runtime/xaie_hwcfg.h" - - using namespace mlir::iree_compiler; using namespace mlir::iree_compiler::AMDAIE; diff --git a/runtime/src/iree-amd-aie/aie_runtime/test/utest.cc b/runtime/src/iree-amd-aie/aie_runtime/test/utest.cc index 540d7bbac..44a0e9427 100755 --- a/runtime/src/iree-amd-aie/aie_runtime/test/utest.cc +++ b/runtime/src/iree-amd-aie/aie_runtime/test/utest.cc @@ -230,7 +230,6 @@ clang-format off #include #include "iree-amd-aie/aie_runtime/iree_aie_runtime.h" -#include "iree-amd-aie/aie_runtime/xaie_hwcfg.h" int main(int argc, char** argv) { std::string elfPath(argv[1]);