cpu: Add a StaticInst::advancePC which takes a ThreadContext.

This will avoid having to create a new heap allocated PCState, since the
instruction will know what type of backing storage to allocate on the
stack for the working copy.

Change-Id: Id208e015f6cb764bf7b13e0faf1677278b7e4641
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/52069
Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
Maintainer: Gabe Black <gabe.black@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
4 files changed