sim-se: factor out FutexMap::suspend and FutexMap::suspend_bitset
authorCiro Santilli <ciro.santilli@arm.com>
Thu, 19 Dec 2019 19:04:32 +0000 (19:04 +0000)
committerCiro Santilli <ciro.santilli@arm.com>
Mon, 10 Aug 2020 08:52:03 +0000 (08:52 +0000)
commit9c9fea575a32578a1f2ea26fad279459f9ced1f3
tree7cd8b715d6bedf90a3bc042e2a8a7508cda73d26
parentaa219dba7ab74072b9658c8774382f58c707cde4
sim-se: factor out FutexMap::suspend and FutexMap::suspend_bitset

Both methods do basically the same, especially since they don't handle the
timeout which is basically the only difference between both modes of the
syscall (one uses absolute and the other relative time).

Remove the WaiterState::WaiterState(ThreadContext* _tc) constructor,
since the only calls were from FutexMap::suspend which does not use them
anymore. Instead, set the magic 0xffffffff constant as a parameter to
suspend_bitset.

Change-Id: I69d86bad31d63604657a3c71cf07e5623f0ea639
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/29776
Reviewed-by: Brandon Potter <Brandon.Potter@amd.com>
Maintainer: Brandon Potter <Brandon.Potter@amd.com>
Tested-by: kokoro <noreply+kokoro@google.com>
src/sim/futex_map.cc
src/sim/futex_map.hh