Re: Error: attempt to get value of unresolved symbol `L0'

2022-10-16 Thread Pali Rohár via Gcc
On Tuesday 11 October 2022 19:07:55 Pali Rohár wrote: > On Tuesday 11 October 2022 15:33:59 Nick Clifton wrote: > > Hi Pali, Hi Richard, > > > > > Having file name and line number would be also useful as it took me > > > some time to figure out where is the issue... > > > > Right - I have tried

Re: Error: attempt to get value of unresolved symbol `L0'

2022-10-11 Thread Pali Rohár via Gcc
On Tuesday 11 October 2022 15:33:59 Nick Clifton wrote: > Hi Pali, Hi Richard, > > > Having file name and line number would be also useful as it took me > > some time to figure out where is the issue... > > Right - I have tried a little harder and come up with a follow up patch. > This is now

Re: Error: attempt to get value of unresolved symbol `L0'

2022-10-11 Thread Nick Clifton via Gcc
Hi Pali, Hi Richard, Having file name and line number would be also useful as it took me some time to figure out where is the issue... Right - I have tried a little harder and come up with a follow up patch. This is now checked in, and given an input file that looks like this: % cat t.s

Re: Error: attempt to get value of unresolved symbol `L0'

2022-10-11 Thread Pali Rohár via Gcc
... > But just for reference the following would work: > > .word KERNEL_OFFSET + CONFIG_SYS_TEXT_BASE - . > > > I agree however that this message: > > t.s: Error: attempt to get value of unresolved symbol `L0' > > is unhelpful. So I am going to che

Re: Error: attempt to get value of unresolved symbol `L0'

2022-10-11 Thread Richard Biener via Gcc
the KERNEL_OFFSET and CONFIG_SYS_TEXT_BASE values are known at assembly > time. > > A clever assembler might be able to rearrange the expression, assuming that > overflow is unimportant, but gas does not do that. But just for reference > the following would work: > > .word KER

Re: Error: attempt to get value of unresolved symbol `L0'

2022-10-11 Thread Nick Clifton via Gcc
would work: .word KERNEL_OFFSET + CONFIG_SYS_TEXT_BASE - . I agree however that this message: t.s: Error: attempt to get value of unresolved symbol `L0' is unhelpful. So I am going to check in a patch to change it to: t.s: Error: expression is too complex to be resolved I

Re: Error: attempt to get value of unresolved symbol `L0'

2022-10-11 Thread Pali Rohár via Gcc
FIG_SYS_TEXT_BASE=0x80008000 -pipe -c test.S > > {standard input}: Assembler messages: > > {standard input}: Error: attempt to get value of unresolved symbol `L0' > > > > I do not use any L0 symbol in the code, so error message seems to be > > incorrect. And also I do

Re: Error: attempt to get value of unresolved symbol `L0'

2022-10-11 Thread Richard Biener via Gcc
t: > > $ cat test.S > kernoffs: > .word KERNEL_OFFSET - (. - CONFIG_SYS_TEXT_BASE) > > $ arm-linux-gnueabi-gcc -DKERNEL_OFFSET=0x4 > -DCONFIG_SYS_TEXT_BASE=0x80008000 -pipe -c test.S > {standard input}: Assembler messages: > {standard input}: Error: attempt to get

Error: attempt to get value of unresolved symbol `L0'

2022-10-10 Thread Pali Rohár via Gcc
-gcc -DKERNEL_OFFSET=0x4 -DCONFIG_SYS_TEXT_BASE=0x80008000 -pipe -c test.S {standard input}: Assembler messages: {standard input}: Error: attempt to get value of unresolved symbol `L0' I do not use any L0 symbol in the code, so error message seems to be incorrect. And also I do not think