- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Dear sir or madam:
I need to use dss interface in c++ program.
From Intel® Math Kernel Library Reference Manual MKL 11.1, Page 2973:
The default value of the parameter opt is MKL_DSS_MSG_LVL_WARNING + MKL_DSS_TERM_LVL_ERROR.
By default, the DSS routines use Fortran style indexing for input arrays of integer types (the first value is referenced as array element 1), regardless of whether the Fortran or the C interface is used. To set indexing to C style (the first value is referenced as array element 0), add the following value to the opt parameter: MKL_DSS_ZERO_BASED_INDEXING.
And from dss exmaple dss_sym_c.c, I know that when I need to use default option, I need to write MKL_INT opt = MKL_DSS_DEFAULTS.
So, if I need to set indexing to C style (the first value is referenced as array element 0), which one I should use:
MKL_INT opt = MKL_DSS_DEFAULTS+MKL_DSS_ZERO_BASED_INDEXING or MKL_INT opt = MKL_DSS_MSG_LVL_WARNING + MKL_DSS_TERM_LVL_ERROR+MKL_DSS_ZERO_BASED_INDEXING
Beause when I read mkl_dss.h
#define MKL_DSS_DEFAULTS 0
#define MKL_DSS_ZERO_BASED_INDEXING 131072
#define MKL_DSS_MSG_LVL_WARNING -2147483644
#define MKL_DSS_MSG_LVL_ERROR -2147483643
MKL_DSS_DEFAULTS+MKL_DSS_ZERO_BASED_INDEXING is not equal to MKL_DSS_MSG_LVL_WARNING + MKL_DSS_TERM_LVL_ERROR+MKL_DSS_ZERO_BASED_INDEXING
Thank you very much
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
MKL_DSS_DEFAULTS for each DSS routine take different meaning so it is hard to set it to correct value for each routine. That's the reason why DSS_DEFAULTS is not equal to MKL_DSS_MSG_LVL_WARNING+MKL_DSS_TERM_LVL_ERROR in spite of same behavior. But I am strongly avoid to use MKL_DSS_DEFAULTS as one of component in sum - it is better to expand MKL_DSS_DEFAULS for each routine if you don't want to use default parameter. So, for your case you need to set opt = MKL_DSS_MSG_LVL_WARNING + MKL_DSS_TERM_LVL_ERROR + MKL_DSS_ZERO_BASED_INDEXING.
Thanks,
Alex
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page