- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Inside the FORTRAN (at line 12), I set a substring of one of the arguments to some value.
What I would like to know is this:
Why do I get the following error message when the /check:bounds option is on?
The error message is: forrtl: severe (408): fort: (19): Dummy character variable 'HERR' has length 255 which is greater then actual variable length -3689348818177883905
This error did not happen with a 32-bit build. Why the long negative integer? Is it a compiler bug?
I am using IVF 11.1.051 (w_cprof_p_11.1.051)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You declared the character lengths as "int" in C. They need to be an "address-sized int".
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You declared the character lengths as "int" in C. They need to be an "address-sized int".
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Dear All,
I am getting the very same error as described above however I have not been able to implement the suggested solution.
The following line is where I'm getting the error. This works successfully in x32.
DPBSV("U", &n,&kd,&nrhs,Aptr,&ldA,Xptr,&ldB,&info);
I would be grateful if someone could post an example of the code utilising intptr_t.
Kind Regards,
Shane
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
If you have a recent copy of Intel C, the header file is provided:
void DPBSV( char* uplo, MKL_INT* n, MKL_INT* kd, MKL_INT* nrhs, double* ab, MKL
_INT* ldab, double* b, MKL_INT* ldb, MKL_INT* info );
(#define MKL_INT int for the case where you use default integers in Fortran)
It's OK when using the standard Fortran source for this function to omit the string length argument. If you wish to access the length of uplo, which the standard code doesn't do, the string length is appended to the argument list.
void DPBSV( char* uplo, MKL_INT* n, MKL_INT* kd, MKL_INT* nrhs, double* ab, MKL
_INT* ldab, double* b, MKL_INT* ldb, MKL_INT* info, MKL_INT *uplo_len );
MKL_INT uplo_len = 1;
DPBSV("U", &n,&kd,&nrhs,Aptr,&ldA,Xptr,&ldB,&info,&uplo_len);
As the standard Fortran source doesn't handle the interface, and by default you have disagreement between the names used in Fortran and C (unless using Windows), you might consider adding the iso_c_binding declaration on the Fortran side, but that suppresses the hidden length argument.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks Tim your suggestion helped alot!
Kind Regards,
Shane.

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page