machinst x64: use a sign-extension when loading jump table offsets;

The jump table offset that's loaded out of the jump table could be
signed (if it's an offset to before the jump table itself), so we should
use a signed extension there, not an unsigned extension.
This commit is contained in:
Benjamin Bouvier
2020-07-28 11:07:16 +02:00
parent 8fd92093a4
commit 7f109a5198
3 changed files with 12 additions and 5 deletions

View File

@@ -350,6 +350,7 @@ pub enum Inst {
/// Jump-table sequence, as one compound instruction (see note in lower.rs for rationale).
/// The generated code sequence is described in the emit's function match arm for this
/// instruction.
/// See comment in lowering about the temporaries signedness.
JmpTableSeq {
idx: Reg,
tmp1: Writable<Reg>,