One thing to try, that program looks like it needs --num-cpus=5 as it spawns 4 threads (so main + 4 total). ________________________________ From: Bobby Bruce via gem5-users <gem5-users@gem5.org> Sent: Thursday, October 15, 2020 10:13 PM To: gem5 users mailing list <gem5-users@gem5.org> Cc: Farhad Yusufali <farhad.yusuf...@mail.utoronto.ca>; Bobby Bruce <bbr...@ucdavis.edu> Subject: [gem5-users] Re: SE Mode crashing with multithread workload
Hey Farhad, I've added a Jira ticket about this bug: https://gem5.atlassian.net/browse/GEM5-798. I'm afraid to say we don't have a solution right now, but we suspect it may be similar to this bug: https://gem5.atlassian.net/browse/GEM5-332. You can see the comments on this bug for more information. Now that it's on Jira, and a known bug in gem5, we hope we can get to the bottom of this and fix it in a future release. Keep track of the Jira ticket for progress on this issue. We are sorry for the inconvenience this is causing you, but as far as I know, no one has a solution at this point in time. Kind regards, Bobby -- Dr. Bobby R. Bruce Room 2235, Kemper Hall, UC Davis Davis, CA, 95616 web: https://www.bobbybruce.net On Thu, Oct 15, 2020 at 8:00 AM Farhad Yusufali via gem5-users <gem5-users@gem5.org<mailto:gem5-users@gem5.org>> wrote: Hi all, Just following up on this. Any help would be appreciated! Thanks, Farhad ________________________________ From: Farhad Yusufali Sent: October 13, 2020 9:37 PM To: gem5-users@gem5.org<mailto:gem5-users@gem5.org> <gem5-users@gem5.org<mailto:gem5-users@gem5.org>> Subject: SE Mode crashing with multithread workload Hi all, My gem5 version is fa70478413e4650d0058cbfe81fd5ce362101994. I'm trying to run a multithreaded workload in SE mode, but it's crashing. Here is my very simple workload: #include <pthread.h> #include <iostream> using namespace std; int sum[4]; void* thread(void* sum) { for (int i = 0; i < 1000; i++) *((int*)sum) += i; return 0; } int main() { sum[0] = sum[1] = sum[2] = sum[3] = 0; pthread_t threads[4]; for (int tid = 0; tid < 4; tid++) pthread_create(&threads[tid], NULL, thread, &sum[tid]); for (int tid = 0; tid < 4; tid++) pthread_join(threads[tid], NULL); cout << sum [0] << " " << sum[1] << " " << sum[2] << " " << sum[3] << endl; return 0; } When I run it with: build/X86/gem5.opt --debug-flags=PseudoInst configs/example/se.py --cmd=./multi --num-cpus=4 --ruby --cpu-type=DerivO3CPU I get: panic: panic condition !clobber occurred: EmulationPageTable::allocate: addr 0x7ffff778d000 already mapped I found an existing thread that discusses this but no update was posted: https://www.mail-archive.com/gem5-users@gem5.org/msg17926.html Was this ever resolved? Thanks, Farhad _______________________________________________ gem5-users mailing list -- gem5-users@gem5.org<mailto:gem5-users@gem5.org> To unsubscribe send an email to gem5-users-le...@gem5.org<mailto:gem5-users-le...@gem5.org> %(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s
_______________________________________________ gem5-users mailing list -- gem5-users@gem5.org To unsubscribe send an email to gem5-users-le...@gem5.org %(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s