forked from len0rd/rockbox
Fix (hopefully) last aliasing bug (midiutil), and enable -fno-strict-aliasing again for zxbox and doom (no easy fix there)
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25889 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
91249a5c7d
commit
7a994c1e7d
3 changed files with 5 additions and 5 deletions
|
@ -19,7 +19,7 @@ DOOM_OBJ := $(call c2obj, $(DOOM_SRC))
|
||||||
# add source files to OTHER_SRC to get automatic dependencies
|
# add source files to OTHER_SRC to get automatic dependencies
|
||||||
OTHER_SRC += $(DOOM_SRC)
|
OTHER_SRC += $(DOOM_SRC)
|
||||||
|
|
||||||
DOOMCFLAGS = $(PLUGINFLAGS) -Wno-strict-prototypes -O2
|
DOOMCFLAGS = $(PLUGINFLAGS) -Wno-strict-prototypes -O2 -fno-strict-aliasing
|
||||||
|
|
||||||
ifndef SIMVER
|
ifndef SIMVER
|
||||||
ifeq ($(TARGET), IRIVER_H100)
|
ifeq ($(TARGET), IRIVER_H100)
|
||||||
|
|
|
@ -40,7 +40,7 @@ struct SynthObject voices[MAX_VOICES] IBSS_ATTR;
|
||||||
void *alloc(int size)
|
void *alloc(int size)
|
||||||
{
|
{
|
||||||
static char *offset = NULL;
|
static char *offset = NULL;
|
||||||
static ssize_t totalSize = 0;
|
static size_t totalSize = 0;
|
||||||
char *ret;
|
char *ret;
|
||||||
|
|
||||||
int remainder = size % 4;
|
int remainder = size % 4;
|
||||||
|
@ -49,10 +49,10 @@ void *alloc(int size)
|
||||||
|
|
||||||
if (offset == NULL)
|
if (offset == NULL)
|
||||||
{
|
{
|
||||||
offset = rb->plugin_get_audio_buffer((size_t *)&totalSize);
|
offset = rb->plugin_get_audio_buffer(&totalSize);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (size + 4 > totalSize)
|
if (size + 4 > (int)totalSize)
|
||||||
{
|
{
|
||||||
printf("MALLOC BARF");
|
printf("MALLOC BARF");
|
||||||
printf("MALLOC BARF");
|
printf("MALLOC BARF");
|
||||||
|
|
|
@ -30,7 +30,7 @@ else
|
||||||
ROCKS += $(ZXBOX_OBJDIR)/zxbox.rock
|
ROCKS += $(ZXBOX_OBJDIR)/zxbox.rock
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ZXBOXFLAGS = $(filter-out -O%,$(PLUGINFLAGS)) -O3 -funroll-loops
|
ZXBOXFLAGS = $(filter-out -O%,$(PLUGINFLAGS)) -O3 -funroll-loops -fno-strict-aliasing
|
||||||
|
|
||||||
$(ZXBOX_OBJDIR)/zxbox.rock: $(ZXBOX_OBJ)
|
$(ZXBOX_OBJDIR)/zxbox.rock: $(ZXBOX_OBJ)
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue