[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Chicken-hackers] [PATCH] Simplify forwarding pointer wrapping and unwra
From: |
Peter Bex |
Subject: |
[Chicken-hackers] [PATCH] Simplify forwarding pointer wrapping and unwrapping |
Date: |
Sun, 2 Jul 2017 19:59:54 +0200 |
User-agent: |
NeoMutt/20170113 (1.7.2) |
Hi all,
While looking at the GC bug I already posted a patch for, I noticed that
forwarding pointers are constructed in a bit of a roundabout way, and
this could be simplified purely for readability reasons.
I tested the attached patch on x86_64 as well as 32-bit PowerPC and
nothing breaks. Unfortunately, it doesn't make any difference in
performance - I had hoped GCs would be sped up a bit due to less
instructions being needed to create the forwarding pointers.
In case you're wondering if there's a reason for why it's done in the
way it's done, we can check the original commit in which it changed
from a simple setting of the top bit to the current code:
cvs -d:pserver:anonymous:@cvs.sv.nongnu.org:/cvsroot/chicken rlog -r1.55
chicken/runtime.c
cvs -d:pserver:anonymous:@cvs.sv.nongnu.org:/cvsroot/chicken rdiff -r1.55
chicken/runtime.c
I also added a comment to the code to (hopefully) clarify what's going
on in these macros.
Cheers,
Peter
0001-Simplify-forwarding-pointer-wrapping-unwrapping.patch
Description: Text Data
signature.asc
Description: PGP signature
- [Chicken-hackers] [PATCH] Simplify forwarding pointer wrapping and unwrapping,
Peter Bex <=