Port Fcopysign..FcvtToSintSat to ISLE (AArch64) (#4753)
* Port `Fcopysign`..``FcvtToSintSat` to ISLE (AArch64)
Ported the existing implementations of the following opcodes to ISLE on
AArch64:
- `Fcopysign`
- Also introduced missing support for `fcopysign` on vector values, as
per the docs.
- This introduces the vector encoding for the `SLI` machine
instruction.
- `FcvtToUint`
- `FcvtToSint`
- `FcvtFromUint`
- `FcvtFromSint`
- `FcvtToUintSat`
- `FcvtToSintSat`
Copyright (c) 2022 Arm Limited
* Document helpers and abstract conversion checks
This commit is contained in:
@@ -39,7 +39,7 @@ pub use crate::isa::aarch64::lower::isle::generated_code::{
|
||||
ALUOp, ALUOp3, APIKey, AtomicRMWLoopOp, AtomicRMWOp, BitOp, FPUOp1, FPUOp2, FPUOp3,
|
||||
FpuRoundMode, FpuToIntOp, IntToFpuOp, MInst as Inst, MoveWideOp, VecALUModOp, VecALUOp,
|
||||
VecExtendOp, VecLanesOp, VecMisc2, VecPairOp, VecRRLongOp, VecRRNarrowOp, VecRRPairLongOp,
|
||||
VecRRRLongOp, VecShiftImmOp,
|
||||
VecRRRLongOp, VecShiftImmModOp, VecShiftImmOp,
|
||||
};
|
||||
|
||||
/// A floating-point unit (FPU) operation with two args, a register and an immediate.
|
||||
@@ -767,6 +767,10 @@ fn aarch64_get_operands<F: Fn(VReg) -> VReg>(inst: &Inst, collector: &mut Operan
|
||||
collector.reg_def(rd);
|
||||
collector.reg_use(rn);
|
||||
}
|
||||
&Inst::VecShiftImmMod { rd, rn, .. } => {
|
||||
collector.reg_mod(rd);
|
||||
collector.reg_use(rn);
|
||||
}
|
||||
&Inst::VecExtract { rd, rn, rm, .. } => {
|
||||
collector.reg_def(rd);
|
||||
collector.reg_use(rn);
|
||||
@@ -2371,6 +2375,20 @@ impl Inst {
|
||||
let rn = pretty_print_vreg_vector(rn, size, allocs);
|
||||
format!("{} {}, {}, #{}", op, rd, rn, imm)
|
||||
}
|
||||
&Inst::VecShiftImmMod {
|
||||
op,
|
||||
rd,
|
||||
rn,
|
||||
size,
|
||||
imm,
|
||||
} => {
|
||||
let op = match op {
|
||||
VecShiftImmModOp::Sli => "sli",
|
||||
};
|
||||
let rd = pretty_print_vreg_vector(rd.to_reg(), size, allocs);
|
||||
let rn = pretty_print_vreg_vector(rn, size, allocs);
|
||||
format!("{} {}, {}, #{}", op, rd, rn, imm)
|
||||
}
|
||||
&Inst::VecExtract { rd, rn, rm, imm4 } => {
|
||||
let rd = pretty_print_vreg_vector(rd.to_reg(), VectorSize::Size8x16, allocs);
|
||||
let rn = pretty_print_vreg_vector(rn, VectorSize::Size8x16, allocs);
|
||||
|
||||
Reference in New Issue
Block a user