git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@228 35acf78f-673a-0410-8e92-d51de3d6d3f4

This commit is contained in:
gdisirio 2008-03-12 21:05:13 +00:00
parent d76f6bff4f
commit 777291ac8a
12 changed files with 17 additions and 14 deletions

View File

@ -101,7 +101,7 @@ TOPT = -mthumb -D THUMB
# chconf.h.
# NOTE: -falign-functions=16 may improve the performance, not always, but
# increases the code size.
OPT = -O2 -ggdb -fomit-frame-pointer -fno-strict-aliasing
OPT = -O2 -ggdb -fomit-frame-pointer
#OPT += -ffixed-r7
#OPT += -falign-functions=16

View File

@ -101,7 +101,7 @@ TOPT = -mthumb -D THUMB
# chconf.h.
# NOTE: -falign-functions=16 may improve the performance, not always, but
# increases the code size.
OPT = -Os -ggdb -fomit-frame-pointer -fno-strict-aliasing
OPT = -Os -ggdb -fomit-frame-pointer
#OPT += -ffixed-r7
#OPT += -falign-functions=16

View File

@ -99,7 +99,7 @@ TOPT = -mthumb -D THUMB
# chconf.h.
# NOTE: -falign-functions=16 may improve the performance, not always, but
# increases the code size.
OPT = -O2 -ggdb -fomit-frame-pointer -fno-strict-aliasing
OPT = -O2 -ggdb -fomit-frame-pointer
#OPT += -ffixed-r7
OPT += -falign-functions=16

View File

@ -99,7 +99,7 @@ TOPT = -mthumb -D THUMB
# chconf.h.
# NOTE: -falign-functions=16 may improve the performance, not always, but
# increases the code size.
OPT = -Os -ggdb -fomit-frame-pointer -fno-strict-aliasing
OPT = -Os -ggdb -fomit-frame-pointer
#OPT += -ffixed-r7
OPT += -falign-functions=16

View File

@ -102,7 +102,7 @@ TOPT = -mthumb -D THUMB
# chconf.h.
# NOTE: -falign-functions=16 may improve the performance, not always, but
# increases the code size.
OPT = -O2 -ggdb -fomit-frame-pointer -fno-strict-aliasing
OPT = -O2 -ggdb -fomit-frame-pointer
#OPT += -ffixed-r7
OPT += -falign-functions=16

View File

@ -161,7 +161,7 @@ CFLAGS += -funsigned-char
CFLAGS += -funsigned-bitfields
CFLAGS += -fpack-struct
CFLAGS += -fshort-enums
CFLAGS += -fno-strict-aliasing
#CFLAGS += -fno-strict-aliasing
CFLAGS += -Wall
CFLAGS += -Wstrict-prototypes
#CFLAGS += -mshort-calls

View File

@ -161,7 +161,7 @@ CFLAGS += -funsigned-char
CFLAGS += -funsigned-bitfields
CFLAGS += -fpack-struct
CFLAGS += -fshort-enums
CFLAGS += -fno-strict-aliasing
#CFLAGS += -fno-strict-aliasing
CFLAGS += -Wall
CFLAGS += -Wstrict-prototypes
#CFLAGS += -mshort-calls

View File

@ -76,7 +76,7 @@ ULIBDIR =
ULIBS =
# Define optimisation level here
OPT = -Os -fomit-frame-pointer -fno-strict-aliasing
OPT = -Os -fomit-frame-pointer
#
# End of user defines

View File

@ -66,6 +66,9 @@ AVR-AT90CANx-GCC - Port on AVR AT90CAN128, not tested on hardware yet.
- Nice scheduler speed improvement obtained by removing the 2nd parameter to
the chSchReadyI() API and manually assigning the message value only where
is really needed (very few points in the code).
- Huge space saving and speed improvement obtained by removing the
-fno-strict-aliasing option from the makefiles, now the kernel compiles
without any warning without this option.
- Removed the -falign-functions=16 option from the AT91SAM7X demo makefiles,
the Atmel chip does not require it, the option is still present on the
LPC21xx demos. This saves significant ROM space.

View File

@ -32,7 +32,7 @@ DeltaList dlist;
*/
void chVTInit(void) {
dlist.dl_next = dlist.dl_prev = (VirtualTimer *)&dlist;
dlist.dl_next = dlist.dl_prev = (void *)&dlist;
dlist.dl_dtime = (systime_t)-1;
}
@ -64,7 +64,7 @@ void chVTSetI(VirtualTimer *vtp, systime_t time, vtfunc_t vtfunc, void *par) {
vtp->vt_prev = (vtp->vt_next = p)->vt_prev;
vtp->vt_prev->vt_next = p->vt_prev = vtp;
vtp->vt_dtime = time;
if (p != (VirtualTimer *)&dlist)
if (p != (void *)&dlist)
p->vt_dtime -= time;
}
else
@ -79,7 +79,7 @@ void chVTSetI(VirtualTimer *vtp, systime_t time, vtfunc_t vtfunc, void *par) {
*/
void chVTResetI(VirtualTimer *vtp) {
if (vtp->vt_next != (VirtualTimer *)&dlist)
if (vtp->vt_next != (void *)&dlist)
vtp->vt_next->vt_dtime += vtp->vt_dtime;
vtp->vt_prev->vt_next = vtp->vt_next;
vtp->vt_next->vt_prev = vtp->vt_prev;

View File

@ -76,7 +76,7 @@ extern DeltaList dlist;
while (!(vtp = dlist.dl_next)->vt_dtime) { \
vtfunc_t fn = vtp->vt_func; \
vtp->vt_func = 0; \
(vtp->vt_next->vt_prev = (VirtualTimer *)&dlist)->vt_next = vtp->vt_next; \
(vtp->vt_next->vt_prev = (void *)&dlist)->vt_next = vtp->vt_next; \
fn(vtp->vt_par); \
} \
}

View File

@ -61,7 +61,7 @@ typedef struct EventSource {
* @note Can be called with interrupts disabled or enabled.
*/
#define chEvtInit(esp) \
((esp)->es_next = (EventListener *)(esp))
((esp)->es_next = (void *)(esp))
/**
* Verifies if there is at least one \p EventListener registered on the
@ -70,7 +70,7 @@ typedef struct EventSource {
* @note Can be called with interrupts disabled or enabled.
*/
#define chEvtIsListening(esp) \
((esp) != (EventSource *)(esp)->es_next)
((esp) != (void *)(esp)->es_next)
/** Event Handler callback function.*/