I am having difficulty with the RealView linker crashing when trying to link variables to absolute addresses above ~ 0x70000000. For example, here is three different methods I've tried (trying to achieve the same thing) that cause the linker to crash:
#include <absacc.h> // Crash Method 1 //#pragma arm section rwdata = ".ARM.__AT_0xE01FC040" //volatile unsigned long memmap; //#pragma arm section rwdata // Crash Method 2 //volatile __attribute__((section(".ARM.__AT_0xE01FC040"))) unsigned long memmap; // Crash Method 3 volatile unsigned long memmap __at (0xE01FC040); int main(void) { while(1); }
-thanks, Kevin
try it
int main() { #define memmap (*((volatile unsigned long *)0xE01FC040)); while(1); }
realview have no _at
Yes, I am aware that the preprocessor #define method works without crashing the linker. I would like however to define an absolute address variable without use of the preprocessor.
The RealView documentation states the use of _at, and it is defined in RealView's <absacc.h> header file, so I do think this is supposed to work? In fact, I'm almost certain it works correctly on addresses in the 0x40000000 range.
Even if this feature is not supported, the fact that 3 lines of code can cause a $4,000 "World Class" linker such as the RealView to completely crash is a little disconcerting....
Hi Kevin, I tried your snippet and it compiles and links fine. Are you using RV-MDK 3.10?
Ahh!?
No, I'm using version 3.0.0.951. I'll see about getting the latest version and giving that a try.
Thanks. Kevin
That did the trick! Thanks.