Skip to content

Commit de3169f

Browse files
Test: add xNRM2 prototypes to C++ header
1 parent 7550683 commit de3169f

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

TESTING/cpp/lapack.hpp

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,9 @@
4444

4545
extern "C"
4646
{
47+
float snrm2_(lapack_int* n, const float* p, lapack_int* incx);
48+
double dnrm2_(lapack_int* n, const double* p, lapack_int* incx);
49+
4750
void sgemm_(
4851
char* transa, char* transb,
4952
lapack_int* m, lapack_int* n, lapack_int* k,
@@ -1082,6 +1085,15 @@ inline integer_t xLASRTR(
10821085

10831086

10841087

1088+
float xNRM2(integer_t n, const float* x, integer_t incx) {
1089+
return snrm2_(&n, x, &incx);
1090+
}
1091+
1092+
double xNRM2(integer_t n, const double* x, integer_t incx) {
1093+
return dnrm2_(&n, x, &incx);
1094+
}
1095+
1096+
10851097
inline integer_t xPSTRF(
10861098
char uplo, integer_t n, float* A, integer_t lda,
10871099
integer_t* p_piv, integer_t* p_rank, float tol,

0 commit comments

Comments
 (0)