This is the mail archive of the
mailing list for the GCC project.
tracking pointers in hardware
- From: Yoav Etsion <etsman at gmail dot com>
- To: gcc at gcc dot gnu dot org
- Date: Wed, 01 Mar 2006 11:41:43 +0200
- Subject: tracking pointers in hardware
- Reply-to: etsman at cs dot huji dot ac dot il
I'm designing a new hardware that needs to know which GPR contains a
simple integer, and which contained pointer. The hardware simply needs
different load operations for both (we're talking load/store machines,
with no indirect addressing to make life easier).
From the compiler's perspective, all it needs is to annotate load
operations to tell the hardware if this is a pointer or an integer (say
LD for integers and PLD for pointers).
As far as I can see, this data is not available in the final RTL stage:
the RTL contains some pointer data about virtual registers at first, but
it seems this data gets lost during optimizations, and mainly during the
Do any of you guys have suggestions how to implement it as part of gcc?
My only idea for now is to add an RTL pass just before the final pass
tracking dataflow to find which registers are used as addresses in
loads/stores (but this can probably be done by dataflow tracking