Linear versus spline interpolation: same speed ?!

Hi guys,

I’m resampling about 1000 values and doing this in parallel for about another 1000 lines. One method I used is simple
texture interpolation ( I use a cudaArray, bind it to texture and then just read out at the points where I want the resampling
to be done). I do both linear and nearest neighbour interpolation by changing the cudaReadMode between Point en Linear.
I just implemented spline interpolation as well, based on an example in the SDK which calculates the 4 basic cubic b-spline coefficients
, 2 offset functions and 2 amplitude functions and does 4 tex2D readouts. I found the results a bit weird and was hoping you could help
me figure them out or tell me that I did something wrong (and preferable what I did wrong)

  1. The total processing time of the nearest neighbour and linear interpolations are exactly the same. Is this because the readouts from texture
    will take the same time?

  2. Even the total processing time for the spline method (which does a lot more calculations) is only 0.5% slower! Could this be right?
    Is this because binding the array to texture takes up most of the time or something?


It might just be a timing problem…

No it is not a timing issue, I checked and double checked.
Could it be that the binding of the cudaArray to the 2D texture takes up most of the time anyway so that the
4 versus 1 reads from texture memory don’t add up to this number?