systemc: avoid mutex lock in non async cases
authorEarl Ou <shunhsingou@google.com>
Thu, 17 Sep 2020 06:31:44 +0000 (14:31 +0800)
committerEarl Ou <shunhsingou@google.com>
Wed, 23 Sep 2020 04:05:03 +0000 (04:05 +0000)
commitb86461ce94f7e6cab8dc00393a30624dbf778b54
tree94e08f22c25600dd226a075b194a503d1e737e53
parent2035ebfbba599c520645b505241508f78b9b0636
systemc: avoid mutex lock in non async cases

Avoid acquiring a mutex lock in case there is no async update in the
scheduler. This helps increasing simulation speed by about 4%.

Change-Id: I971c7bf1a1eeb46208eeee6e5da6385c907092b3
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34695
Reviewed-by: Earl Ou <shunhsingou@google.com>
Maintainer: Earl Ou <shunhsingou@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
src/systemc/core/scheduler.cc
src/systemc/core/scheduler.hh