<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
<p>Hello Fabricio,</p>
<p>please note that sis does not try to run simulation synchronously
with 'wall time', it executes the application as fast as it can.
That does not mean that the simulation is not accurate -
instruction timing is fairly accurate for erc32 (+- 5%), while for
leon2/3 roughly +-25%. The time within the simulator (as visible
to the execute application) is accurate, but simulator time might
run faster or slower to wall time depending on target architecture
and the emulated frequency set with -freq. Application with low
cpu utilization (e.g ticker.exe) will run significantly faster
than wall time since the simulator can skip time forward when the
cpu is in power-down waiting for next interrupt. Applications with
high load (e.g dhrystone) will run slower. The 'perf' command will
report various simulation statistics.<br>
</p>
<p>To run simulation in step with wall time, sis would need to
periodically compare wall time with simulated time and pause
briefly if the simulator time exceeded wall time. I will consider
this as an option for a future sis version. Right now, I am trying
to speed up execution further by caching pre-decoded instructions,
coupled with (simple) dynamic translation for x64 ...<br>
</p>
<p>Jiri.<br>
</p>
<div class="moz-cite-prefix">On 8/7/20 6:40 PM, Fabrício de Novaes
Kucinskis wrote:<br>
</div>
<blockquote type="cite"
cite="mid:004501d66cd9$7ded1200$79c73600$@inpe.br">
<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:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
p.msonormal0, li.msonormal0, div.msonormal0
{mso-style-name:msonormal;
mso-margin-top-alt:auto;
margin-right:0cm;
mso-margin-bottom-alt:auto;
margin-left:0cm;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}
span.EstiloDeEmail18
{mso-style-type:personal;
font-family:"Calibri",sans-serif;
color:windowtext;}
span.EstiloDeEmail19
{mso-style-type:personal-compose;
font-family:"Calibri",sans-serif;
color:windowtext;}
.MsoChpDefault
{mso-style-type:export-only;
font-family:"Calibri",sans-serif;
mso-fareast-language:EN-US;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:70.85pt 3.0cm 70.85pt 3.0cm;}
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]-->
<div class="WordSection1">
<p class="MsoNormal"><span style="mso-fareast-language:EN-US"
lang="EN-US">Thanks for the response, Joel! Hope you’re
fine.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-US"
lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-US"
lang="EN-US">It’s been a while since I've used SIS paying
attention to its timing. I'm trying it now to make some
activities possible at home office, because I’m not allowed
to bring lab equipment home :(.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-US"
lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-US"
lang="EN-US">I've recovered some virtual machines we have
with previous versions of RTEMS (and hence, SIS), and
noticed that:<o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-US"
lang="EN-US"> * SIS 2.7.5 for RTEMS 4.10 had
its timing "correct", or else, one simulated second is near
one second;<o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-US"
lang="EN-US"> * SIS 2.8 for RTEMS 4.11 runs
the same application super-fast, as does the current SIS
2.21 for RTEMS 5.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-US"
lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-US"
lang="EN-US">So, it seems that something has changed between
versions 2.7.5 and 2.8. As I've stated before, set the
"freq" parameter seems to have no effect.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-US"
lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-US"
lang="EN-US">Maybe Jiri - long time no write! - can say if
there's a way to get the same "old 2.7.5" timing behavior on
the current version?<o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-US"
lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-US"
lang="EN-US">Thanks again and best regards,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-US"
lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-US"
lang="EN-US">Fabrício.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-US"
lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><b>De:</b> Joel Sherrill
[<a class="moz-txt-link-freetext" href="mailto:joel@rtems.org">mailto:joel@rtems.org</a>] <br>
<b>Enviada em:</b> sexta-feira, 7 de agosto de 2020 11:31<br>
<b>Para:</b> Fabrício de Novaes Kucinskis
<a class="moz-txt-link-rfc2396E" href="mailto:fabricio.kucinskis@inpe.br"><fabricio.kucinskis@inpe.br></a>; Jiri Gaisler
<a class="moz-txt-link-rfc2396E" href="mailto:jiri@gaisler.se"><jiri@gaisler.se></a><br>
<b>Cc:</b> RTEMS Users <a class="moz-txt-link-rfc2396E" href="mailto:rtems-users@rtems.org"><rtems-users@rtems.org></a><br>
<b>Assunto:</b> Re: Question about SIS for RTEMS 5 and timing<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<div>
<p class="MsoNormal">On Thu, Aug 6, 2020 at 3:54 PM
Fabrício de Novaes Kucinskis <<a
href="mailto:fabricio.kucinskis@inpe.br"
moz-do-not-send="true">fabricio.kucinskis@inpe.br</a>>
wrote:<o:p></o:p></p>
</div>
<blockquote style="border:none;border-left:solid #CCCCCC
1.0pt;padding:0cm 0cm 0cm
6.0pt;margin-left:4.8pt;margin-right:0cm">
<div>
<div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span
lang="EN-US">Hello all, I hope everyone on the
list is health and safe.</span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span
lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span
lang="EN-US">I’m studying the update of a SPARC
project, currently based on RTEMS 4.11, to RTEMS
5.</span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span
lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span
lang="EN-US">After installing RTEMS 5, the first
thing I did was compile and run, on SIS, a set of
example applications.</span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span
lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span
lang="EN-US">When calling sparc-rtems5-sis, I
noticed that the loaded application run fast as
hell, as SIS was just calling one instruction
after the other, with no timing concerns –
different from what I saw on older versions.</span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span
lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span
lang="EN-US">I’ve tried to set the frequency with
the “-freq” parameter, but this makes no
difference. I also checked the RTEMS SPARC BSP
sources, and the CLOCK_SPEED definition inside the
trap table is still set to 10, as ever.</span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span
lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span
lang="EN-US">Can anyone say what is different
between the previous and current SIS versions, and
how can I make the applications run with a
reasonable timing?</span><o:p></o:p></p>
</div>
</div>
</blockquote>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">AFAIK sis is cycle accurate for the
instructions inside its simulated world. But the erc32
is VERY slow compared to the host processor and
simulated code runs incredibly fast. 1 second of erc32
CPU time takes much less time to simulate.<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">There is a perf command in sis to get
the view of the simulated CPU time.<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">I've cc'ed Jiri so he can add
anything.<o:p></o:p></p>
</div>
<blockquote style="border:none;border-left:solid #CCCCCC
1.0pt;padding:0cm 0cm 0cm
6.0pt;margin-left:4.8pt;margin-right:0cm">
<div>
<div>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span
lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span
lang="EN-US">Thanks in advance and best regards,</span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span
lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal"
style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span
lang="EN-US">Fabrício.</span><o:p></o:p></p>
</div>
</div>
<p class="MsoNormal">_______________________________________________<br>
users mailing list<br>
<a href="mailto:users@rtems.org" target="_blank"
moz-do-not-send="true">users@rtems.org</a><br>
<a href="http://lists.rtems.org/mailman/listinfo/users"
target="_blank" moz-do-not-send="true">http://lists.rtems.org/mailman/listinfo/users</a><o:p></o:p></p>
</blockquote>
</div>
</div>
</div>
</blockquote>
</body>
</html>