Re: [PATCH 02/13] target/riscv: Extend pc for runtime pc write

2021-11-02 Thread Richard Henderson
On 11/1/21 9:48 PM, LIU Zhiwei wrote: On 2021/11/1 下午6:33, Richard Henderson wrote: On 11/1/21 6:01 AM, LIU Zhiwei wrote: In some cases, we must restore the guest PC to the address of the start of the TB, such as when the instruction counter hit zero. So extend pc register according to current

Re: [PATCH 02/13] target/riscv: Extend pc for runtime pc write

2021-11-01 Thread LIU Zhiwei
On 2021/11/1 下午6:33, Richard Henderson wrote: On 11/1/21 6:01 AM, LIU Zhiwei wrote: In some cases, we must restore the guest PC to the address of the start of the TB, such as when the instruction counter hit zero. So extend pc register according to current xlen for these cases. Signed-off-b

Re: [PATCH 02/13] target/riscv: Extend pc for runtime pc write

2021-11-01 Thread Richard Henderson
On 11/1/21 6:01 AM, LIU Zhiwei wrote: In some cases, we must restore the guest PC to the address of the start of the TB, such as when the instruction counter hit zero. So extend pc register according to current xlen for these cases. Signed-off-by: LIU Zhiwei --- target/riscv/cpu.c| 20

[PATCH 02/13] target/riscv: Extend pc for runtime pc write

2021-11-01 Thread LIU Zhiwei
In some cases, we must restore the guest PC to the address of the start of the TB, such as when the instruction counter hit zero. So extend pc register according to current xlen for these cases. Signed-off-by: LIU Zhiwei --- target/riscv/cpu.c| 20 +--- target/riscv/cpu.h