www.delorie.com/gnu/docs/gmp/gmp_118.html   search  
 
Buy GNU books!


GNU MP 4.1.2

[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

16.8 Assembler Coding

The assembler subroutines in GMP are the most significant source of speed at small to moderate sizes. At larger sizes algorithm selection becomes more important, but of course speedups in low level routines will still speed up everything proportionally.

Carry handling and widening multiplies that are important for GMP can't be easily expressed in C. GCC asm blocks help a lot and are provided in `longlong.h', but hand coding low level routines invariably offers a speedup over generic C by a factor of anything from 2 to 10.

16.8.1 Code Organisation  
16.8.2 Assembler Basics  
16.8.3 Carry Propagation  
16.8.4 Cache Handling  
16.8.5 Floating Point  
16.8.6 SIMD Instructions  
16.8.7 Software Pipelining  
16.8.8 Loop Unrolling  


  webmaster   donations   bookstore     delorie software   privacy  
  Copyright © 2003   by The Free Software Foundation     Updated Jun 2003