diff --git a/cranelift/codegen/src/isa/aarch64/lower.isle b/cranelift/codegen/src/isa/aarch64/lower.isle index 67d07f9388..aa90a3546e 100644 --- a/cranelift/codegen/src/isa/aarch64/lower.isle +++ b/cranelift/codegen/src/isa/aarch64/lower.isle @@ -26,48 +26,48 @@ ;; `i64` and smaller -;; base case, simply adding things in registers +;; Base case, simply adding things in registers. (rule (lower (has_type (fits_in_64 ty) (iadd x y))) (value_reg (alu_rrr (iadd_op ty) (put_in_reg x) (put_in_reg y)))) -;; special case for when one operand is an immediate that fits in 12 bits +;; Special case for when one operand is an immediate that fits in 12 bits. (rule (lower (has_type (fits_in_64 ty) (iadd x (imm12_from_value y)))) (value_reg (alu_rr_imm12 (iadd_op ty) (put_in_reg x) y))) -;; same as the previous special case, except we can switch the addition to a +;; Same as the previous special case, except we can switch the addition to a ;; subtraction if the negated immediate fits in 12 bits. (rule (lower (has_type (fits_in_64 ty) (iadd x (imm12_from_negated_value y)))) (value_reg (alu_rr_imm12 (isub_op ty) (put_in_reg x) y))) -;; special case for when we're adding an extended register where the extending +;; Special case for when we're adding an extended register where the extending ;; operation can get folded into the add itself. (rule (lower (has_type (fits_in_64 ty) (iadd x (extended_value_from_value y)))) (value_reg (alu_rr_extend_reg (iadd_op ty) (put_in_reg x) y))) -;; special case for when we're adding the shift of a different +;; Special case for when we're adding the shift of a different ;; register by a constant amount and the shift can get folded into the add. (rule (lower (has_type (fits_in_64 ty) (iadd x (def_inst (ishl y (def_inst (iconst (lshl_from_imm64