File tree 2 files changed +7
-6
lines changed
src/plugins/intel_npu/src/compiler_adapter
2 files changed +7
-6
lines changed Original file line number Diff line number Diff line change 5
5
6
6
#pragma once
7
7
8
+ #include < cstdint>
9
+
8
10
namespace intel_npu {
9
11
int64_t get_peak_memory_usage ();
10
12
}
Original file line number Diff line number Diff line change 2
2
3
3
#include " mem_usage.hpp"
4
4
5
- namespace intel_npu {
6
-
7
5
#if defined _WIN32
8
6
9
7
#include < windows.h>
10
8
#include < psapi.h>
9
+ #include < cmath>
10
+ #include < stdexcept>
11
11
12
- int64_t get_peak_memory_usage () {
12
+ int64_t intel_npu:: get_peak_memory_usage () {
13
13
PROCESS_MEMORY_COUNTERS mem_counters;
14
14
if (!GetProcessMemoryInfo (GetCurrentProcess (), &mem_counters, sizeof (mem_counters))) {
15
15
throw std::runtime_error (" Can't get system memory values" );
@@ -35,8 +35,8 @@ int64_t get_peak_memory_usage() {
35
35
#include < regex>
36
36
#include < sstream>
37
37
38
- int64_t get_peak_memory_usage () {
39
- size_t peak_mem_usage_kB = 0 ;
38
+ int64_t intel_npu:: get_peak_memory_usage () {
39
+ std:: size_t peak_mem_usage_kB = 0 ;
40
40
41
41
std::ifstream status_file (" /proc/self/status" );
42
42
std::string line;
@@ -61,4 +61,3 @@ int64_t get_peak_memory_usage() {
61
61
}
62
62
63
63
#endif
64
- }
You can’t perform that action at this time.
0 commit comments