/* * Class: com_intel_analytics_bigdl_mkl_MKL * Method: vsSub * Signature: (I[FI[FI[FI)V */ JNIEXPORT void JNICALL Java_com_intel_analytics_bigdl_mkl_MKL_vsSub (JNIEnv * env, jclass cls, jint n, jfloatArray a, jint aOffset, jfloatArray b, jint bOffset, jfloatArray y, jint yOffset) { jfloat * jni_a = (*env)->GetPrimitiveArrayCritical(env, a, JNI_FALSE); jfloat * jni_b = (*env)->GetPrimitiveArrayCritical(env, b, JNI_FALSE); jfloat * jni_y = (*env)->GetPrimitiveArrayCritical(env, y, JNI_FALSE); vsSub( n, jni_a + aOffset, jni_b + bOffset, jni_y + yOffset); (*env)->ReleasePrimitiveArrayCritical(env, y, jni_y, 0); (*env)->ReleasePrimitiveArrayCritical(env, b, jni_b, 0); (*env)->ReleasePrimitiveArrayCritical(env, a, jni_a, 0); }
// To force linking in all needed Intel routines // See compileCX for details (linking against .a) void Dummy(void) { vsAdd(); vsSub(); vsDiv(); vsSqr(); vsMul(); vsAbs(); vsInv(); vsSin(); vsCos(); vsSinCos(); vsTan(); vsAsin(); vsAcos(); vsAtan(); vsAtan2(); vsSinh(); vsCosh(); vsTanh(); vsAsinh(); vsAcosh(); vsAtanh(); vsPow(); vsPowx(); vsSqrt(); vsCbrt(); vsInvSqrt(); vsInvCbrt(); vsHypot(); vsFloor(); vsCeil(); vsRound(); vsTrunc(); vsRint(); vsNearbyInt(); vsModf(); vsExp(); vsLn(); vsLog10(); vsErf(); vsErfc(); vsErfInv(); }
void caffe_sub<float>(const int n, const float* a, const float* b, float* y) { vsSub(n, a, b, y); }
DLLEXPORT void s_vector_subtract( const int n, const float x[], const float y[], float result[] ){ vsSub( n, x, y, result ); }