<div dir="ltr"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">This comes from OVS code and shows OVS thread spinning, not DPDK PMD.<br>Blame the OVS application for not using e.g. _mm_pause() and burning<br>the CPU like crazy.<br></blockquote><div><br></div><div><br></div>OK, I'm citing a bit more from the same reference:<br><div><b>"By tracing back to the function’s caller </b></div><div><b>in the PMD thread main(void *f_), </b></div><div>we found that the thread kept spinning on the following code block:</div><div><div>for ( ; ; ) {<br>for ( i = 0; i < poll_cnt; i ++) {<br>dp_netdev_process_rxq_port (pmd, list[i].port, poll_list[i].rx) ;<br>}<br>}</div>This indicates that the [PMD] thread was continuously<br>monitoring and executing the receiving data path." </div><div><br></div><div>Cheers,</div><div><br></div><div>Etienne</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Feb 23, 2021 at 10:33 PM Pawel Malachowski <<a href="mailto:pawmal-nanog@freebsd.lublin.pl">pawmal-nanog@freebsd.lublin.pl</a>> 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">> > No, it is not PMD that runs the processor in a polling loop.<br>
> > It is the application itself, thay may or may not busy loop,<br>
> > depending on application programmers choice.<br>
> <br>
> From one of my earlier references [2]:<br>
> <br>
> "we found that a poll mode driver (PMD)<br>
> thread accounted for approximately 99.7 percent<br>
> CPU occupancy (a full core utilization)."<br>
> <br>
> And further on:<br>
> <br>
> "we found that the thread kept spinning on the following code block:<br>
> <br>
> *for ( ; ; ) {for ( i = 0; i < poll_cnt; i ++) {dp_netdev_process_rxq_port<br>
> (pmd, list[i].port, poll_list[i].rx) ;}}*<br>
> This indicates that the thread was continuously<br>
> monitoring and executing the receiving data path."<br>
<br>
This comes from OVS code and shows OVS thread spinning, not DPDK PMD.<br>
Blame the OVS application for not using e.g. _mm_pause() and burning<br>
the CPU like crazy.<br>
<br>
<br>
For comparison, take a look at top+i7z output from DPDK-based 100G DDoS<br>
scrubber currently lifting some low traffic using cores 1-13 on 16 core<br>
host. It uses naive DPDK::rte_pause() throttling to enter C1.<br>
<br>
Tasks: 342 total,   1 running, 195 sleeping,   0 stopped,   0 zombie<br>
%Cpu(s):  6.6 us,  0.6 sy,  0.0 ni, 89.7 id,  3.1 wa,  0.0 hi,  0.0 si,  0.0 st<br>
<br>
        Core [core-id]  :Actual Freq (Mult.)      C0%   Halt(C1)%  C3 %   C6 %  Temp      VCore<br>
        Core 1 [0]:       1467.73 (14.68x)      2.15    5.35       1    92.3    43      0.6724<br>
        Core 2 [1]:       1201.09 (12.01x)      11.7    93.9       0       0    39      0.6575<br>
        Core 3 [2]:       1200.06 (12.00x)      11.8    93.8       0       0    42      0.6543<br>
        Core 4 [3]:       1200.14 (12.00x)      11.8    93.8       0       0    41      0.6549<br>
        Core 5 [4]:       1200.10 (12.00x)      11.8    93.8       0       0    41      0.6526<br>
        Core 6 [5]:       1200.12 (12.00x)      11.8    93.8       0       0    40      0.6559<br>
        Core 7 [6]:       1201.01 (12.01x)      11.8    93.8       0       0    41      0.6559<br>
        Core 8 [7]:       1201.02 (12.01x)      11.8    93.8       0       0    43      0.6525<br>
        Core 9 [8]:       1201.00 (12.01x)      11.8    93.8       0       0    41      0.6857<br>
        Core 10 [9]:      1201.04 (12.01x)      11.8    93.8       0       0    40      0.6541<br>
        Core 11 [10]:     1201.95 (12.02x)      13.6    92.9       0       0    40      0.6558<br>
        Core 12 [11]:     1201.02 (12.01x)      11.8    93.8       0       0    42      0.6526<br>
        Core 13 [12]:     1204.97 (12.05x)      17.6    90.8       0       0    45      0.6814<br>
        Core 14 [13]:     1248.39 (12.48x)      28.2    84.7       0       0    41      0.6855<br>
        Core 15 [14]:     2790.74 (27.91x)      91.9       0       1       1    41      0.8885 <-- not PMD<br>
        Core 16 [15]:     1262.29 (12.62x)      13.1    34.9     1.7    56.2    43      0.6616<br>
<br>
$ dataplanectl stats fcore | grep total<br>
fcore total idle 393788223887 work 860443658 (0.2%) (forced-idle 7458486526622) recv 202201388561 drop 61259353721 (30.3%) limit 269909758 (0.1%) pass 140606076622 (69.6%) ingress 66048460 (0.0%/0.0%) sent 162580376914 (80.4%/100.0%) overflow 0 (0.0%) sampled 628488188/628488188<br>
<br>
<br>
<br>
-- <br>
Pawel Malachowski<br>
@pawmal80<br>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><span style="color:rgb(136,136,136);font-family:tahoma,sans-serif">Ing. Etienne-Victor Depasquale</span><br style="color:rgb(136,136,136);font-family:tahoma,sans-serif"><span style="color:rgb(136,136,136);font-family:tahoma,sans-serif">Assistant Lecturer</span><br style="color:rgb(136,136,136);font-family:tahoma,sans-serif"><span style="color:rgb(136,136,136);font-family:tahoma,sans-serif">Department of Communications & Computer Engineering</span><br style="color:rgb(136,136,136);font-family:tahoma,sans-serif"><span style="color:rgb(136,136,136);font-family:tahoma,sans-serif">Faculty of Information & Communication Technology</span><br style="color:rgb(136,136,136);font-family:tahoma,sans-serif"><span style="color:rgb(136,136,136);font-family:tahoma,sans-serif">University of Malta</span><div>Web. <a href="https://www.um.edu.mt/profile/etiennedepasquale" target="_blank">https://www.um.edu.mt/profile/etiennedepasquale</a><br></div></div></div>