avr-libc-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[avr-libc-dev] [bug #28921] pointer to function > 128k flash


From: Stefan Ernst
Subject: [avr-libc-dev] [bug #28921] pointer to function > 128k flash
Date: Sat, 20 Feb 2010 12:03:34 +0000
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.9.2) Gecko/20100115 Firefox/3.6 (.NET CLR 3.5.30729)

Follow-up Comment #3, bug #28921 (project avr-libc):

> Now, just one more little request: When I pass the pointer to
> a task function to the FreeRTOS task creation routine, gcc passes
> passes a 16-bit pointer, as I expect. Unfortunately, there is
> not a direct "function pointer" reference to the task function,
> so the linker has no need to put the task into the trampoline
> (or, more to the point, it has no need to keep it there). 

The point the trampoline is generated and used is where the linker tries to
assign an address bigger than 16 bit to a 16 bit symbol. It doesn't matter
what type this symbol had in the C code.
Example:

void SomeFunc (void) {
}
...
uint16_t adr = (uint16_t)SomeFunc;

If SomeFunc is located above 128k, then there will be a trampoline for it and
adr will contain the word address of that trampoline.

    _______________________________________________________

Reply to this item at:

  <http://savannah.nongnu.org/bugs/?28921>

_______________________________________________
  Nachricht geschickt von/durch Savannah
  http://savannah.nongnu.org/





reply via email to

[Prev in Thread] Current Thread [Next in Thread]