| 585 | // ---------------------------------------------------------------------------------------- |
| 586 | |
| 587 | inline float dot(const simd4f& lhs, const simd4f& rhs) |
| 588 | { |
| 589 | #ifdef DLIB_HAVE_SSE41 |
| 590 | return _mm_cvtss_f32(_mm_dp_ps(lhs, rhs, 0xff)); |
| 591 | #else |
| 592 | return sum(lhs*rhs); |
| 593 | #endif |
| 594 | } |
| 595 | |
| 596 | // ---------------------------------------------------------------------------------------- |
| 597 |