Subject: smull

From: Nicolas Pitre <[email-masked]>
Date: Sat, 31 Jul 1999 18:15:41 -0400 (EDT)

I found this in egcs's backend for ARM:

(define_insn "mulsidi3"
  [(set (match_operand:DI 0 "s_register_operand" "=&r")
      (mult:DI (sign_extend:DI
                (match_operand:SI 1 "s_register_operand" "%r"))
               (sign_extend:DI
               (match_operand:SI 2 "s_register_operand" "r"))))]
  "arm_fast_multiply"
  "smull%?\\t%Q0, %R0, %1, %2"
[(set_attr "type" "mult")])

Any ideas how to trigger a smull from C code?

Nicolas Pitre, B. ing.
[email-masked]

unsubscribe: body of `unsubscribe linux-arm' to [email-masked]

---

From: Philip Blundell <[email-masked]>
Date: Sat, 31 Jul 1999 23:25:07 +0100

>Any ideas how to trigger a smull from C code?

Something like this:

long long foo(long a, long b)
{
  return (long long)a*(long long)b;
}

foo:
        @ args = 0, pretend = 0, frame = 0
        @ frame_needed = 0, current_function_anonymous_args = 0
        smull   r2, r3, r0, r1
        mov     r1, r3
        mov     r0, r2
        mov     pc, lr

p.