[adtools] baserel problems in GCC 4.4.4

  • From: Sebastian Bauer <mail@xxxxxxxxxxxxxxxxxxx>
  • To: adtools@xxxxxxxxxxxxx
  • Date: Tue, 20 Jul 2010 17:22:31 +0200

Hi,

I had some time to check whether baserel is working with GCC 4.4.4 in the
branches directory. Unfortunately, it isn't. The reason seems to be that
"elf_low" is preferred over "elf_base_low" as both have the same signature. In
the AmigaOS changes of rs6000.md I see following comments:

;; This needs to be above elf_high/elf_low since elf_base_low and elf_low
;; have the same instruction signature, so in some cases elf_low would be
;; generated instead of elf_base_low. Since the requirements for elf_base_low
;; are more restrictive than those for elf_low, there should be no problems
;; when determining which instruction to use.

It speaks about that the definition of elf_base_low precedes the definition of
elf_low in that file. As baserel is broken it means that this workaround no
longer seems to work (so much for the "should"). Unfortunately, I understand a
little of these definitions. But in addition to the plain signatures, there is
also a C condition which must be met in order to emit the assembler
instruction. For elf_base_low it is

TARGET_ELF && ! TARGET_64BIT && TARGET_BASEREL &&
amigaos_baserel_operand(operands[2])

while for elf_low it is

TARGET_ELF && ! TARGET_64BIT

So, both conditions overlap. How about changing elf_low such that the emit is
rejected if TARGET_BASEREL and operand(operands[2]) is met? (it hopefully
tries then the baserel case).

Bye,
Sebastian


-- 
______________________________________________________________________________
Amiga Development tools ML - //www.freelists.org/list/adtools
Homepage...................: http://www.sourceforge.net/projects/adtools
Listserver help............: mailto:adtools-request@xxxxxxxxxxxxx?Subject=HELP

Other related posts: