🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.gcc.help
Article #50584

Wierd use of registers in gcc 2.4.5

#50584
From: David Alan Gilbert
Date: Wed, 15 Sep 1993 08:11
32 lines
2025 bytes
gcc-2.4.5 is producing this very strange piece of RTL (seen in the jump2 output file)
It is moving R6 into R5 and then storing R5.  This obviously causes a dependancy
between the move and the store. Surely gcc should always use the oldest equivalent
registers so as to prevent this type of thing? (any solutions??)

On another point, how can I get more information from 'movstrsi' - does the si
actually imply alignment of the source operand?  There is only one alignment
value passed and it would be useful if both were passed since it would be
possible to call a different memcpy routine if alignment were known
on even one of the parameters.

Also the manual says movstrsi neednt give 'special consideration to the possibility that
the source and destination strings might overlap' - is this implying gcc checks during
compilation - how does it know that they dont overlap??


Dave

(insn 703 704 705 (set (reg/v:SI 5 r5)
        (reg/v:SI 6 r6)) 61 {movsi} (insn_list:REG_DEP_ANTI 702 (nil))
    (nil))

(insn 705 703 706 (set (mem:SI (reg:SI 0 r0))
        (reg/v:SI 5 r5)) 61 {movsi} (insn_list:REG_DEP_ANTI 702 (insn_list 703 (
insn_list 704 (nil))))
    (expr_list:REG_DEAD (reg:SI 0 r0)
        (nil)))

--
-------------------------------------------------------------------------------
- David Alan Gilbert - gilbertd@cs.man.ac.uk - G7FHJ@GB7CRG                   -
------(Programmers don't sleep - they just park their heads)-------------------
Technical Details
Message-ID: <gilbertd.748080706@cs.man.ac.uk>
Path: arc1-ca.pugleaf.net!gmd.de!newsserver.jvnc.net!howland.reston.ans.net!europa.eng.gtefsd.com!uunet!pipex!uknet!mucs!cs.man.ac.uk!gilbertd

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 11318c,bf2af39dcbcb50fe,start
X-Google-Attributes: gid11318c,public
X-Google-ArrivalTime: 1993-09-15 17:39:59 PST
Path: arc1-ca.pugleaf.net!gmd.de!newsserver.jvnc.net!howland.reston.ans.net!europa.eng.gtefsd.com!uunet!pipex!uknet!mucs!cs.man.ac.uk!gilbertd
From: gilbertd@cs.man.ac.uk (David Alan Gilbert)
Newsgroups: gnu.gcc.help
Subject: Wierd use of registers in gcc 2.4.5
Message-ID: <gilbertd.748080706@cs.man.ac.uk>
Date: 15 Sep 93 08:11:46 GMT
Sender: news@cs.man.ac.uk
Lines: 32