This is the mail archive of the crossgcc@sources.redhat.com mailing list for the crossgcc project.
See the CrossGCC FAQ for lots more information.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
[code] inline int fixp_mul_32s_n16( int a, int b ) { int res, tmp; __asm__ __volatile__ ( "smull %0, %1, %2, %3 \n\t" "movs %0, %0, lsr #16 \n\t" "adc %1, %0, %1, lsl #(32-16) \n\t" : "=&r" (res), "=&r" (tmp) : "r" (a), "r" (b) ); return res; } [/code]
[code] inline int fixp_mul_32s_nX( int a, int b, char n ) { int res, tmp; __asm__ __volatile__ ( "smull %0, %1, %2, %3 \n\t" "movs %0, %0, lsr #%4 \n\t" "adc %1, %0, %1, lsl #(32-%4) \n\t" : "=&r" (res), "=&r" (tmp) : "r" (a), "r" (b), "M" (n) ); return res; } [/code]
Thanks in advance for your help, - Bryce Schober
--- [This E-mail scanned for viruses by digiposs.com]
------ Want more information? See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/ Want to unsubscribe? Send a note to crossgcc-unsubscribe@sources.redhat.com
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |