[PATCH] xtensa: Optimize stack frame adjustment more
Takayuki 'January June' Suwa
jjsuwa_sys3175@yahoo.co.jp
Sat Jan 7 02:54:50 GMT 2023
On 2023/01/06 17:05, Max Filippov wrote:
> On Thu, Jan 5, 2023 at 10:57 PM Takayuki 'January June' Suwa
> <jjsuwa_sys3175@yahoo.co.jp> wrote:
>> By using the helper function, it makes stack frame adjustment logic
>> simplified and instruction count less in some cases.
>
> I've built a couple linux configurations with and without this change and
> I observe consistent code size growth, e.g.:
>
> iss_defconfig without the change:
> text data bss dec hex filename
> 3014768 164016 115108 3293892 3242c4 vmlinux
>
> iss_defconfig with the change:
> text data bss dec hex filename
> 3015296 164008 115108 3294412 3244cc vmlinux
>
> virt_defconfig without the change:
> text data bss dec hex filename
> 5498881 2254360 291768 8045009 7ac1d1 vmlinux
>
> virt_defconfig with the change:
> text data bss dec hex filename
> 5500389 2254360 291768 8046517 7ac7b5 vmlinux
>
> generic_kc705_defconfig without the change:
> text data bss dec hex filename
> 7062530 635340 286400 7984270 79d48e vmlinux
>
> generic_kc705_defconfig with the change:
> text data bss dec hex filename
> 7064078 635340 286400 7985818 79da9a vmlinux
>
Probably due to this location:
> + else if (TARGET_DENSITY && optimize_size && xtensa_simm12b (imm))
^^^^^^^^^^^^^^^^
I omitted it in the new patch, so please check it.
More information about the Gcc-patches
mailing list