Because you used bx
in the effective address, the assembler thought you wanted a 16 bit address and hence generated 16 bit relocation that the linker was unhappy with. It probably wouldn't work in 32 bit mode anyway, since your variable is unlikely to be in the bottom 64k of the address space.
If you don't have any free registers maybe you can use the stack:
push ebx
mov bl, dl
;(other operations involving bx)
movzx ebx, bx
mov [pool+ebx], esi
pop ebx
You said only low 16 bits of ebx
were used. If that's the case for edx
as well, you can save dx
in the top 16 bits of ebx
, such as:
shl ebx, 16
mov bx, dx
;(other operations involving dx)
movzx edx, dx
mov [pool+edx], esi
mov dx, bx
shr ebx, 16
No, you can't save arbitrary values in segment registers.