[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug gas/11509] New: Strange evaluation of symbol containing register
From: |
theorizer at freemail dot hu |
Subject: |
[Bug gas/11509] New: Strange evaluation of symbol containing register |
Date: |
16 Apr 2010 21:04:27 -0000 |
Assume the source below:
.intel_syntax noprefix
.eqv param, ebp-4
mov eax, [param]
mov eax, [param]
On this source 'as' (2.19, 2.20) assembles the following:
0: 8b 45 fc mov eax,DWORD PTR [ebp-0x4]
3: b8 fc ff ff ff mov eax,0xfffffffc
'as' 2.18 however assembles this here:
0: 8b 01 mov eax,DWORD PTR [ecx]
2: 8b 01 mov eax,DWORD PTR [ecx]
if you change the symbol definition line to
.eqv param, ebp
then the assembled code is already the same for both mov instructions (with any
'as' versions):
0: 8b 45 00 mov eax,DWORD PTR [ebp+0x0]
3: 8b 45 00 mov eax,DWORD PTR [ebp+0x0]
As I see it does not matter whether you apply .eqv, .equ, .equiv, or =. The
result is always the same.
--
Summary: Strange evaluation of symbol containing register
Product: binutils
Version: 2.20
Status: NEW
Severity: normal
Priority: P2
Component: gas
AssignedTo: unassigned at sources dot redhat dot com
ReportedBy: theorizer at freemail dot hu
CC: bug-binutils at gnu dot org
GCC build triplet: x86_64-gentoo-linux, x86_32-gentoo-linux, cygwin
GCC host triplet: x86_64-gentoo-linux, x86_32-gentoo-linux, cygwin
GCC target triplet: x86_64-gentoo-linux, x86_32-gentoo-linux, cygwin
http://sourceware.org/bugzilla/show_bug.cgi?id=11509
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
- [Bug gas/11509] New: Strange evaluation of symbol containing register,
theorizer at freemail dot hu <=