diff options
author | Andree Buschmann <AndreeBuschmann@t-online.de> | 2011-08-18 21:01:08 +0000 |
---|---|---|
committer | Andree Buschmann <AndreeBuschmann@t-online.de> | 2011-08-18 21:01:08 +0000 |
commit | 0aa2fcb3b66b7281dc1dedd954d98b005bd4f1b5 (patch) | |
tree | fc856d3f3fd29503efdb948bd659c0a84b376fa5 | |
parent | b086458e4e1908878161ab5b84f287d5d726497b (diff) | |
download | rockbox-0aa2fcb3b66b7281dc1dedd954d98b005bd4f1b5.tar.gz rockbox-0aa2fcb3b66b7281dc1dedd954d98b005bd4f1b5.zip |
Optimized compiler settings for libgme. ARM now uses -O1 except for the 2413 emulator. The speed on PP5022 increases by 0-5% (NSF, YM2413-VGM), 5-10% (GBS, VGM) and 10-15% (SGC, KSS, AY).
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30331 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r-- | apps/codecs/codecs.make | 25 | ||||
-rw-r--r-- | apps/codecs/libgme/EMU2413SOURCES | 4 | ||||
-rw-r--r-- | apps/codecs/libgme/KSSSOURCES | 2 | ||||
-rw-r--r-- | apps/codecs/libgme/NSFSOURCES | 1 | ||||
-rw-r--r-- | apps/codecs/libgme/SGCSOURCES | 4 | ||||
-rw-r--r-- | apps/codecs/libgme/VGMSOURCES | 3 | ||||
-rw-r--r-- | apps/codecs/libgme/libemu2413.make | 10 |
7 files changed, 28 insertions, 21 deletions
diff --git a/apps/codecs/codecs.make b/apps/codecs/codecs.make index 1644ff0e91..5706075067 100644 --- a/apps/codecs/codecs.make +++ b/apps/codecs/codecs.make | |||
@@ -50,6 +50,7 @@ include $(APPSDIR)/codecs/libgme/libnsf.make | |||
50 | include $(APPSDIR)/codecs/libgme/libsgc.make | 50 | include $(APPSDIR)/codecs/libgme/libsgc.make |
51 | include $(APPSDIR)/codecs/libgme/libvgm.make | 51 | include $(APPSDIR)/codecs/libgme/libvgm.make |
52 | include $(APPSDIR)/codecs/libgme/libkss.make | 52 | include $(APPSDIR)/codecs/libgme/libkss.make |
53 | include $(APPSDIR)/codecs/libgme/libemu2413.make | ||
53 | 54 | ||
54 | # compile flags for codecs | 55 | # compile flags for codecs |
55 | CODECFLAGS = $(CFLAGS) -fstrict-aliasing -I$(APPSDIR)/codecs \ | 56 | CODECFLAGS = $(CFLAGS) -fstrict-aliasing -I$(APPSDIR)/codecs \ |
@@ -80,6 +81,7 @@ $(SPCLIB) : CODECFLAGS += -fno-strict-aliasing -O1 | |||
80 | $(TREMORLIB) : CODECFLAGS += -O2 | 81 | $(TREMORLIB) : CODECFLAGS += -O2 |
81 | $(TTALIB) : CODECFLAGS += -O2 | 82 | $(TTALIB) : CODECFLAGS += -O2 |
82 | $(VGMLIB) : CODECFLAGS += -fno-strict-aliasing -O2 | 83 | $(VGMLIB) : CODECFLAGS += -fno-strict-aliasing -O2 |
84 | $(EMU2413LIB) : CODECFLAGS += -fno-strict-aliasing -O3 | ||
83 | $(WAVPACKLIB) : CODECFLAGS += -O1 | 85 | $(WAVPACKLIB) : CODECFLAGS += -O1 |
84 | $(WMALIB) : CODECFLAGS += -O2 | 86 | $(WMALIB) : CODECFLAGS += -O2 |
85 | $(WMAPROLIB) : CODECFLAGS += -O1 | 87 | $(WMAPROLIB) : CODECFLAGS += -O1 |
@@ -89,13 +91,14 @@ $(WMAVOICELIB) : CODECFLAGS += -O1 | |||
89 | ifeq ($(CPU),arm) | 91 | ifeq ($(CPU),arm) |
90 | # redo per arm generation | 92 | # redo per arm generation |
91 | $(ALACLIB) : CODECFLAGS += -O2 | 93 | $(ALACLIB) : CODECFLAGS += -O2 |
92 | $(AYLIB) : CODECFLAGS += -fno-strict-aliasing -O3 | 94 | $(AYLIB) : CODECFLAGS += -fno-strict-aliasing -O1 |
93 | $(GBSLIB) : CODECFLAGS += -fno-strict-aliasing -O3 | 95 | $(GBSLIB) : CODECFLAGS += -fno-strict-aliasing -O1 |
94 | $(HESLIB) : CODECFLAGS += -fno-strict-aliasing -O3 | 96 | $(HESLIB) : CODECFLAGS += -fno-strict-aliasing -O1 |
95 | $(KSSLIB) : CODECFLAGS += -fno-strict-aliasing -O3 | 97 | $(KSSLIB) : CODECFLAGS += -fno-strict-aliasing -O1 |
96 | $(NSFLIB) : CODECFLAGS += -fno-strict-aliasing -O3 | 98 | $(NSFLIB) : CODECFLAGS += -fno-strict-aliasing -O1 |
97 | $(SGCLIB) : CODECFLAGS += -fno-strict-aliasing -O3 | 99 | $(SGCLIB) : CODECFLAGS += -fno-strict-aliasing -O1 |
98 | $(VGMLIB) : CODECFLAGS += -fno-strict-aliasing -O3 | 100 | $(VGMLIB) : CODECFLAGS += -fno-strict-aliasing -O1 |
101 | $(EMU2413LIB) : CODECFLAGS += -fno-strict-aliasing -O3 | ||
99 | $(WAVPACKLIB) : CODECFLAGS += -O3 | 102 | $(WAVPACKLIB) : CODECFLAGS += -O3 |
100 | else ifeq ($(CPU),coldfire) | 103 | else ifeq ($(CPU),coldfire) |
101 | $(A52LIB) : CODECFLAGS += -O2 | 104 | $(A52LIB) : CODECFLAGS += -O2 |
@@ -161,10 +164,10 @@ $(CODECDIR)/tta.codec : $(CODECDIR)/libtta.a | |||
161 | $(CODECDIR)/ay.codec : $(CODECDIR)/libay.a | 164 | $(CODECDIR)/ay.codec : $(CODECDIR)/libay.a |
162 | $(CODECDIR)/gbs.codec : $(CODECDIR)/libgbs.a | 165 | $(CODECDIR)/gbs.codec : $(CODECDIR)/libgbs.a |
163 | $(CODECDIR)/hes.codec : $(CODECDIR)/libhes.a | 166 | $(CODECDIR)/hes.codec : $(CODECDIR)/libhes.a |
164 | $(CODECDIR)/nsf.codec : $(CODECDIR)/libnsf.a | 167 | $(CODECDIR)/nsf.codec : $(CODECDIR)/libnsf.a $(CODECDIR)/libemu2413.a |
165 | $(CODECDIR)/sgc.codec : $(CODECDIR)/libsgc.a | 168 | $(CODECDIR)/sgc.codec : $(CODECDIR)/libsgc.a $(CODECDIR)/libemu2413.a |
166 | $(CODECDIR)/vgm.codec : $(CODECDIR)/libvgm.a | 169 | $(CODECDIR)/vgm.codec : $(CODECDIR)/libvgm.a $(CODECDIR)/libemu2413.a |
167 | $(CODECDIR)/kss.codec : $(CODECDIR)/libkss.a | 170 | $(CODECDIR)/kss.codec : $(CODECDIR)/libkss.a $(CODECDIR)/libemu2413.a |
168 | 171 | ||
169 | $(CODECS): $(CODECLIB) # this must be last in codec dependency list | 172 | $(CODECS): $(CODECLIB) # this must be last in codec dependency list |
170 | 173 | ||
diff --git a/apps/codecs/libgme/EMU2413SOURCES b/apps/codecs/libgme/EMU2413SOURCES new file mode 100644 index 0000000000..901c49eccf --- /dev/null +++ b/apps/codecs/libgme/EMU2413SOURCES | |||
@@ -0,0 +1,4 @@ | |||
1 | sms_apu.c | ||
2 | sms_fm_apu.c | ||
3 | emu2413.c | ||
4 | ym2413_emu.c | ||
diff --git a/apps/codecs/libgme/KSSSOURCES b/apps/codecs/libgme/KSSSOURCES index 8e9c6601bb..2607c7364c 100644 --- a/apps/codecs/libgme/KSSSOURCES +++ b/apps/codecs/libgme/KSSSOURCES | |||
@@ -3,11 +3,9 @@ kss_cpu.c | |||
3 | kss_emu.c | 3 | kss_emu.c |
4 | kss_scc_apu.c | 4 | kss_scc_apu.c |
5 | opl_apu.c | 5 | opl_apu.c |
6 | sms_apu.c | ||
7 | z80_cpu.c | 6 | z80_cpu.c |
8 | blip_buffer.c | 7 | blip_buffer.c |
9 | multi_buffer.c | 8 | multi_buffer.c |
10 | rom_data.c | 9 | rom_data.c |
11 | emu2413.c | ||
12 | emu8950.c | 10 | emu8950.c |
13 | emuadpcm.c | 11 | emuadpcm.c |
diff --git a/apps/codecs/libgme/NSFSOURCES b/apps/codecs/libgme/NSFSOURCES index d96e1d3f32..54b4f82f60 100644 --- a/apps/codecs/libgme/NSFSOURCES +++ b/apps/codecs/libgme/NSFSOURCES | |||
@@ -12,4 +12,3 @@ nsfe_info.c | |||
12 | blip_buffer.c | 12 | blip_buffer.c |
13 | multi_buffer.c | 13 | multi_buffer.c |
14 | rom_data.c | 14 | rom_data.c |
15 | emu2413.c | ||
diff --git a/apps/codecs/libgme/SGCSOURCES b/apps/codecs/libgme/SGCSOURCES index 72b06efef9..d91c0e1731 100644 --- a/apps/codecs/libgme/SGCSOURCES +++ b/apps/codecs/libgme/SGCSOURCES | |||
@@ -1,10 +1,6 @@ | |||
1 | sgc_cpu.c | 1 | sgc_cpu.c |
2 | sgc_emu.c | 2 | sgc_emu.c |
3 | sms_apu.c | ||
4 | sms_fm_apu.c | ||
5 | ym2413_emu.c | ||
6 | z80_cpu.c | 3 | z80_cpu.c |
7 | blip_buffer.c | 4 | blip_buffer.c |
8 | multi_buffer.c | 5 | multi_buffer.c |
9 | rom_data.c | 6 | rom_data.c |
10 | emu2413.c | ||
diff --git a/apps/codecs/libgme/VGMSOURCES b/apps/codecs/libgme/VGMSOURCES index ed32baca0d..637f87e8b0 100644 --- a/apps/codecs/libgme/VGMSOURCES +++ b/apps/codecs/libgme/VGMSOURCES | |||
@@ -1,10 +1,7 @@ | |||
1 | blip_buffer.c | 1 | blip_buffer.c |
2 | multi_buffer.c | 2 | multi_buffer.c |
3 | resampler.c | 3 | resampler.c |
4 | sms_apu.c | ||
5 | vgm_emu.c | 4 | vgm_emu.c |
6 | emu2413.c | ||
7 | ym2413_emu.c | ||
8 | ym2612_emu.c | 5 | ym2612_emu.c |
9 | inflate/bbfuncs.c | 6 | inflate/bbfuncs.c |
10 | inflate/inflate.c | 7 | inflate/inflate.c |
diff --git a/apps/codecs/libgme/libemu2413.make b/apps/codecs/libgme/libemu2413.make new file mode 100644 index 0000000000..2f489ced46 --- /dev/null +++ b/apps/codecs/libgme/libemu2413.make | |||
@@ -0,0 +1,10 @@ | |||
1 | |||
2 | # libemu2413 | ||
3 | EMU2413LIB := $(CODECDIR)/libemu2413.a | ||
4 | EMU2413LIB_SRC := $(call preprocess, $(APPSDIR)/codecs/libgme/EMU2413SOURCES) | ||
5 | EMU2413LIB_OBJ := $(call c2obj, $(EMU2413LIB_SRC)) | ||
6 | OTHER_SRC += $(EMU2413LIB_SRC) | ||
7 | |||
8 | $(EMU2413LIB): $(EMU2413LIB_OBJ) | ||
9 | $(SILENT)$(shell rm -f $@) | ||
10 | $(call PRINTS,AR $(@F))$(AR) rcs $@ $^ >/dev/null | ||