Message ID | 20190801183812.GA2805@ibm-toto.the-meissners.org |
---|---|
State | New |
Headers | show |
Series | [committed] Fix comment about pcrel_external_address | expand |
On Thu, Aug 01, 2019 at 02:38:12PM -0400, Michael Meissner wrote: > I committed this patch as 'obvious'. As I'm preparing the next round of future > PowerPC patches, I noticed I had a typo in the usage for the predicate > pcrel_external_address. > ;; Return true if the operand is an external symbol whose address can be loaded > ;; into a register using: > -;; PLA reg,label@pcrel@got > +;; PLD reg,label@pcrel@got Are you sure? pla reg,value loads "value" into reg pld reg,value loads the memory contents at address "value" into reg (both use pcrel addressing, so +CIA) pcrel_external_mem_operand does this extra indirection already? Segher
Index: gcc/config/rs6000/predicates.md =================================================================== --- gcc/config/rs6000/predicates.md (revision 273981) +++ gcc/config/rs6000/predicates.md (working copy) @@ -1656,7 +1656,7 @@ (define_predicate "pcrel_address" ;; Return true if the operand is an external symbol whose address can be loaded ;; into a register using: -;; PLA reg,label@pcrel@got +;; PLD reg,label@pcrel@got ;; ;; The linker will either optimize this to either a PADDI if the label is ;; defined locally in another module or a PLD of the address if the label is