[Nasm-bugs] [Bug 3392784] New: 'error: label `foo' changed during code generation' after masm-style storage defines
noreply-nasm at dev.nasm.us
noreply-nasm at dev.nasm.us
Sat Sep 18 10:21:21 PDT 2021
https://bugzilla.nasm.us/show_bug.cgi?id=3392784
Bug ID: 3392784
Summary: 'error: label `foo' changed during code generation'
after masm-style storage defines
Product: NASM
Version: 2.15.xx
Hardware: PC
OS: Linux
Status: OPEN
Severity: normal
Priority: Medium
Component: Assembler
Assignee: nobody at nasm.us
Reporter: russvz at comcast.net
CC: chang.seok.bae at intel.com, gorcunov at gmail.com,
hpa at zytor.com, nasm-bugs at nasm.us
Obtained from: Binary from nasm.us
When storage types are changed during masm-syntax storage defines in a struct,
the label of the following definition is flagged with 'label foo changed during
storage definition'. This happens even with this example from nasm's manual:
struc nasm3_2_2
buffer: db 64 dup (?)
wordvar: dw ?
realarray dq 10 dup (?)
ymmval: dy ?
zmmvals: dz 32 dup (?)
endstruc
receives error message:
error: label `realarray' changed during code generation
[-w+error=label-redef-late]
If wordvar is changed to the same type as the defs before it (db) then the
error message moves down to 'ymmval' because realarray is the first masm-syntax
change. If instead wordvar is defined nasm style (resw 1) the problem moves to
'ymmval' because only masm style definitions cause the problem (in this case
the define of realarray breaks ymmval).
This happens in standard nasm 2.15.05 with or without the masm package. I
encountered the problem in my own code, then reproduced with this example to
simplify.
--
You are receiving this mail because:
You are watching all bug changes.
You are on the CC list for the bug.
More information about the Nasm-bugs
mailing list