I created a small module in assembler for ARM, to be linked together with my bare-metal embedded application. Sometimes when I'm rebuilding the application, I get a "Error[Lp002]: relocation failed: valued out of range or illegal". What is even more puzzling is that I'm getting the error after commenting out some code in a C module.
The IAR manual is vague about 're-ordering the section or the code.' But looking at the assembler files generated by the compiler from my .c files, I see no difference between their section declaration and mine. I actually started my code by stubbing it out in C then taking over the assembled file.