<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <div class="moz-cite-prefix">Also, you are grepping for LJ_Comb, not
      LJComb as Szilard suggested.<br>
      <br>
      Cheers,<br>
      <br>
      Berk<br>
      <br>
      On 25/04/2019 14.48, Szilárd Páll wrote:<br>
    </div>
    <blockquote type="cite"
cite="mid:CANnYEw7z60+sGqzX24Q0MZhWQbFqWJ3FSqTCFOQCYEtrgO8xSA@mail.gmail.com">
      <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
      <div dir="ltr">
        <div dir="ltr">
          <div dir="ltr">
            <div dir="ltr">
              <div dir="ltr"><br clear="all">
                <div>
                  <div dir="ltr" class="gmail_signature"><br>
                  </div>
                </div>
                <br>
              </div>
              <br>
              <div class="gmail_quote">
                <div dir="ltr" class="gmail_attr">On Thu, Apr 25, 2019
                  at 2:43 PM Mahmood Naderan &lt;<a
                    href="mailto:nt_mahmood@yahoo.com"
                    moz-do-not-send="true">nt_mahmood@yahoo.com</a>&gt;
                  wrote:<br>
                </div>
                <blockquote class="gmail_quote" style="margin:0px 0px
                  0px 0.8ex;border-left:1px solid
                  rgb(204,204,204);padding-left:1ex">
                  <div>
                    <div
                      class="gmail-m_-7076311669053638246ydp470688b9yahoo-style-wrap"
                      style="font-family:&quot;Helvetica
                      Neue&quot;,Helvetica,Arial,sans-serif;font-size:16px">
                      <div>
                        <div><span>&gt; <span>Selection happens at
                              runtime, see
                              in nbnxn_cuda.cu:select_nbnxn_kernel().</span></span></div>
                        <div><span><span><br>
                            </span></span></div>
                        <div><span><span>Yes I see that.</span></span></div>
                        <div><span><span><br>
                            </span></span>
                          <div><br>
                          </div>
                          <span><span></span></span></div>
                        <div><span><br>
                          </span></div>
                        <div><span><br>
                          </span></div>
                        <div><span>&gt; Try "git grep LJComb".</span></div>
                        <div><span><br>
                          </span></div>
                        <div><span>I am trying to find that in 2018.2
                            release that I have currently.</span></div>
                        <div><span><br>
                          </span></div>
                        <div><span><span><a class="moz-txt-link-abbreviated" href="mailto:mahmood@mpc:/opt/gromacs-2018.2/src/gromacs/mdlib/nbnxn_cuda$">mahmood@mpc:/opt/gromacs-2018.2/src/gromacs/mdlib/nbnxn_cuda$</a>
                              grep -i LJ_Comb nbnxn_cuda_kernel.cuh<br>
                              #if defined LJ_COMB_GEOM || defined
                              LJ_COMB_LB<br>
                              #define LJ_COMB<br>
                              #ifndef LJ_COMB<br>
                                  const float2       *lj_comb     =
                              atdat.lj_comb;<br>
                              #ifndef LJ_COMB<br>
                              #if !defined LJ_COMB_LB || defined
                              CALC_ENERGIES<br>
                              #ifdef LJ_COMB_LB<br>
                              #ifndef LJ_COMB<br>
                              #ifndef LJ_COMB<br>
                                      ljcpib[tidxj * c_clSize + tidxi] =
                              lj_comb[ai];<br>
                              #ifndef LJ_COMB<br>
                                                  ljcp_j  = lj_comb[aj];<br>
                              #ifndef LJ_COMB<br>
                              #ifdef LJ_COMB_GEOM<br>
                              #endif                          /*
                              LJ_COMB_GEOM */<br>
                              #endif                          /* LJ_COMB
                              */<br>
                              #if !defined LJ_COMB_LB || defined
                              CALC_ENERGIES<br>
                              #else                           /*
                              !LJ_COMB_LB || CALC_ENERGIES */<br>
                              #endif                          /*
                              !LJ_COMB_LB || CALC_ENERGIES */<br>
                              #undef LJ_COMB<br>
<a class="moz-txt-link-abbreviated" href="mailto:mahmood@mpc:/opt/gromacs-2018.2/src/gromacs/mdlib/nbnxn_cuda$">mahmood@mpc:/opt/gromacs-2018.2/src/gromacs/mdlib/nbnxn_cuda$</a> grep -i
                              LJComb nbnxn_cuda_kernel.cuh<br>
                            </span></span>
                          <div><span><span><a class="moz-txt-link-abbreviated" href="mailto:mahmood@mpc:/opt/gromacs-2018.2/src/gromacs/mdlib/nbnxn_cuda$">mahmood@mpc:/opt/gromacs-2018.2/src/gromacs/mdlib/nbnxn_cuda$</a></span></span></div>
                        </div>
                      </div>
                    </div>
                  </div>
                </blockquote>
                <div><br>
                </div>
                <div>As suggested before, grep the source repo, not that
                  one file; or grep the right file -- the one I
                  recommended looking at in my previous email
                  (src/gromacs/mdlib/nbnxn_cuda/nbnxn_cuda_kernels.cuh).</div>
                <div> </div>
                <blockquote class="gmail_quote" style="margin:0px 0px
                  0px 0.8ex;border-left:1px solid
                  rgb(204,204,204);padding-left:1ex">
                  <div>
                    <div
                      class="gmail-m_-7076311669053638246ydp470688b9yahoo-style-wrap"
                      style="font-family:&quot;Helvetica
                      Neue&quot;,Helvetica,Arial,sans-serif;font-size:16px">
                      <div>
                        <div>
                          <div><span><span></span></span><br>
                          </div>
                          <div><br>
                          </div>
                          <div><br>
                          </div>
                          <div><br>
                          </div>
                          <div>I expect that <span><span><span>VdwLJCombLB_F</span></span></span>
                            means that the statements that must be
                            executed in <span>nbnxn_cuda_kernel.cuh,
                              are those that are used in defined macros.</span></div>
                        </div>
                      </div>
                    </div>
                  </div>
                </blockquote>
                <div><br>
                </div>
                <div>Correct. In fact the "VdwLJCombLB" kenrnels will
                  not even have e.g. VdwLJFsw  (i.e. LJ force switch)
                  code included in them.</div>
                <div> </div>
                <blockquote class="gmail_quote" style="margin:0px 0px
                  0px 0.8ex;border-left:1px solid
                  rgb(204,204,204);padding-left:1ex">
                  <div>
                    <div
                      class="gmail-m_-7076311669053638246ydp470688b9yahoo-style-wrap"
                      style="font-family:&quot;Helvetica
                      Neue&quot;,Helvetica,Arial,sans-serif;font-size:16px">
                      <div>
                        <div>
                          <div><span><br>
                            </span></div>
                          <div><span>For example, since I see Vdw, the
                              following code must be executed</span></div>
                          <div><span><br>
                            </span></div>
                          <div><span><span>#ifdef VDW_CUTOFF_CHECK<br>
                                                                /*
                                Separate VDW cut-off check to enable
                                twin-range cut-offs<br>
                                                                 * (rvdw
                                &lt; rcoulomb &lt;= rlist)<br>
                                                                 */<br>
                                                               
                                vdw_in_range  = (r2 &lt; rvdw_sq) ? 1.0f
                                : 0.0f;<br>
                                                               
                                F_invr       *= vdw_in_range;<br>
                                <br>
                              </span></span>
                            <div><br>
                            </div>
                            <div><br>
                            </div>
                            <div>Also, since LJCombLB is seen, the
                              following code must be executed<br>
                            </div>
                            <div><br>
                            </div>
                            <div><br>
                            </div>
                            <div><span>#else                          
                                /* !LJ_COMB_LB || CALC_ENERGIES */<br>
                                                                float
                                sig_r  = sigma*inv_r;<br>
                                                                float
                                sig_r2 = sig_r*sig_r;<br>
                                                                float
                                sig_r6 = sig_r2*sig_r2*sig_r2;<br>
                              </span></div>
                          </div>
                        </div>
                        <div><br>
                        </div>
                        <div><br>
                        </div>
                        <div><br>
                        </div>
                        <div><br>
                        </div>
                        <div>And so on...</div>
                        <div><br>
                        </div>
                        <div>Please let me know if I still haven't
                          understand that.</div>
                        <br>
                        <div><br>
                        </div>
                        <div><br>
                        </div>
                        <div
                          class="gmail-m_-7076311669053638246ydp470688b9signature">Regards,<br>
                          Mahmood</div>
                      </div>
                      <div><br>
                      </div>
                    </div>
                    <div><br>
                    </div>
                  </div>
                </blockquote>
              </div>
            </div>
          </div>
        </div>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
    </blockquote>
    <br>
  </body>
</html>