<HTML><HEAD></HEAD>
<BODY dir=ltr>
<DIV dir=ltr>
<DIV style="FONT-SIZE: 12pt; FONT-FAMILY: 'Calibri'; COLOR: #000000">
<DIV>Hi,</DIV>
<DIV> </DIV>
<DIV>just a side advice: do not use RTC as i also tried to measure some 
actions.</DIV>
<DIV> </DIV>
<DIV>I tried the following</DIV>
<DIV>   rtc1 = rtc.get_current_time();</DIV>
<DIV>   rtc2 = rtc.get_current_time();</DIV>
<DIV>and always got a difference of 1 second. (in a loop) – and that was only 
with calling rtc.</DIV>
<DIV> </DIV>
<DIV>So i looked at RTC ( <SPAN 
style='FONT-FAMILY: ; LINE-HEIGHT: 18pt; mso-fareast-font-family: "Times New Roman"; mso-ansi-language: de; mso-fareast-language: de; mso-bidi-language: ar-sa'><A 
style='href: "https://github.com/genodelabs/genode/blob/master/repos/os/src/drivers/rtc/x86/main.cc"'><FONT 
color=#0000ff 
face="Times New Roman">https://github.com/genodelabs/genode/blob/master/repos/os/src/drivers/rtc/x86/main.cc</FONT></A><FONT 
face="Times New Roman"> </FONT><FONT color=#333333 face=Calibri>) and found: 
“</FONT></SPAN><FONT style='face: "Courier' new?><FONT 
style="COLOR: #333333"><SPAN class=k3><SPAN 
style="FONT-FAMILY: ; COLOR: ; LINE-HEIGHT: 17pt; mso-bidi-font-size: 10.0pt"><FONT 
style="FONT-SIZE: 11pt">return</FONT></SPAN></SPAN><SPAN 
style="FONT-FAMILY: ; COLOR: ; LINE-HEIGHT: 17pt; mso-bidi-font-size: 10.0pt"><FONT 
style="FONT-SIZE: 11pt"> <SPAN class=n2>mktime</SPAN><SPAN class=p>(</SPAN><SPAN 
class=n2>day</SPAN><SPAN class=p>,</SPAN> <SPAN class=n2>mon</SPAN><SPAN 
class=p>,</SPAN> <SPAN class=n2>year</SPAN><SPAN class=p>,</SPAN> <SPAN 
class=n2>hour</SPAN><SPAN class=p>,</SPAN> <SPAN class=n2>min</SPAN><SPAN 
class=p>,</SPAN> <SPAN class=n2>sec</SPAN><SPAN class=p>)</SPAN> <SPAN 
class=o2>*</SPAN> </FONT></SPAN></FONT></FONT><FONT style='face: "Courier' 
new?><FONT style="COLOR: #333333"><SPAN class=mi2><SPAN 
style="FONT-FAMILY: ; COLOR: ; LINE-HEIGHT: 17pt; mso-bidi-font-size: 10.0pt"><FONT 
style="FONT-SIZE: 11pt">1000000ULL</FONT></SPAN></SPAN><SPAN class=p><SPAN 
style="FONT-FAMILY: ; COLOR: ; LINE-HEIGHT: 17pt; mso-bidi-font-size: 10.0pt"><FONT 
style="FONT-SIZE: 11pt">;”  s</FONT></SPAN></SPAN></FONT></FONT><FONT 
style='face: "Courier' new?><FONT style="COLOR: #333333"><SPAN class=p><SPAN 
style="FONT-FAMILY: ; COLOR: ; LINE-HEIGHT: 17pt; mso-bidi-font-size: 10.0pt">o 
it only has a precision of one second and only gives you a value that looks like 
it could have a higher precision.</SPAN></SPAN></FONT></FONT></DIV>
<DIV><FONT style='face: "Courier' new?><FONT style="COLOR: #333333"><SPAN 
class=p><SPAN 
style="FONT-FAMILY: ; COLOR: ; LINE-HEIGHT: 17pt; mso-bidi-font-size: 10.0pt"></SPAN></SPAN></FONT></FONT> </DIV>
<DIV><SPAN 
style='FONT-FAMILY: ; LINE-HEIGHT: 18pt; mso-fareast-font-family: "Times New Roman"; mso-ansi-language: de; mso-fareast-language: de; mso-bidi-language: ar-sa'><FONT 
face="Times New Roman">Take alook at RDTSC in <SPAN 
style='FONT-FAMILY: ; LINE-HEIGHT: 18pt; mso-fareast-font-family: "Times New Roman"; mso-ansi-language: de; mso-fareast-language: de; mso-bidi-language: ar-sa'><A 
style='href: "https://github.com/genodelabs/genode/tree/master/repos/os/include/x86_64/trace/timestamp.h"' 
href="https://github.com/genodelabs/genode/tree/master/repos/os/include/x86_64/trace\timestamp.h"><FONT 
color=#0000ff>https://github.com/genodelabs/genode/tree/master/repos/os/include/x86_64/trace\timestamp.h</FONT></A></SPAN></FONT></SPAN></DIV>
<DIV><SPAN 
style='FONT-FAMILY: ; LINE-HEIGHT: 18pt; mso-fareast-font-family: "Times New Roman"; mso-ansi-language: de; mso-fareast-language: de; mso-bidi-language: ar-sa'><FONT 
face="Times New Roman"><SPAN 
style='FONT-FAMILY: ; LINE-HEIGHT: 18pt; mso-fareast-font-family: "Times New Roman"; mso-ansi-language: de; mso-fareast-language: de; mso-bidi-language: ar-sa'>This 
will inline the code so you do not have costly RPC 
calls.</SPAN></FONT></SPAN></DIV>
<DIV><SPAN 
style='FONT-FAMILY: ; LINE-HEIGHT: 18pt; mso-fareast-font-family: "Times New Roman"; mso-ansi-language: de; mso-fareast-language: de; mso-bidi-language: ar-sa'><FONT 
face="Times New Roman"><SPAN 
style='FONT-FAMILY: ; LINE-HEIGHT: 18pt; mso-fareast-font-family: "Times New Roman"; mso-ansi-language: de; mso-fareast-language: de; mso-bidi-language: ar-sa'></SPAN></FONT></SPAN> </DIV>
<DIV><SPAN 
style='FONT-FAMILY: ; LINE-HEIGHT: 18pt; mso-fareast-font-family: "Times New Roman"; mso-ansi-language: de; mso-fareast-language: de; mso-bidi-language: ar-sa'><FONT 
face="Times New Roman"><SPAN 
style='FONT-FAMILY: ; LINE-HEIGHT: 18pt; mso-fareast-font-family: "Times New Roman"; mso-ansi-language: de; mso-fareast-language: de; mso-bidi-language: ar-sa'>RDTSC 
will give you huge numbers, the prozessor counters. If your prozessor is running 
at for example 2.4 Ghz you will see values for one second around 2.400.000.000 
(can differ a bit as machines are not running exactly at x 
Mhz).</SPAN></FONT></SPAN></DIV>
<DIV><SPAN 
style='FONT-FAMILY: ; LINE-HEIGHT: 18pt; mso-fareast-font-family: "Times New Roman"; mso-ansi-language: de; mso-fareast-language: de; mso-bidi-language: ar-sa'><FONT 
face="Times New Roman"><SPAN 
style='FONT-FAMILY: ; LINE-HEIGHT: 18pt; mso-fareast-font-family: "Times New Roman"; mso-ansi-language: de; mso-fareast-language: de; mso-bidi-language: ar-sa'>With 
the machine i tested it is still not completly accurate, but has a standard 
deviation less then 50 microseconds.</SPAN></FONT></SPAN></DIV>
<DIV><SPAN 
style='FONT-FAMILY: ; LINE-HEIGHT: 18pt; mso-fareast-font-family: "Times New Roman"; mso-ansi-language: de; mso-fareast-language: de; mso-bidi-language: ar-sa'><FONT 
face="Times New Roman"><SPAN 
style='FONT-FAMILY: ; LINE-HEIGHT: 18pt; mso-fareast-font-family: "Times New Roman"; mso-ansi-language: de; mso-fareast-language: de; mso-bidi-language: ar-sa'></SPAN></FONT></SPAN> </DIV>
<DIV><SPAN 
style='FONT-FAMILY: ; LINE-HEIGHT: 18pt; mso-fareast-font-family: "Times New Roman"; mso-ansi-language: de; mso-fareast-language: de; mso-bidi-language: ar-sa'><FONT 
face="Times New Roman"><SPAN 
style='FONT-FAMILY: ; LINE-HEIGHT: 18pt; mso-fareast-font-family: "Times New Roman"; mso-ansi-language: de; mso-fareast-language: de; mso-bidi-language: ar-sa'>Best 
regards</SPAN></FONT></SPAN></DIV>
<DIV><SPAN 
style='FONT-FAMILY: ; LINE-HEIGHT: 18pt; mso-fareast-font-family: "Times New Roman"; mso-ansi-language: de; mso-fareast-language: de; mso-bidi-language: ar-sa'><FONT 
face="Times New Roman"><SPAN 
style='FONT-FAMILY: ; LINE-HEIGHT: 18pt; mso-fareast-font-family: "Times New Roman"; mso-ansi-language: de; mso-fareast-language: de; mso-bidi-language: ar-sa'>Wolfgang</SPAN></FONT></SPAN></DIV>
<DIV><SPAN 
style='FONT-FAMILY: ; LINE-HEIGHT: 18pt; mso-fareast-font-family: "Times New Roman"; mso-ansi-language: de; mso-fareast-language: de; mso-bidi-language: ar-sa'><FONT 
face="Times New Roman"><SPAN 
style='FONT-FAMILY: ; LINE-HEIGHT: 18pt; mso-fareast-font-family: "Times New Roman"; mso-ansi-language: de; mso-fareast-language: de; mso-bidi-language: ar-sa'></SPAN></FONT></SPAN> </DIV>
<DIV 
style='FONT-SIZE: small; TEXT-DECORATION: none; FONT-FAMILY: "Calibri"; FONT-WEIGHT: normal; COLOR: #000000; FONT-STYLE: normal; DISPLAY: inline'>
<DIV style="FONT: 10pt tahoma">
<DIV><FONT size=3 face=Calibri></FONT> </DIV>
<DIV style="BACKGROUND: #f5f5f5">
<DIV style="font-color: black"><B>From:</B> <A title=kloisiie@...236... 
href="mailto:kloisiie@...236...">王硕</A> </DIV>
<DIV><B>Sent:</B> Friday, September 5, 2014 10:24 PM</DIV>
<DIV><B>To:</B> <A title=genode-main@lists.sourceforge.net 
href="mailto:genode-main@lists.sourceforge.net">genode-main</A> </DIV>
<DIV><B>Subject:</B> Re: Some questions about performance optimization related 
toGUIframework on Genode</DIV></DIV></DIV>
<DIV> </DIV></DIV>
<DIV 
style='FONT-SIZE: small; TEXT-DECORATION: none; FONT-FAMILY: "Calibri"; FONT-WEIGHT: normal; COLOR: #000000; FONT-STYLE: normal; DISPLAY: inline'>Hello 
Norman,<BR>
<P>In Genode, it takes approximately 3 seconds for qt_launchpad to launch, and 
more than 1 seconds for other apps to launch. This is too slow, so my task is to 
reduce the launch time of qt_launchpad and apps. But I don't know what the 
reason of the low performance is. So I turn to you for some advice.</P>
<P>I use Rtc (\os\src\drivers\rtc\x86) to record the launch time of qt_launchpad 
and apps as listed below:</P>
<P>in main.cpp of qt_launchpad:</P>
<P><FONT color=#008000>int main(int argc, char *argv[])<BR>{<BR>/*Use Rtc to 
record the time*/<BR>...<BR>...<BR>launchpad->show();<BR>/*Use Rtc to record 
the time again*/ <BR>...<BR>...<BR>}</FONT></P>
<P>in launch_entry.cpp of qt_launchpad: </P>
<P><FONT color=#008000>void Launch_entry::on_launchButton_clicked()</FONT><FONT 
color=#008000><BR></FONT><FONT color=#008000>{</FONT></P>
<P><FONT color=#008000></FONT><FONT color=#008000>/*Use Rtc to record the 
time*/</FONT><FONT color=#008000> </FONT><FONT color=#008000><BR></FONT><FONT 
color=#008000>_launchpad->start_child(_filename, ...);</FONT></P>
<P><FONT color=#008000>/*Use Rtc to record the time again*/ </FONT><FONT 
color=#008000></FONT><FONT color=#008000><BR></FONT><FONT 
color=#008000>}</FONT></P>
<P> </P>
<DIV>
<DIV style="FONT-SIZE: 14px; FONT-FAMILY: verdana; COLOR: #000">
<DIV>Shuo Wang, <BR>University of Chinese Academy of Sciences.</DIV></DIV></DIV>
<DIV> </DIV>
<DIV>
<DIV> </DIV>
<DIV> </DIV>
<DIV>----<SPAN id=_editor_bookmark_start_306 
style="DISPLAY: none; LINE-HEIGHT: 0px">‍</SPAN>--<SPAN 
id=_editor_bookmark_start_307 
style="DISPLAY: none; LINE-HEIGHT: 0px">‍</SPAN>--<SPAN 
id=_editor_bookmark_start_308 
style="DISPLAY: none; LINE-HEIGHT: 0px">‍</SPAN>Original mail----<SPAN 
id=_editor_bookmark_start_309 
style="DISPLAY: none; LINE-HEIGHT: 0px">‍</SPAN>--<SPAN 
id=_editor_bookmark_start_310 
style="DISPLAY: none; LINE-HEIGHT: 0px">‍</SPAN>--<BR>Sender: norman.feske 
<norman.feske@...1...>    <BR>(by 
genode-main-bounces@lists.sourceforge.net )<BR>Time: 2014-09-01 (Mon) 12:00 
(UTC+02:00)    <BR>Receiver: genode-main 
<genode-main@lists.sourceforge.net><BR><SPAN id=_editor_bookmark_start_868 
style="DISPLAY: none; LINE-HEIGHT: 0px">‍</SPAN><BR><SPAN 
id=_editor_bookmark_start_867 
style="DISPLAY: none; LINE-HEIGHT: 0px">‍</SPAN><SPAN 
id=_editor_bookmark_start_311 
style="DISPLAY: none; LINE-HEIGHT: 0px">‍</SPAN></DIV>Hello Shuo 
Wang,<BR><BR>> The Git branch of our genode is listed below:<BR>> 
https://github.com/kloisiie/vsos<BR><BR>thanks for making your modifications 
publicly available. But I am wondering:<BR><BR>Why haven't you just forked the 
Genode repository? See<BR><BR>  
https://github.com/genodelabs/genode<BR><BR>By having imported a snapshot of the 
source code to a new repository,<BR>you removed all the history and cannot 
easily follow the mainline<BR>development. For me, this makes it almost 
impossible to spot your<BR>modifications. Why haven't you just applied your 
changes as a topic<BR>branch on top of the regular Genode 
repository?<BR><BR>Moreover, why have you removed the LICENSE file from 
top-level<BR>directory? The license is important information and should always 
be<BR>prominently visible.<BR><BR>I would also recommend to keep the original 
README file or, at least,<BR>provide a link to the original Genode 
repository.<BR><BR>> * Have you tried to run your GUI application on 
base-linux? If yes,<BR>> have you compared its performance to the same 
application compiled for<BR>> native Linux w/o Genode?<BR>> Our apps is 
Fiasco.OC-specific, so I don't know how to run these apps on<BR>> 
base-linux.<BR>> <BR>> * On base-linux, you could use normal Linux 
profiling tools such as<BR>> oprofile to find out where the CPU time 
goes.<BR>> Please recommend some similar tools on base-foc.<BR><BR>There is 
no such tool for base-foc. For this reason, I recommended to<BR>run the 
application on base-linux in the first place.<BR><BR>Even if you application 
depends on Fiasco.OC, you might still use any of<BR>the other (portable) example 
applications to investigate an eventual<BR>performance problem of Qt. First 
check if the behavior that you noticed<BR>can be reproduced with one of those 
example applications. If that is the<BR>case, run the same application on Linux 
and use oprofile to investigate.<BR><BR>> * Can you make a Git branch with 
your application publicly available‍<BR>> 
https://github.com/kloisiie/vsos‍<BR>> To run the vsos, use<BR>> $ 
./create_builddir fox_x86_32 build_dir=~/<build-directory><BR>> to 
create a build directory, and then execute<BR>> $ make run/verify<BR>> in 
build directory.<BR><BR>Unfortunately, I am not able to compile it. I get an 
error as follows:<BR><BR>  
/open/incoming/vsos/base/include/base/rpc_server.h:152:41: 
error:<BR>‘l4_utcb_id’ is not a member of ‘Fiasco’<BR><BR>The type 'l4_utcb_id' 
does not exist in the 'base-foc/contrib' source<BR>tree. It seems like you 
changed the kernel but invoking 'make prepare'<BR>within 'base-foc' fetches the 
original kernel.<BR><BR>Best regards<BR>Norman<BR><BR>-- <BR>Dr.-Ing. Norman 
Feske<BR>Genode Labs<BR><BR>http://www.genode-labs.com · 
http://genode.org<BR><BR>Genode Labs GmbH · Amtsgericht Dresden · HRB 28424 · 
Sitz Dresden<BR>Geschäftsführer: Dr.-Ing. Norman Feske, Christian 
Helmuth<BR><BR>------------------------------------------------------------------------------<BR>Slashdot 
TV.  <BR>Video for Nerds.  Stuff that 
matters.<BR>http://tv.slashdot.org/<BR>_______________________________________________<BR>genode-main 
mailing 
list<BR>genode-main@lists.sourceforge.net<BR>https://lists.sourceforge.net/lists/listinfo/genode-main<BR></DIV>
<P>
<HR>
------------------------------------------------------------------------------<BR>Slashdot 
TV.  <BR>Video for Nerds.  Stuff that 
matters.<BR>http://tv.slashdot.org/ 
<P>
<HR>
_______________________________________________<BR>genode-main mailing 
list<BR>genode-main@lists.sourceforge.net<BR>https://lists.sourceforge.net/lists/listinfo/genode-main<BR></DIV></DIV></DIV></BODY></HTML>