SlugLab / CXLMemSim

A place to store the CXL simulator
123 stars 20 forks source link

Abort when simulate the microbench/malloc #7

Closed wiketool closed 4 months ago

wiketool commented 7 months ago
(base) ren@ren:~/Desktop/CXLMemSim$ sudo LOGV=1 ./CXLMemSim -t ./microbench/malloc
/home/ren/Desktop/CXLMemSim/src/main.cc:126 int main(int, char**) (CXLSwitch 1 (CXLMemExpander 1,CXLMemExpander 2))(CXLMemExpander 0)
argv[0] = ./microbench/malloc
allocating 1000 MB
allocated - press enter to fill/read
filling
 /home/ren/Desktop/CXLMemSim/src/monitor.cpp:96 int Monitors::enable(uint32_t, uint32_t, bool, uint64_t, int32_t) pid 0[tgid=31569, tid=31569] monitoring start
 /home/ren/Desktop/CXLMemSim/src/helper.cpp:65 PerfConfig Helper::detect_model(uint32_t, const std::vector<std::__cxx11::basic_string<char> >&, const std::vector<long unsigned int>&, const std::vector<long unsigned int>&) Detecting model...151
terminate called after throwing an instance of 'std::runtime_error'
  what():  open
Aborted
wiketool commented 7 months ago

I found the problem. But I dont know how to solve it

openat(AT_FDCWD, "/sys/bus/event_source/devices/uncore_cbo_0/type", O_RDONLY) = -1 ENOENT (No such file or directory)
futex(0x7fb255732210, FUTEX_WAKE_PRIVATE, 2147483647) = 0
write(2, "terminate called after throwing "..., 48terminate called after throwing an instance of ') = 48
write(2, "std::runtime_error", 18std::runtime_error)      = 18
write(2, "'\n", 2'
)                      = 2
write(2, "  what():  ", 11  what():  )             = 11
write(2, "open", 4open)                     = 4
write(2, "\n", 1
)                       = 1

I just found uncore_cbox_0 in /sys/bus/event_source/devices/

victoryang00 commented 5 months ago

What CPU are you running on, and do your CPU support perf?