For PtlNIInit(...), if you specify PTL_SIZE_MAX for any of the ptl_ni_limits_t
members which are of type ptl_size_t e.g. max_msg_size, the actual values
returned by the reference implementation are set to the minimums. Looking at
the source code, src/ib/ptl_ni.c the static function set_limits(...) function
calls chk_param(int,long). Since the requested value is passed as an unsigned
64bit type (ptl_size_t) it is truncated to 0 when automatically cast to a long.
Source code to reproduce:
ptl_ni_limits_t ptl_ni_limits_requested;
ptl_ni_limits_requested.max_entries = INT_MAX;
ptl_ni_limits_requested.max_unexpected_headers = INT_MAX;
ptl_ni_limits_requested.max_mds = INT_MAX;
ptl_ni_limits_requested.max_eqs = INT_MAX;
ptl_ni_limits_requested.max_cts = INT_MAX;
ptl_ni_limits_requested.max_pt_index = INT_MAX;
ptl_ni_limits_requested.max_iovecs = INT_MAX;
ptl_ni_limits_requested.max_list_size = INT_MAX;
ptl_ni_limits_requested.max_triggered_ops = INT_MAX;
ptl_ni_limits_requested.max_msg_size = PTL_SIZE_MAX;
ptl_ni_limits_requested.max_atomic_size = PTL_SIZE_MAX;
ptl_ni_limits_requested.max_fetch_atomic_size = PTL_SIZE_MAX;
ptl_ni_limits_requested.max_waw_ordered_size = PTL_SIZE_MAX;
ptl_ni_limits_requested.max_war_ordered_size = PTL_SIZE_MAX;
ptl_ni_limits_requested.max_volatile_size = PTL_SIZE_MAX;
ptl_ni_limits_requested.features = PTL_TARGET_BIND_INACCESSIBLE;
status = PtlNIInit(PTL_IFACE_DEFAULT,
PTL_NI_NO_MATCHING | PTL_NI_LOGICAL,
PTL_PID_ANY,
&ptl_ni_limits_requested,
&l_state.ptl_ni_limits,
&l_state.ptl_ni_handle);
assert(PTL_OK == status);
printf("max_entries = %d (%d requested)\n",
l_state.ptl_ni_limits.max_entries,
ptl_ni_limits_requested.max_entries);
printf("max_unexpected_headers = %d (%d requested)\n",
l_state.ptl_ni_limits.max_unexpected_headers,
ptl_ni_limits_requested.max_unexpected_headers);
printf("max_mds = %d (%d requested)\n",
l_state.ptl_ni_limits.max_mds,
ptl_ni_limits_requested.max_mds);
printf("max_eqs = %d (%d requested)\n",
l_state.ptl_ni_limits.max_eqs,
ptl_ni_limits_requested.max_eqs);
printf("max_cts = %d (%d requested)\n",
l_state.ptl_ni_limits.max_cts,
ptl_ni_limits_requested.max_cts);
printf("max_pt_index = %d (%d requested)\n",
l_state.ptl_ni_limits.max_pt_index,
ptl_ni_limits_requested.max_pt_index);
printf("max_iovecs = %d (%d requested)\n",
l_state.ptl_ni_limits.max_iovecs,
ptl_ni_limits_requested.max_iovecs);
printf("max_list_size = %d (%d requested)\n",
l_state.ptl_ni_limits.max_list_size,
ptl_ni_limits_requested.max_list_size);
printf("max_triggered_ops = %d (%d requested)\n",
l_state.ptl_ni_limits.max_triggered_ops,
ptl_ni_limits_requested.max_triggered_ops);
printf("max_msg_size = %llu (%llu requested)\n",
(long long unsigned)l_state.ptl_ni_limits.max_msg_size,
(long long unsigned)ptl_ni_limits_requested.max_msg_size);
printf("max_atomic_size = %llu (%llu requested)\n",
(long long unsigned)l_state.ptl_ni_limits.max_atomic_size,
(long long unsigned)ptl_ni_limits_requested.max_atomic_size);
printf("max_fetch_atomic_size = %llu (%llu requested)\n",
(long long unsigned)l_state.ptl_ni_limits.max_fetch_atomic_size,
(long long unsigned)ptl_ni_limits_requested.max_fetch_atomic_size);
printf("max_waw_ordered_size = %llu (%llu requested)\n",
(long long unsigned)l_state.ptl_ni_limits.max_waw_ordered_size,
(long long unsigned)ptl_ni_limits_requested.max_waw_ordered_size);
printf("max_war_ordered_size = %llu (%llu requested)\n",
(long long unsigned)l_state.ptl_ni_limits.max_war_ordered_size,
(long long unsigned)ptl_ni_limits_requested.max_war_ordered_size);
printf("max_volatile_size = %llu (%lu requested)\n",
(long long unsigned)l_state.ptl_ni_limits.max_volatile_size,
(long long unsigned)ptl_ni_limits_requested.max_volatile_size);
printf("features = %u (%u requested)\n",
l_state.ptl_ni_limits.features,
ptl_ni_limits_requested.features);
What version of the product are you using? On what operating system?
URL: http://portals4.googlecode.com/svn/trunk/src/ib
Repository Root: http://portals4.googlecode.com/svn
Repository UUID: 4e5cb362-e38f-11de-a053-3b9a60e514ca
Revision: 2209
Node Kind: directory
Schedule: normal
Last Changed Author: [email protected]
Last Changed Rev: 2209
Last Changed Date: 2013-05-29 10:26:30 -0700 (Wed, 29 May 2013)
Running on OSX 10.7.5 but I imagine this will happen almost anywhere.