[ 
https://issues.apache.org/jira/browse/DISPATCH-2121?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17345979#comment-17345979
 ] 

Jiri Daněk commented on DISPATCH-2121:
--------------------------------------

There are benefits from simply enabling LTO within Dispatch and also from 
enabling {{-fno-semantic-interposition}} [1]. This is beneficial even when 
Proton is linked dynamically. The semantic interposition option can have 
negative impact on DISPATCH-1783 (interposition is the mechanism to reconfigure 
program at runtime and inject mocks), but that's something that can be resolved 
when the time comes (turn interposition back on when intending to run 
unittests). Interposition is disabled by default on Clang.

[1] https://fedoraproject.org/wiki/Changes/PythonNoSemanticInterpositionSpeedup

Before

{noformat}
% iperf3 -c 127.0.0.1 -p 5202
Connecting to host 127.0.0.1, port 5202
[  5] local 127.0.0.1 port 44890 connected to 127.0.0.1 port 5202
[ ID] Interval           Transfer     Bitrate         Retr  Cwnd
[  5]   0.00-1.00   sec  45.0 MBytes   377 Mbits/sec    0   1.25 MBytes       
[  5]   1.00-2.00   sec  38.8 MBytes   325 Mbits/sec    0   1.25 MBytes       
[  5]   2.00-3.00   sec  51.2 MBytes   430 Mbits/sec    0   1.25 MBytes       
[  5]   3.00-4.00   sec  52.5 MBytes   440 Mbits/sec    0   1.25 MBytes       
[  5]   4.00-5.00   sec  46.2 MBytes   388 Mbits/sec    0   1.25 MBytes       
[  5]   5.00-6.00   sec  46.2 MBytes   388 Mbits/sec    0   1.25 MBytes       
[  5]   6.00-7.00   sec  47.5 MBytes   398 Mbits/sec    0   1.25 MBytes       
[  5]   7.00-8.00   sec  51.2 MBytes   430 Mbits/sec    0   1.25 MBytes       
[  5]   8.00-9.00   sec  53.8 MBytes   451 Mbits/sec    0   1.25 MBytes       
[  5]   9.00-10.00  sec  48.8 MBytes   409 Mbits/sec    0   1.25 MBytes       
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval           Transfer     Bitrate         Retr
[  5]   0.00-10.00  sec   481 MBytes   404 Mbits/sec    0             sender
[  5]   0.00-10.00  sec   474 MBytes   397 Mbits/sec                  receiver

iperf Done.
{noformat}

After

{noformat}
% iperf3 -c 127.0.0.1 -p 5202
Connecting to host 127.0.0.1, port 5202
[  5] local 127.0.0.1 port 45122 connected to 127.0.0.1 port 5202
[ ID] Interval           Transfer     Bitrate         Retr  Cwnd
[  5]   0.00-1.00   sec  66.2 MBytes   556 Mbits/sec    0   1.19 MBytes       
[  5]   1.00-2.00   sec  56.2 MBytes   472 Mbits/sec    0   1.19 MBytes       
[  5]   2.00-3.00   sec  63.8 MBytes   535 Mbits/sec    0   1.19 MBytes       
[  5]   3.00-4.00   sec  58.8 MBytes   493 Mbits/sec    0   1.19 MBytes       
[  5]   4.00-5.00   sec  57.5 MBytes   482 Mbits/sec    0   1.19 MBytes       
[  5]   5.00-6.00   sec  62.5 MBytes   524 Mbits/sec    0   1.19 MBytes       
[  5]   6.00-7.00   sec  60.0 MBytes   503 Mbits/sec    0   1.19 MBytes       
[  5]   7.00-8.00   sec  61.2 MBytes   514 Mbits/sec    0   1.19 MBytes       
[  5]   8.00-9.00   sec  60.0 MBytes   503 Mbits/sec    0   1.19 MBytes       
[  5]   9.00-10.00  sec  61.2 MBytes   514 Mbits/sec    0   1.19 MBytes       
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval           Transfer     Bitrate         Retr
[  5]   0.00-10.00  sec   608 MBytes   510 Mbits/sec    0             sender
[  5]   0.00-10.00  sec   599 MBytes   503 Mbits/sec                  receiver
{noformat}

So enabling LTO and turning interposition seems to be worth doing.

> Investigate whether there might be benefits from LTO-ing Proton into Dispatch
> -----------------------------------------------------------------------------
>
>                 Key: DISPATCH-2121
>                 URL: https://issues.apache.org/jira/browse/DISPATCH-2121
>             Project: Qpid Dispatch
>          Issue Type: Task
>    Affects Versions: 1.16.0
>            Reporter: Jiri Daněk
>            Assignee: Jiri Daněk
>            Priority: Major
>             Fix For: 1.17.0
>
>
> https://stackoverflow.com/questions/25878407/how-can-i-use-lto-with-static-libraries



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to