<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<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:Wingdings;
        panose-1:5 0 0 0 0 0 0 0 0 0;}
@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:0in;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
p.MsoListParagraph, li.MsoListParagraph, div.MsoListParagraph
        {mso-style-priority:34;
        margin-top:0in;
        margin-right:0in;
        margin-bottom:0in;
        margin-left:.5in;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
span.EmailStyle18
        {mso-style-type:personal-reply;
        font-family:"Calibri",sans-serif;
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri",sans-serif;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
/* List Definitions */
@list l0
        {mso-list-id:860878;
        mso-list-type:hybrid;
        mso-list-template-ids:508577824 67698703 67698713 67698715 67698703 67698713 67698715 67698703 67698713 67698715;}
@list l0:level1
        {mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;}
@list l0:level2
        {mso-level-number-format:alpha-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;}
@list l0:level3
        {mso-level-number-format:roman-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:right;
        text-indent:-9.0pt;}
@list l0:level4
        {mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;}
@list l0:level5
        {mso-level-number-format:alpha-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;}
@list l0:level6
        {mso-level-number-format:roman-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:right;
        text-indent:-9.0pt;}
@list l0:level7
        {mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;}
@list l0:level8
        {mso-level-number-format:alpha-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;}
@list l0:level9
        {mso-level-number-format:roman-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:right;
        text-indent:-9.0pt;}
@list l1
        {mso-list-id:1707632039;
        mso-list-type:hybrid;
        mso-list-template-ids:-1886228856 9962722 67698691 67698693 67698689 67698691 67698693 67698689 67698691 67698693;}
@list l1:level1
        {mso-level-number-format:bullet;
        mso-level-text:-;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;
        font-family:"Calibri",sans-serif;
        mso-fareast-font-family:Calibri;}
@list l1:level2
        {mso-level-number-format:bullet;
        mso-level-text:o;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;
        font-family:"Courier New";}
@list l1:level3
        {mso-level-number-format:bullet;
        mso-level-text:;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;
        font-family:Wingdings;}
@list l1:level4
        {mso-level-number-format:bullet;
        mso-level-text:;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;
        font-family:Symbol;}
@list l1:level5
        {mso-level-number-format:bullet;
        mso-level-text:o;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;
        font-family:"Courier New";}
@list l1:level6
        {mso-level-number-format:bullet;
        mso-level-text:;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;
        font-family:Wingdings;}
@list l1:level7
        {mso-level-number-format:bullet;
        mso-level-text:;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;
        font-family:Symbol;}
@list l1:level8
        {mso-level-number-format:bullet;
        mso-level-text:o;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;
        font-family:"Courier New";}
@list l1:level9
        {mso-level-number-format:bullet;
        mso-level-text:;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;
        font-family:Wingdings;}
ol
        {margin-bottom:0in;}
ul
        {margin-bottom:0in;}
--></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]-->
</head>
<body lang="EN-US" link="blue" vlink="purple" style="word-wrap:break-word">
<div class="WordSection1">
<p class="MsoNormal">I’ve just changed the optimization flags for rtems-tools, but I think I found where to go to change that.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Using the Xilinx_zynq_a9_qemu BSP for example<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<ul style="margin-top:0in" type="disc">
<li class="MsoListParagraph" style="margin-left:0in;mso-list:l1 level1 lfo2">Go to bsps/arm/xilinx-zynqmp/config/xilinx_zynqmp.inc<o:p></o:p></li><li class="MsoListParagraph" style="margin-left:0in;mso-list:l1 level1 lfo2">Change the “-O2” value to the different optimization flag in the CFLAGS_OPTIMIZE_V list<o:p></o:p></li></ul>
<p class="MsoNormal"><o:p> </o:p></p>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal" style="margin-left:.5in"><b>From:</b> Joel Sherrill <joel@rtems.org>
<br>
<b>Sent:</b> Tuesday, September 7, 2021 12:27 PM<br>
<b>To:</b> Mr. Andrei Chichak <groups@chichak.ca><br>
<b>Cc:</b> Ryan Long <ryan.long@oarcorp.com>; rtems-devel@rtems.org <devel@rtems.org><br>
<b>Subject:</b> Re: [PATCH RSB] rtems-gcc-10-newlib-head.cfg: Add newlib patch<o:p></o:p></p>
</div>
<p class="MsoNormal" style="margin-left:.5in"><o:p> </o:p></p>
<div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:0in;margin-right:0in;margin-bottom:12.0pt;margin-left:.5in">
<o:p> </o:p></p>
<div>
<div>
<p class="MsoNormal" style="margin-left:.5in">On Tue, Sep 7, 2021, 12:18 PM Mr. Andrei Chichak <<a href="mailto:groups@chichak.ca">groups@chichak.ca</a>> wrote:<o:p></o:p></p>
</div>
<blockquote style="border:none;border-left:solid #CCCCCC 1.0pt;padding:0in 0in 0in 6.0pt;margin-left:4.8pt;margin-right:0in">
<p class="MsoNormal" style="margin-left:.5in">Hey Joel,<br>
<br>
I don’t suppose this update will be in the places where the build system decides on the instruction set that newlib uses for Cortex-M4????<o:p></o:p></p>
</blockquote>
</div>
</div>
<div>
<p class="MsoNormal" style="margin-left:.5in"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal" style="margin-left:.5in">No. This one is just to patch over a big in some of the aarch64 assembly language methods in newlib.<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="margin-left:.5in"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal" style="margin-left:.5in">I don't know that it does much as a flag except pick the C versions over assembly language ones.<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="margin-left:.5in"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal" style="margin-left:.5in">You'd be better off trying to change the target gcc flags to -Os. I think Ryan knows how to do that. Chris can answer that also <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="margin-left:.5in"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal" style="margin-left:.5in">It is a shame that AFAIK every multilib gets the same optimisation flags and macros  some of the smaller parts would be better off defaulting to size over speed.<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="margin-left:.5in"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal" style="margin-left:.5in">--joel<o:p></o:p></p>
</div>
<div>
<div>
<blockquote style="border:none;border-left:solid #CCCCCC 1.0pt;padding:0in 0in 0in 6.0pt;margin-left:4.8pt;margin-right:0in">
<p class="MsoNormal" style="mso-margin-top-alt:0in;margin-right:0in;margin-bottom:12.0pt;margin-left:.5in">
<br>
A<br>
<br>
> On 2021-September-07, at 08:56, Joel Sherrill <<a href="mailto:joel@rtems.org" target="_blank">joel@rtems.org</a>> wrote:<br>
> <br>
> On Tue, Sep 7, 2021 at 8:04 AM Ryan Long <<a href="mailto:ryan.long@oarcorp.com" target="_blank">ryan.long@oarcorp.com</a>> wrote:<br>
>> <br>
>> Alright, I’ll have that in the next version.<br>
> <br>
> I have a patch ready for this and already posted. Just ran out of disk space<br>
> testing it on all architectures on CentOS.<br>
> <br>
> When that build finishes, unless someone complains, I will push it.<br>
> <br>
> --joel<br>
> <br>
> <br>
>> <br>
>> <br>
>> From: Joel Sherrill <<a href="mailto:joel@rtems.org" target="_blank">joel@rtems.org</a>><br>
>> Sent: Saturday, September 4, 2021 3:31 PM<br>
>> To: Chris Johns <<a href="mailto:chrisj@rtems.org" target="_blank">chrisj@rtems.org</a>><br>
>> Cc: Ryan Long <<a href="mailto:ryan.long@oarcorp.com" target="_blank">ryan.long@oarcorp.com</a>>;
<a href="mailto:rtems-devel@rtems.org" target="_blank">rtems-devel@rtems.org</a> <<a href="mailto:devel@rtems.org" target="_blank">devel@rtems.org</a>><br>
>> Subject: Re: [PATCH RSB] rtems-gcc-10-newlib-head.cfg: Add newlib patch<br>
>> <br>
>> <br>
>> <br>
>> <br>
>> <br>
>> On Fri, Sep 3, 2021, 9:05 PM Chris Johns <<a href="mailto:chrisj@rtems.org" target="_blank">chrisj@rtems.org</a>> wrote:<br>
>> <br>
>> Can we please join onto this an rtems-tools update so the recent fixes I pushed<br>
>> can be picked up?<br>
>> <br>
>> <br>
>> <br>
>> Ryan can you make that a second patch in this series?<br>
>> <br>
>> <br>
>> <br>
>> --joel<br>
>> <br>
>> <br>
>> Thanks<br>
>> Chris<br>
>> <br>
>> On 4/9/21 2:40 am, Joel Sherrill wrote:<br>
>>> You also should add the patch in the gcc-head-newlib-head<br>
>>> configuration as well for rtems7 tools.<br>
>>> <br>
>>> --joel<br>
>>> <br>
>>> On Fri, Sep 3, 2021 at 11:01 AM Joel Sherrill <<a href="mailto:joel@rtems.org" target="_blank">joel@rtems.org</a>> wrote:<br>
>>>> <br>
>>>> On Fri, Sep 3, 2021 at 9:27 AM Ryan Long <<a href="mailto:ryan.long@oarcorp.com" target="_blank">ryan.long@oarcorp.com</a>> wrote:<br>
>>>>> <br>
>>>>> Adds patch to add the -DPREFER_SIZE_OVER_SPEED flag to aarch64 tool<br>
>>>>> builds with newlib.<br>
>>>> <br>
>>>> This doesn't explain why. This patch is needed to prevent the use of<br>
>>>> the assembly<br>
>>>> versions of some methods in newlib which are incorrect for ilp32. This<br>
>>>> can be removed<br>
>>>> when those methods are updated from ARM. Newlib is quite behind ARM for these<br>
>>>> methods and that will require work from an ARM Newlib person.<br>
>>>> <br>
>>>> Updates #4215,<br>
>>>> <br>
>>>> Improve the comment and ensure the ticket is clear that this is temporary for<br>
>>>> those reasons.<br>
>>>> <br>
>>>>> ---<br>
>>>>> rtems/config/tools/rtems-gcc-10-newlib-head.cfg | 3 +++<br>
>>>>> 1 file changed, 3 insertions(+)<br>
>>>>> <br>
>>>>> diff --git a/rtems/config/tools/rtems-gcc-10-newlib-head.cfg b/rtems/config/tools/rtems-gcc-10-newlib-head.cfg<br>
>>>>> index 69c4fb5..3594d1c 100644<br>
>>>>> --- a/rtems/config/tools/rtems-gcc-10-newlib-head.cfg<br>
>>>>> +++ b/rtems/config/tools/rtems-gcc-10-newlib-head.cfg<br>
>>>>> @@ -13,6 +13,9 @@<br>
>>>>> %patch add gcc -p1 <a href="https://devel.rtems.org/raw-attachment/ticket/4215/0001-nios2-Remove-custom-instruction-warnings.patch" target="_blank">
https://devel.rtems.org/raw-attachment/ticket/4215/0001-nios2-Remove-custom-instruction-warnings.patch</a><br>
>>>>> %hash sha512 0001-nios2-Remove-custom-instruction-warnings.patch afd8a5e6bdcc5b75d5fbbf558bdf56ccac400521a6eec9d88cc95f6be67c481f2dbf8faa0f6ddc1e4ac7c56a84938714d80e46e9cf80ec4b8fcd739986449881<br>
>>>>> <br>
>>>>> +%patch add newlib -p1 <a href="https://devel.rtems.org/raw-attachment/ticket/4510/0001-configure.host-Add-DPREFER_SIZE_OVER_SPEED.patch" target="_blank">
https://devel.rtems.org/raw-attachment/ticket/4510/0001-configure.host-Add-DPREFER_SIZE_OVER_SPEED.patch</a><br>
>>>>> +%hash sha512 0001-configure.host-Add-DPREFER_SIZE_OVER_SPEED.patch ad183b6c9a168d1d751505e64873f117c11fb059819d341c5d715619985b285c324ef27c1177c6300088df7bbe3aebd7fa034034c3892f2bf6ec57324c9b1e2a<br>
>>>>> +<br>
>>>> <br>
>>>> Looks like you forgot to use sha512-base64<br>
>>>> <br>
>>>> <br>
>>>>> %define newlib_version 4f81149<br>
>>>>> %define newlib_external 1<br>
>>>>> %define newlib_expand_name sourceware-mirror-newlib-cygwin-%{newlib_version}<br>
>>>>> --<br>
>>>>> 1.8.3.1<br>
>>>>> <br>
>>>>> _______________________________________________<br>
>>>>> devel mailing list<br>
>>>>> <a href="mailto:devel@rtems.org" target="_blank">devel@rtems.org</a><br>
>>>>> <a href="http://lists.rtems.org/mailman/listinfo/devel" target="_blank">http://lists.rtems.org/mailman/listinfo/devel</a><br>
>>> _______________________________________________<br>
>>> devel mailing list<br>
>>> <a href="mailto:devel@rtems.org" target="_blank">devel@rtems.org</a><br>
>>> <a href="http://lists.rtems.org/mailman/listinfo/devel" target="_blank">http://lists.rtems.org/mailman/listinfo/devel</a><br>
>>> <br>
> _______________________________________________<br>
> devel mailing list<br>
> <a href="mailto:devel@rtems.org" target="_blank">devel@rtems.org</a><br>
> <a href="http://lists.rtems.org/mailman/listinfo/devel" target="_blank">http://lists.rtems.org/mailman/listinfo/devel</a><br>
<br>
<o:p></o:p></p>
</blockquote>
</div>
</div>
</div>
</div>
</body>
</html>