<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:DengXian;
panose-1:2 1 6 0 3 1 1 1 1 1;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Aptos;}
@font-face
{font-family:"Helvetica Neue";}
@font-face
{font-family:"\@DengXian";
panose-1:2 1 6 0 3 1 1 1 1 1;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
font-size:11.0pt;
font-family:"Aptos",sans-serif;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:#467886;
text-decoration:underline;}
span.EmailStyle20
{mso-style-type:personal-reply;
font-family:"Aptos",sans-serif;
color:windowtext;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:10.0pt;
mso-ligatures:none;}
@page WordSection1
{size:8.5in 11.0in;
margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-US" link="#467886" vlink="#96607D" style="word-wrap:break-word">
<div class="WordSection1">
<p class="MsoNormal">The inject size is the maximum allowed size, so the condition is “message size <= inject size”. The man page needs to be fixed for clarity.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">The behavior of injecting with size greater than inject size is undefined. The provider has the freedom to implement it in the most efficient way. For example, some providers just have an assertion there, so it would cause assertion failure
for a debugging build but would continue silently (and may cause errors later) for a release build. In a nutshell, the expectation is that the user should ensure the size is right when using the FI_INJECT flag or calling the fi_inject*() functions.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<div style="border:none;border-left:solid blue 1.5pt;padding:0in 0in 0in 4.0pt">
<div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal"><b><span style="font-family:"Calibri",sans-serif">From:</span></b><span style="font-family:"Calibri",sans-serif"> Libfabric-users <libfabric-users-bounces@lists.openfabrics.org>
<b>On Behalf Of </b>Niyaz Murshed<br>
<b>Sent:</b> Friday, August 16, 2024 10:19 AM<br>
<b>To:</b> Hartman, John <john.hartman@hpe.com>; libfabric-users@lists.openfabrics.org<br>
<b>Cc:</b> nd <nd@arm.com><br>
<b>Subject:</b> Re: [libfabric-users] FI_INJECT and fi_sendmsg<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">My understand is that application need to make sure that we use inject API only if message < inject Size ( as it is done in fi_rma_bw sample).<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">In case of error, I would assume the below is the error.<o:p></o:p></p>
<p class="MsoNormal" style="line-height:15.0pt;background:white"><b><i><span style="font-size:10.5pt;font-family:"Helvetica Neue";color:#333333">-FI_EAGAIN</span></i></b><b><span style="font-size:10.5pt;font-family:"Helvetica Neue";color:#333333"><o:p></o:p></span></b></p>
<p class="MsoNormal" style="margin-left:.5in;line-height:15.0pt;background:white">
<span style="font-size:10.5pt;font-family:"Helvetica Neue";color:#333333">Indicates that the underlying provider currently lacks the resources needed to initiate the requested operation. This may be the result of insufficient internal buffering, in the case
of FI_INJECT, or processing queues are full.<o:p></o:p></span></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">I am still new to libfabric, might be wrong… Hope someone can correct me if I am.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<div id="mail-editor-reference-message-container">
<div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal" style="margin-bottom:12.0pt"><b><span style="font-size:12.0pt;color:black">From:
</span></b><span style="font-size:12.0pt;color:black">Libfabric-users <<a href="mailto:libfabric-users-bounces@lists.openfabrics.org">libfabric-users-bounces@lists.openfabrics.org</a>> on behalf of Hartman, John <<a href="mailto:john.hartman@hpe.com">john.hartman@hpe.com</a>><br>
<b>Date: </b>Friday, August 16, 2024 at 12:01</span><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black"> </span><span style="font-size:12.0pt;color:black">PM<br>
<b>To: </b><a href="mailto:libfabric-users@lists.openfabrics.org">libfabric-users@lists.openfabrics.org</a> <<a href="mailto:Libfabric-users@lists.openfabrics.org">Libfabric-users@lists.openfabrics.org</a>><br>
<b>Subject: </b>[libfabric-users] FI_INJECT and fi_sendmsg<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt">Regarding the FI_INJECT flag, the fi_sendmsg man page says “This flag can only be used with messages smaller than inject_size.” What is the behavior if the message is larger than inject_size? Is the flag ignored,
or is an error returned (and if so, which error)? </span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:12.0pt"> </span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:12.0pt">Also, the fi_sendmsg man page says “messages smaller than inject_size” whereas the fi_endpoint man page says that inject_size is “the maximum size data transfer that can be associated with an inject operation”.
Which is correct, should the message be < inject_size or <= inject_size?</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:12.0pt"> </span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:12.0pt">I’m looking at the v1.22.0 man pages.</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:12.0pt"> </span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:12.0pt">Thanks</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:12.0pt"> </span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Calibri",sans-serif">John</span><o:p></o:p></p>
</div>
</div>
</div>
</div>
</div>
</body>
</html>