 
     dim3 dimGrid (padded / TARGET_BLOCK_SIZE, 1 );
     dim3 dimBlock(TARGET_BLOCK_SIZE, 1);
+    int* result_flag = (int*)malloc(padded * sizeof(int));
 
 // flag for ignition
 #ifdef IGN

            cudaErrorCheck( cudaPeekAtLastError() );
            cudaErrorCheck( cudaDeviceSynchronize() );
    #endif
            // transfer memory back to CPU
            cudaErrorCheck( cudaMemcpy2D (y_temp, padded * sizeof(double),
                                            host_mech->y, padded * sizeof(double),

    free(y_temp);
    free(host_mech);
    free(host_solver);
    free(result_flag);
    cudaErrorCheck( cudaDeviceReset() );

    return 0;
