How to speed up programs by compiling



It would be helpful if you showed what the calls to the built-in 
integrate  program look like.

If they are truly polynomials, perhaps you are doing thousands of 
calls?   Or perhaps you
have coefficients which are thousands of digits long?   If the latter, 
then what you need
is not faster integration, but faster arithmetic on bignums!