You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi,
I'm trying to run openmp application on zsim.
I tried a very simple program, accumulating an array and it works well on the host. But, when simulating, it may deadlock (
occasionally complete). I test it on different ubuntu system with the same config file and face the same problem.
[Config file]
4 simple cores
[Test system 1]
Ubuntu 14.04 (4.4.0 kernel) / Pin-2.14-71293
gcc: 4.8.5
[Test system 2]
Ubuntu 20.04 (6.2.0 kernel) / Pin-2.14-71293
gcc: 9.4.0
[Test system 3]
Ubuntu 22.04 (6.5.0 kernel) / Pin-2.14-71293)
gcc: 11.4.0
[test.cpp]
int main() {
const int size = 100;
int arr[size];
int sum = 0;
// Initialize the array
for (int i = 0; i < size; i++) {
arr[i] = i + 1;
}
#pragma omp parallel for reduction(+:sum)
for (int i = 0; i < size; i++) {
sum += arr[i];
}
std::cout << "Sum: " << sum << std::endl;
return 0;
}
[S 0] Started process, PID 3909
[S 0] procMask: 0x0
[H] Attached to global heap
[S 0] vDSO info initialized
[S 0] Started contention simulation thread 0
[S 0] Started scheduler watchdog thread
[S 0] Thread 0 starting
[S 0] FF control Thread TID 3920
[S 0] [0] Post-patching SYS_sched_getaffinity size 8 cpuset 0x5555555592a0
[S 0] Thread 4 starting
[S 0] Thread 5 starting
[S 0] Thread 6 starting
Sum: 5050
[S 0] Thread 0 finished
[H] WARN: Stalled for 20 secs so far
[H] WARN: Stalled for 30 secs so far
[H] WARN: Stalled for 40 secs so far
[H] WARN: Stalled for 50 secs so far
[H] WARN: Stalled for 60 secs so far
[H] WARN: Stalled for 70 secs so far
[H] WARN: Stalled for 80 secs so far
[H] WARN: Stalled for 90 secs so far
[H] WARN: Stalled for 100 secs so far
[H] WARN: Stalled for 110 secs so far
[H] WARN: Stalled for 120 secs so far
[H] WARN: Stalled for 130 secs so far
[H] WARN: Deadlock detected, killing children
[H] Received interrupt
[H] Attempting graceful termination
[H] Killing process 5141
[H] Done sending kill signals
[H] WARN: Hard death at exit (1 children running), killing the whole process tree
Killed
Does anyone saw this kind of problem?
Any comments or suggestion will be helpful.
Thanks,
Xuanyi
The text was updated successfully, but these errors were encountered:
Hi,
I'm trying to run openmp application on zsim.
I tried a very simple program, accumulating an array and it works well on the host. But, when simulating, it may deadlock (
occasionally complete). I test it on different ubuntu system with the same config file and face the same problem.
[Config file]
4 simple cores
[Test system 1]
Ubuntu 14.04 (4.4.0 kernel) / Pin-2.14-71293
gcc: 4.8.5
[Test system 2]
Ubuntu 20.04 (6.2.0 kernel) / Pin-2.14-71293
gcc: 9.4.0
[Test system 3]
Ubuntu 22.04 (6.5.0 kernel) / Pin-2.14-71293)
gcc: 11.4.0
[test.cpp]
[4simple.cfg]
[Message]
Does anyone saw this kind of problem?
Any comments or suggestion will be helpful.
Thanks,
Xuanyi
The text was updated successfully, but these errors were encountered: