From 8785fd0236732d7fc20f5595beb881dc47fd265d Mon Sep 17 00:00:00 2001 From: TuxSH Date: Thu, 16 Apr 2020 21:05:33 +0100 Subject: [PATCH] Use -Os for rosalina, pm, sm. Decrease gdb buffer sizes, etc. --- sysmodules/pm/Makefile | 2 +- sysmodules/rosalina/Makefile | 4 ++-- sysmodules/rosalina/include/gdb.h | 4 ++-- sysmodules/sm/Makefile | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/sysmodules/pm/Makefile b/sysmodules/pm/Makefile index b14d489..63ba36f 100644 --- a/sysmodules/pm/Makefile +++ b/sysmodules/pm/Makefile @@ -28,7 +28,7 @@ INCLUDES := include ARCH := -march=armv6k -mtune=mpcore -mfloat-abi=hard -mtp=soft DEFINES := -DARM11 -D_3DS -CFLAGS := -g -std=gnu11 -Wall -Wextra -Werror -O2 -mword-relocations \ +CFLAGS := -g -std=gnu11 -Wall -Wextra -Werror -Os -mword-relocations \ -fomit-frame-pointer -ffunction-sections -fdata-sections \ $(ARCH) $(DEFINES) diff --git a/sysmodules/rosalina/Makefile b/sysmodules/rosalina/Makefile index 0616f6f..e88238b 100644 --- a/sysmodules/rosalina/Makefile +++ b/sysmodules/rosalina/Makefile @@ -28,8 +28,8 @@ INCLUDES := include include/gdb include/menus include/redshift ARCH := -march=armv6k -mtune=mpcore -mfloat-abi=hard -mtp=soft DEFINES := -DARM11 -D_3DS -CFLAGS := -g -std=gnu11 -Wall -Wextra -Werror -Wno-unused-value -O2 -mword-relocations \ - -fomit-frame-pointer -ffunction-sections -fdata-sections -ffast-math \ +CFLAGS := -g -std=gnu11 -Wall -Wextra -Werror -Wno-unused-value -Os -mword-relocations \ + -fomit-frame-pointer -ffunction-sections -fdata-sections -fno-math-errno \ $(ARCH) $(DEFINES) CFLAGS += $(INCLUDE) diff --git a/sysmodules/rosalina/include/gdb.h b/sysmodules/rosalina/include/gdb.h index aa1499f..b9266a2 100644 --- a/sysmodules/rosalina/include/gdb.h +++ b/sysmodules/rosalina/include/gdb.h @@ -18,14 +18,14 @@ #define MAX_DEBUG 3 #define MAX_DEBUG_THREAD 127 -#define MAX_BREAKPOINT 256 +#define MAX_BREAKPOINT 64 #define MAX_TIO_OPEN_FILE 32 // 512+24 is the ideal size as IDA will try to read exactly 0x100 bytes at a time. Add 4 to this, for $#, see below. // IDA seems to want additional bytes as well. // 1024 is fine enough to put all regs in the 'T' stop reply packets -#define GDB_BUF_LEN 2048 +#define GDB_BUF_LEN 1024 #define GDB_HANDLER(name) GDB_Handle##name #define GDB_QUERY_HANDLER(name) GDB_HANDLER(Query##name) diff --git a/sysmodules/sm/Makefile b/sysmodules/sm/Makefile index b14d489..63ba36f 100644 --- a/sysmodules/sm/Makefile +++ b/sysmodules/sm/Makefile @@ -28,7 +28,7 @@ INCLUDES := include ARCH := -march=armv6k -mtune=mpcore -mfloat-abi=hard -mtp=soft DEFINES := -DARM11 -D_3DS -CFLAGS := -g -std=gnu11 -Wall -Wextra -Werror -O2 -mword-relocations \ +CFLAGS := -g -std=gnu11 -Wall -Wextra -Werror -Os -mword-relocations \ -fomit-frame-pointer -ffunction-sections -fdata-sections \ $(ARCH) $(DEFINES)