From math view point these things matter most:
number of parameters
type of parameters (like integer or continous)
goal function characteristics (smooth, having steps, having multiple minima or only one, sum of squares, etc.)
In many benchmarks BFGS is amoung the best - if problem is smooth. Source code is available in Numerical Recipes in Pascal (or C).