[Bug gas/26126] New: aarch64/mips: reject symbolic operand of an instruction taking an immediate operand

2020-06-16 Thread i at maskray dot me
https://sourceware.org/bugzilla/show_bug.cgi?id=26126

Bug ID: 26126
   Summary: aarch64/mips: reject symbolic operand of an
instruction taking an immediate operand
   Product: binutils
   Version: 2.35 (HEAD)
Status: UNCONFIRMED
  Severity: normal
  Priority: P2
 Component: gas
  Assignee: unassigned at sourceware dot org
  Reporter: i at maskray dot me
  Target Milestone: ---

Rigid:
% powerpc64le-linux-gnu-as <<< 'or 3, 3, start-.; start:'  # good
% powerpc64le-linux-gnu-as <<< 'or 3, 3, start; start:'
{standard input}: Assembler messages:
{standard input}:1: Error: unsupported relocation against .text

Permissive:

% aarch64-linux-gnu-as <<< 'orr w3, w3, start; start:'
# no relocation

% mipsel-linux-gnu-as <<< 'ori $3, $3, start; start:'
% llvm-objdump -dr
...
   0: 04 00 63 34   ori $3, $3, 4 
:  R_MIPS_LO16  .text

% mips64el-linux-gnuabi64-as <<< 'ori $3, $3, start; start:'  # succeeded
% llvm-objdump -dr
...
   0: 00 00 63 34   ori $3, $3, 0 <.text>
:  R_MIPS_LO16/R_MIPS_NONE/R_MIPS_NONE 
.text+0x4

On most RISC architectures, the immediate bits cannot encode an arbitrary
symbolic value (32-bit/64-bit). It probably makes sense rejecting assembling
the instruction.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug gas/26113] gas 2.34 hangs after compilation error

2020-06-16 Thread me at tbrindus dot ca
https://sourceware.org/bugzilla/show_bug.cgi?id=26113

--- Comment #2 from Tudor  ---
Thanks!

-- 
You are receiving this mail because:
You are on the CC list for the bug.