GNU bug report logs -
#41615
[feature/native-comp] Dump prettier C code.
Previous Next
Full log
Message #20 received at 41615 <at> debbugs.gnu.org (full text, mbox):
Andrea Corallo <akrl <at> sdf.org> writes:
> Nicolas Bértolo <nicolasbertolo <at> gmail.com> writes:
>
>> I have reformatted the patches.
>>
>> Sorry for the inconveniences.
>>
>>
>> From 0720ec7eb3dc552b018273cd68a5f7d6bb2fdb72 Mon Sep 17 00:00:00 2001
>> From: =?UTF-8?q?Nicol=C3=A1s=20B=C3=A9rtolo?= <nicolasbertolo <at> gmail.com>
>> Date: Wed, 20 May 2020 00:34:32 -0300
>> Subject: [PATCH 1/2] Define static data using string literals.
>>
>> The purpose of this change is to dump prettier C files.
>> This does not affect compilation times in my tests.
>>
>> * src/comp.c (emit_static_object): Define static objects using string
>> literals, memcpy and bzero.
>> ---
>> src/comp.c | 295 +++++++++++++++++++++++++++++++++++++++++++++++++----
>> 1 file changed, 277 insertions(+), 18 deletions(-)
>
> I like this considerably less :)
>
> It introduces quite some complexity and the same advantage in
> debuggability can be achieved with something like the attached 8 line
> patch (untested).
>
> Generally speaking I want to try to keep our back-end as simple as we
> manage to.
>
> On the subject of 'emit_static_object' the current situation is not
> ideal. But rather that working around the workaround I believe the right
> thing to do is to improve GCC with a new entry point and keep the
> current arrangement as a simple fallback.
>
> I've already an half cooked GCC patch to allow for directly injecting
> blobs, this should have more then one advantage. Hopefully I manage to
> start testing it today, I'm rather curious.
>
> Andrea
Interesting news
I've boostraped the Emacs with my GCC with blob support and measured an
embarrassing low overall compile time.
Then I questioned my-self "why is Nico not seeing any compile time
benefit from his patch?"
So I boostraped "Define static data using string literals" measuring a
considerable improvement too. Is not as good as the one with specific
GCC blob support but still very beneficial.
Are you sure you do not see improvements in compile-time when this is
applied? If is not the case maybe your memcpy is inlined and unrolled,
but is quite strange that I do not see it here.
Andrea
--
akrl <at> sdf.org
This bug report was last modified 5 years and 39 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.