From 37355dca6996485b0fb656c2d909d0e55f1a2053 Mon Sep 17 00:00:00 2001 From: yoshida_teruhisa Date: Mon, 14 Jul 2008 07:52:52 +0000 Subject: [PATCH] =?UTF-8?q?jackal=E3=81=A8racoon=E3=81=AE=E9=87=8D?= =?UTF-8?q?=E3=81=95=E3=81=AE=E5=B7=AE=E3=82=92=E8=AA=BF=E3=81=B9=E3=82=8B?= =?UTF-8?q?=E3=81=9F=E3=82=81=E3=81=AE=E9=9B=9B=E5=BD=A2SimpleBenchmark?= =?UTF-8?q?=E3=82=92tests=E3=81=AB=E8=BF=BD=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit git-svn-id: file:///Users/lillianskinner/Downloads/platinum/twl/TwlIPL/trunk@1873 b08762b0-b915-fc4b-9d8c-17b2551a87ff --- .../SimpleBenchmark/ARM9/ARM9-TS.lcf.template | 1048 +++++++++++++++++ build/tests/SimpleBenchmark/ARM9/ARM9-TS.lsf | 53 + build/tests/SimpleBenchmark/ARM9/Makefile | 32 + build/tests/SimpleBenchmark/ARM9/Makefile.0 | 74 ++ build/tests/SimpleBenchmark/ARM9/Makefile.1 | 61 + build/tests/SimpleBenchmark/ARM9/main0.rsf | 204 ++++ build/tests/SimpleBenchmark/ARM9/main1.rsf | 204 ++++ .../ARM9/src/SimpleBenchmark.c | 81 ++ .../ARM9/src/SimpleBenchmark.h | 36 + build/tests/SimpleBenchmark/ARM9/src/main.c | 86 ++ build/tests/SimpleBenchmark/Makefile | 30 + build/tests/SimpleBenchmark/banner/Makefile | 32 + build/tests/SimpleBenchmark/banner/Makefile.0 | 48 + build/tests/SimpleBenchmark/banner/Makefile.1 | 48 + .../SimpleBenchmark/banner/banner_v3.bsf | Bin 0 -> 762 bytes .../SimpleBenchmark/banner/icon/gameIcon.bmp | Bin 0 -> 630 bytes .../banner/icon/msk_pictchat_icon.bin | Bin 0 -> 4480 bytes .../banner/test-utf16_0_v3.TWL.bsf | Bin 0 -> 786 bytes .../banner/test-utf16_1_v3.TWL.bsf | Bin 0 -> 786 bytes 19 files changed, 2037 insertions(+) create mode 100644 build/tests/SimpleBenchmark/ARM9/ARM9-TS.lcf.template create mode 100644 build/tests/SimpleBenchmark/ARM9/ARM9-TS.lsf create mode 100644 build/tests/SimpleBenchmark/ARM9/Makefile create mode 100644 build/tests/SimpleBenchmark/ARM9/Makefile.0 create mode 100644 build/tests/SimpleBenchmark/ARM9/Makefile.1 create mode 100644 build/tests/SimpleBenchmark/ARM9/main0.rsf create mode 100644 build/tests/SimpleBenchmark/ARM9/main1.rsf create mode 100644 build/tests/SimpleBenchmark/ARM9/src/SimpleBenchmark.c create mode 100644 build/tests/SimpleBenchmark/ARM9/src/SimpleBenchmark.h create mode 100644 build/tests/SimpleBenchmark/ARM9/src/main.c create mode 100644 build/tests/SimpleBenchmark/Makefile create mode 100644 build/tests/SimpleBenchmark/banner/Makefile create mode 100644 build/tests/SimpleBenchmark/banner/Makefile.0 create mode 100644 build/tests/SimpleBenchmark/banner/Makefile.1 create mode 100644 build/tests/SimpleBenchmark/banner/banner_v3.bsf create mode 100644 build/tests/SimpleBenchmark/banner/icon/gameIcon.bmp create mode 100644 build/tests/SimpleBenchmark/banner/icon/msk_pictchat_icon.bin create mode 100644 build/tests/SimpleBenchmark/banner/test-utf16_0_v3.TWL.bsf create mode 100644 build/tests/SimpleBenchmark/banner/test-utf16_1_v3.TWL.bsf diff --git a/build/tests/SimpleBenchmark/ARM9/ARM9-TS.lcf.template b/build/tests/SimpleBenchmark/ARM9/ARM9-TS.lcf.template new file mode 100644 index 00000000..bdc95bb6 --- /dev/null +++ b/build/tests/SimpleBenchmark/ARM9/ARM9-TS.lcf.template @@ -0,0 +1,1048 @@ +#--------------------------------------------------------------------------- +# Project: TwlSDK - include +# File: ARM9-TS.lcf.template +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded instructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev$ +# $Author$ +#--------------------------------------------------------------------------- +MEMORY +{ + (RWX) : ORIGIN = , LENGTH = 0x0 > + + + (RWX) : ORIGIN = , LENGTH = 0x0 >> + + binary.AUTOLOAD_INFO (RWX) : ORIGIN = 0, LENGTH = 0x0 >> + binary.STATIC_FOOTER (RWX) : ORIGIN = 0, LENGTH = 0x0 >> + + F (RW) : ORIGIN = 0, LENGTH = 0x0 > + F (RW) : ORIGIN = 0, LENGTH = 0x0 > + + (RWXO): ORIGIN = , LENGTH = 0x0 > + + + dummy.MAIN_EX.NITRO (RW) : ORIGIN = 0x023e0000, LENGTH = 0x0 + arena.MAIN.NITRO (RW) : ORIGIN = AFTER(,), LENGTH = 0x0 + arena.MAIN_EX.NITRO (RW) : ORIGIN = AFTER(dummy.MAIN_EX.NITRO,), LENGTH = 0x0 + arena.ITCM (RW) : ORIGIN = AFTER(ITCM,), LENGTH = 0x0 + arena.DTCM (RW) : ORIGIN = AFTER(DTCM,), LENGTH = 0x0 + + check.ITCM (RW) : ORIGIN = 0x0, LENGTH = 0x08000 > itcm.check + check.DTCM (RW) : ORIGIN = 0x0, LENGTH = 0x04000 > dtcm.check + check.MAIN.NITRO (RW) : ORIGIN = 0x02000000, LENGTH = 0x0f80000 > main.nitro.check + + binary.LTDAUTOLOAD_TOP (RW) : ORIGIN = 0, LENGTH = 0x0 > + + (RWX) : ORIGIN = , LENGTH = 0x0 >> + + binary.LTDAUTOLOAD_INFO (RWX) : ORIGIN = 0, LENGTH = 0x0 >> + + L (RW) : ORIGIN = 0, LENGTH = 0x0 > + L (RW) : ORIGIN = 0, LENGTH = 0x0 > + + (RWXO): ORIGIN = , LENGTH = 0x0 > + + + dummy.MAIN_EX.TWL (RW) : ORIGIN = 0x0d000000, LENGTH = 0x0 + arena.MAIN.TWL (RW) : ORIGIN = AFTER(,,LTDMAIN,), LENGTH = 0x0 + arena.MAIN_EX.TWL (RW) : ORIGIN = AFTER(dummy.MAIN_EX.TWL,,,LTDMAIN,), LENGTH = 0x0 + + check.MAIN.TWL (RW) : ORIGIN = 0x02000000, LENGTH = 0x0f80000 > main.twl.check + + binary.MODULE_FILES (RW) : ORIGIN = 0, LENGTH = 0x0 > component.files +} + +FORCE_ACTIVE +{ + SVC_SoftReset +} + +KEEP_SECTION +{ + .sinit +} + +SECTIONS +{ + ############################ STATIC ################################# + .: + { + ALIGNALL(4); + . = ALIGN(32); # Fit to cache line + + # + # Definition to refer overlay segment, when same name symbols exist in multiple overlays. + # + + SEARCH_SYMBOL ; + + + # + # TEXT BLOCK: READ ONLY + # + SDK_STATIC_START =.; + SDK_STATIC_TEXT_START =.; + #:::::::::: text/rodata + libsyscall.a (.text) + OBJECT(_start,*) + crt0.FLX.TWL.o (.text) + crt0.FLX.TWL.o (.rodata) + # + # .version セクションを追加しています。 + # このセクションに含まれる情報はロットチェックの際に + # 必要となりますので、必ずこの位置に残すようにして下さい。 + # + * (.version) + OBJECT(TwlMain,*) + + + + + + + * (.exception) + . = ALIGN(4); + SDK_STATIC_ETABLE_START =.; + __exception_table_start__ =.; + EXCEPTION + __exception_table_end__ =.; + SDK_STATIC_ETABLE_END =.; + + + + + + + + + + + + + . = ALIGN(4); + SDK_STATIC_SINIT_START =.; + #:::::::::: ctor + + + + + + + + + + + + + WRITEW 0; + #:::::::::: ctor + SDK_STATIC_SINIT_END =.; + #:::::::::: text/rodata + SDK_STATIC_TEXT_END =.; + + # + # DATA BLOCK: READ WRITE + # + . = ALIGN(32); # Fit to cache line + SDK_STATIC_DATA_START =.; + #:::::::::: data + + + + + + + + + + + + + . = ALIGN(4); + + SDK_LTDOVERLAYTABLE_DIGEST =.; + . = . + 20; + SDK_LTDOVERLAYTABLE_DIGEST_END =.; + SDK_OVERLAYTABLE_DIGEST =.; + . = . + 20; + SDK_OVERLAYTABLE_DIGEST_END =.; + SDK_OVERLAY_DIGEST =.; + . = . + * 20; + . = . + * 20; + SDK_OVERLAY_DIGEST_END =.; + #:::::::::: data + . = ALIGN(32); + SDK_STATIC_DATA_END =.; + SDK_STATIC_END =.; + + SDK_STATIC_TEXT_SIZE = SDK_STATIC_TEXT_END - SDK_STATIC_TEXT_START; + SDK_STATIC_DATA_SIZE = SDK_STATIC_DATA_END - SDK_STATIC_DATA_START; + SDK_STATIC_SIZE = SDK_STATIC_END - SDK_STATIC_START; + __sinit__ = SDK_STATIC_SINIT_START; # for static initializer + + } > + + ..bss: + { + ALIGNALL(4); + . = ALIGN(32); # Fit to cache line + + # + # Definition to refer overlay segment, when same name symbols exist in multiple overlays. + # + + SEARCH_SYMBOL ; + + + # + # BSS BLOCK + # + SDK_STATIC_BSS_START =.; + #:::::::::: bss + + + + + + + + + + + + + #:::::::::: bss + . = ALIGN(32); + SDK_STATIC_BSS_END = .; + + SDK_STATIC_BSS_SIZE = SDK_STATIC_BSS_END - SDK_STATIC_BSS_START; + + } >> + + + ############################ AUTOLOADS ############################## + SDK_AUTOLOAD.ITCM.START = 0x01ff8000; + SDK_AUTOLOAD.ITCM.END = SDK_AUTOLOAD.ITCM.START; + SDK_AUTOLOAD.ITCM.BSS_END = SDK_AUTOLOAD.ITCM.START; + SDK_AUTOLOAD.ITCM.SIZE = 0; + SDK_AUTOLOAD.ITCM.BSS_SIZE = 0; + SDK_AUTOLOAD.DTCM.START = 0x02fe0000; + SDK_AUTOLOAD.DTCM.END = SDK_AUTOLOAD.DTCM.START; + SDK_AUTOLOAD.DTCM.BSS_END = SDK_AUTOLOAD.DTCM.START; + SDK_AUTOLOAD.DTCM.SIZE = 0; + SDK_AUTOLOAD.DTCM.BSS_SIZE = 0; + SDK_AUTOLOAD_START = SDK_STATIC_END; + SDK_AUTOLOAD_SIZE = 0; + SDK_AUTOLOAD_NUMBER = ; + + + .: + { + ALIGNALL(4); + . = ALIGN(32); + + # + # Definition to refer overlay segment, when same name symbols exist in multiple overlays. + # + + SEARCH_SYMBOL ; + + + # + # TEXT BLOCK: READ ONLY + # + SDK_AUTOLOAD__ID =; + SDK_AUTOLOAD..ID =; + SDK_AUTOLOAD..START =.; + SDK_AUTOLOAD..TEXT_START =.; + #:::::::::: text/rodata + + + + + + + + + + + + + + + + + + + . = ALIGN(4); + SDK_AUTOLOAD..SINIT_START = .; + #:::::::::: ctor + + + + + + + + + + + + + WRITEW 0; + #:::::::::: ctor + SDK_AUTOLOAD..SINIT_END = .; + #:::::::::: text/rodata + SDK_AUTOLOAD..TEXT_END =.; + + # + # DATA BLOCK: READ WRITE BLOCK + # + . = ALIGN(32); + SDK_AUTOLOAD..DATA_START =.; + #:::::::::: data + + + + + + + + + + + + + + + + + + + + + + + + + #:::::::::: data + SDK_AUTOLOAD..DATA_END =.; + . = ALIGN(32); + SDK_AUTOLOAD..END =.; + + SDK_AUTOLOAD..TEXT_SIZE = SDK_AUTOLOAD..TEXT_END - SDK_AUTOLOAD..TEXT_START; + SDK_AUTOLOAD..DATA_SIZE = SDK_AUTOLOAD..DATA_END - SDK_AUTOLOAD..DATA_START; + SDK_AUTOLOAD..SIZE = SDK_AUTOLOAD..END - SDK_AUTOLOAD..START; + SDK_AUTOLOAD_SIZE = SDK_AUTOLOAD_SIZE + SDK_AUTOLOAD..SIZE; + + } > + + ..bss: + { + ALIGNALL(4); + . = ALIGN(32); + + # + # Definition to refer overlay segment, when same name symbols exist in multiple overlays. + # + + SEARCH_SYMBOL + + + # + # BSS BLOCK + # + SDK_AUTOLOAD..BSS_START = .; + #:::::::::: bss + + + + + + + + + + + + + + + + + + + + + + + + + #:::::::::: bss + . = ALIGN(32); + SDK_AUTOLOAD..BSS_END = .; + + SDK_AUTOLOAD..BSS_SIZE = SDK_AUTOLOAD..BSS_END - SDK_AUTOLOAD..BSS_START; + + } >> + + + + SDK_AUTOLOAD_ITCM_START = SDK_AUTOLOAD.ITCM.START; + SDK_AUTOLOAD_ITCM_END = SDK_AUTOLOAD.ITCM.END; + SDK_AUTOLOAD_ITCM_BSS_END = SDK_AUTOLOAD.ITCM.BSS_END; + SDK_AUTOLOAD_ITCM_SIZE = SDK_AUTOLOAD.ITCM.SIZE; + SDK_AUTOLOAD_ITCM_BSS_SIZE = SDK_AUTOLOAD.ITCM.BSS_SIZE; + SDK_AUTOLOAD_DTCM_START = SDK_AUTOLOAD.DTCM.START; + SDK_AUTOLOAD_DTCM_END = SDK_AUTOLOAD.DTCM.END; + SDK_AUTOLOAD_DTCM_BSS_END = SDK_AUTOLOAD.DTCM.BSS_END; + SDK_AUTOLOAD_DTCM_SIZE = SDK_AUTOLOAD.DTCM.SIZE; + SDK_AUTOLOAD_DTCM_BSS_SIZE = SDK_AUTOLOAD.DTCM.BSS_SIZE; + + ############################ AUTOLOAD_INFO ########################## + .binary.AUTOLOAD_INFO: + { + + WRITEW ADDR(.); + WRITEW SDK_AUTOLOAD..SIZE; + WRITEW SDK_AUTOLOAD..SINIT_START; + WRITEW SDK_AUTOLOAD..BSS_SIZE; + + + } > binary.AUTOLOAD_INFO + + SDK_AUTOLOAD_LIST = SDK_AUTOLOAD_START + SDK_AUTOLOAD_SIZE; + SDK_AUTOLOAD_LIST_END = SDK_AUTOLOAD_START + SDK_AUTOLOAD_SIZE + SIZEOF(.binary.AUTOLOAD_INFO); + SDK_AUTOLOAD_SIZE = SDK_AUTOLOAD_SIZE + SIZEOF(.binary.AUTOLOAD_INFO); + + ############################ STATIC_FOOTER ########################## + .binary.STATIC_FOOTER: + { + WRITEW 0xdec00621; # LE(0x2106C0DE) = NITRO CODE + WRITEW _start_ModuleParams - ADDR(.); + WRITEW SDK_OVERLAY_DIGEST - ADDR(.); + WRITEW _start_LtdModuleParams - ADDR(.); + } > binary.STATIC_FOOTER + + ############################ OVERLAYS ############################### + SDK_OVERLAY_NUMBER = ; + + + .: + { + ALIGNALL(4); + . = ALIGN(32); # Fit to cache line + + # + # Definition to refer overlay segment, when same name symbols exist in multiple overlays. + # + + SEARCH_SYMBOL ; + + + # + # TEXT BLOCK: READ ONLY + # + SDK_OVERLAY__ID =; ### SEGMENT OVERLAY ID + SDK_OVERLAY..ID =; + SDK_OVERLAY..START =.; + SDK_OVERLAY..TEXT_START =.; + #:::::::::: text/rodata + + + + + + + + + + + + + + + + + + + . = ALIGN(4); + SDK_OVERLAY..SINIT_START =.; + #:::::::::: ctor + + + + + + + + + + + + + WRITEW 0; + #:::::::::: ctor + SDK_OVERLAY..SINIT_END =.; + #:::::::::: text/rodata + SDK_OVERLAY..TEXT_END =.; + + # + # DATA BLOCK: READ WRITE + # + . = ALIGN(32); + SDK_OVERLAY..DATA_START =.; + #:::::::::: data + + + + + + + + + + + + + #:::::::::: data + SDK_OVERLAY..DATA_END =.; + . = ALIGN(32); + SDK_OVERLAY..END =.; + + SDK_OVERLAY..TEXT_SIZE = SDK_OVERLAY..TEXT_END - SDK_OVERLAY..TEXT_START; + SDK_OVERLAY..DATA_SIZE = SDK_OVERLAY..DATA_END - SDK_OVERLAY..DATA_START; + SDK_OVERLAY..SIZE = SDK_OVERLAY..END - SDK_OVERLAY..START; + + } > + + ..bss: + { + ALIGNALL(4); + . = ALIGN(32); + + # + # Definition to refer overlay segment, when same name symbols exist in multiple overlays. + # + + SEARCH_SYMBOL ; + + + # + # BSS BLOCK + # + SDK_OVERLAY..BSS_START = .; + #:::::::::: bss + + + + + + + + + + + + + #:::::::::: bss + . = ALIGN(32); + SDK_OVERLAY..BSS_END = .; + + SDK_OVERLAY..BSS_SIZE = SDK_OVERLAY..BSS_END - SDK_OVERLAY..BSS_START; + + } >> + + + + ############################ OVERLAYDEFS ############################ + .F: + { + ### module information + WRITEW ADDR(.); # load address + WRITEW _start; # entry address + WRITEW SDK_STATIC_SIZE + SDK_AUTOLOAD_SIZE; # size of module + WRITEW _start_AutoloadDoneCallback; # callback autoload done + + ### overlay filename + + WRITES (""); # Overlay + + + } > F + + ############################ OVERLAYTABLE ########################### + .F: + { + + WRITEW ; # overlay ID + WRITEW ADDR(.); # load address + WRITEW SDK_OVERLAY..SIZE; # size of module + WRITEW SDK_OVERLAY..BSS_SIZE; # size of bss + WRITEW SDK_OVERLAY..SINIT_START; # start address of static init + WRITEW SDK_OVERLAY..SINIT_END; # end address of static init + WRITEW ; # ROM file ID + WRITEW 0; # compressed state + + + } > F + + ############################ ARENA ################################## + .dummy.MAIN_EX.NITRO: + { + . = ALIGN(32); + + } > dummy.MAIN_EX.NITRO + + .arena.MAIN.NITRO: + { + . = ALIGN(32); + SDK_SECTION_ARENA_START =.; + + } > arena.MAIN.NITRO + + .arena.MAIN_EX.NITRO: + { + . = ALIGN(32); + SDK_SECTION_ARENA_EX_START =.; + + } > arena.MAIN_EX.NITRO + + .arena.ITCM: + { + . = ALIGN(32); + SDK_SECTION_ARENA_ITCM_START =.; + + } > arena.ITCM + + .arena.DTCM: + { + . = ALIGN(32); + SDK_SECTION_ARENA_DTCM_START =.; + + } > arena.DTCM + + ############################ OTHERS ################################# + SDK_MAIN_ARENA_LO = SDK_SECTION_ARENA_START; + SDK_IRQ_STACKSIZE = ; # allocated in DTCM + SDK_SYS_STACKSIZE = ; # when 0 means all remains of DTCM + SDK_SYS_STACKSIZE_SIGN = (SDK_SYS_STACKSIZE < 0x80000000) * 2 - 1; + + .check.ITCM: + { + . = . + SDK_AUTOLOAD_ITCM_SIZE + SDK_AUTOLOAD_ITCM_BSS_SIZE; + + . = . + SDK_OVERLAY..SIZE + SDK_OVERLAY..BSS_SIZE; + + + } > check.ITCM + + .check.DTCM: + { + . = . + SDK_AUTOLOAD_DTCM_SIZE + SDK_AUTOLOAD_DTCM_BSS_SIZE; + + . = . + SDK_OVERLAY..SIZE + SDK_OVERLAY..BSS_SIZE; + + . = . + 0x080 + SDK_IRQ_STACKSIZE + SDK_SYS_STACKSIZE * SDK_SYS_STACKSIZE_SIGN; + } > check.DTCM + + .check.MAIN.NITRO: + { + . = SDK_SECTION_ARENA_START; + + } > check.MAIN.NITRO + + ########################### LTDAUTOLOADS ############################ + SDK_LTDAUTOLOAD.LTDMAIN.START = SDK_STATIC_BSS_END; + SDK_LTDAUTOLOAD.LTDMAIN.END = SDK_LTDAUTOLOAD.LTDMAIN.START; + SDK_LTDAUTOLOAD.LTDMAIN.BSS_EDN = SDK_LTDAUTOLOAD.LTDMAIN.START; + SDK_LTDAUTOLOAD.LTDMAIN.SIZE = 0; + SDK_LTDAUTOLOAD.LTDMAIN.BSS_SIZE = 0; + SDK_LTDAUTOLOAD_TOP_START = 0x02400000; + SDK_LTDAUTOLOAD_TOP_SIZE = 4; # STATIC 領域が無い代わりに 4 bytes のダミーがバイナリファイルの先頭に入る # + SDK_LTDAUTOLOAD_START = SDK_LTDAUTOLOAD_TOP_START + SDK_LTDAUTOLOAD_TOP_SIZE; + SDK_LTDAUTOLOAD_SIZE = 0; + SDK_LTDAUTOLOAD_NUMBER = ; + + .binary.LTDAUTOLOAD_TOP: + { + WRITEW 0; + + } > binary.LTDAUTOLOAD_TOP + + + .: + { + ALIGNALL(4); + . = ALIGN(32); # Fit to cache line + + # + # Definition to refer overlay segment, when same name symbols exist in multiple overlays. + # + + SEARCH_SYMBOL ; + + + SDK_LTDAUTOLOAD__ID =; + SDK_LTDAUTOLOAD..ID =; + SDK_LTDAUTOLOAD..START =.; + # + # TEXT BLOCK: READ ONLY + # + SDK_LTDAUTOLOAD..TEXT_START =.; + #:::::::::: text/rodata + + + + + + + + + + + + + + + + + + + . = ALIGN(4); + SDK_LTDAUTOLOAD..SINIT_START = .; + #:::::::::: ctor + + + + + + + + + + + + + WRITEW 0; + #:::::::::: ctor + SDK_LTDAUTOLOAD..SINIT_END = .; + #:::::::::: text/rodata + SDK_LTDAUTOLOAD..TEXT_END =.; + + # + # DATA BLOCK: READ WRITE + # + . = ALIGN(32); + SDK_LTDAUTOLOAD..DATA_START =.; + #:::::::::: data + + + + + + + + + + + + + + + + + + + #:::::::::: data + SDK_LTDAUTOLOAD..DATA_END =.; + . = ALIGN(32); + SDK_LTDAUTOLOAD..END =.; + + SDK_LTDAUTOLOAD..TEXT_SIZE = SDK_LTDAUTOLOAD..TEXT_END - SDK_LTDAUTOLOAD..TEXT_START; + SDK_LTDAUTOLOAD..DATA_SIZE = SDK_LTDAUTOLOAD..DATA_END - SDK_LTDAUTOLOAD..DATA_START; + SDK_LTDAUTOLOAD..SIZE = SDK_LTDAUTOLOAD..END - SDK_LTDAUTOLOAD..START; + SDK_LTDAUTOLOAD_SIZE = SDK_LTDAUTOLOAD_SIZE + SDK_LTDAUTOLOAD..SIZE; + + } > + + ..bss: + { + ALIGNALL(4); + . = ALIGN(32); + + # + # Definition to refer overlay segment, when same name symbols exist in multiple overlays. + # + + SEARCH_SYMBOL ; + + + # + # BSS BLOCK + # + SDK_LTDAUTOLOAD..BSS_START =.; + #:::::::::: bss + + + + + + + + + + + + + + + + + + + #:::::::::: bss + . = ALIGN(32); + SDK_LTDAUTOLOAD..BSS_END =.; + + SDK_LTDAUTOLOAD..BSS_SIZE = SDK_LTDAUTOLOAD..BSS_END - SDK_LTDAUTOLOAD..BSS_START; + + } >> + + + + SDK_LTDAUTOLOAD_LTDMAIN_START = SDK_LTDAUTOLOAD.LTDMAIN.START; + SDK_LTDAUTOLOAD_LTDMAIN_END = SDK_LTDAUTOLOAD.LTDMAIN.END; + SDK_LTDAUTOLOAD_LTDMAIN_BSS_END = SDK_LTDAUTOLOAD.LTDMAIN.BSS_END; + SDK_LTDAUTOLOAD_LTDMAIN_SIZE = SDK_LTDAUTOLOAD.LTDMAIN.SIZE; + SDK_LTDAUTOLOAD_LTDMAIN_BSS_SIZE = SDK_LTDAUTOLOAD.LTDMAIN.BSS_SIZE; + + ######################### LTDAUTOLOAD_INFO ########################## + .binary.LTDAUTOLOAD_INFO: + { + + WRITEW ADDR(.); + WRITEW SDK_LTDAUTOLOAD..SIZE; + WRITEW SDK_LTDAUTOLOAD..SINIT_START; + WRITEW SDK_LTDAUTOLOAD..BSS_SIZE; + + + } > binary.LTDAUTOLOAD_INFO + + SDK_LTDAUTOLOAD_LIST = SDK_LTDAUTOLOAD_START + SDK_LTDAUTOLOAD_SIZE; + SDK_LTDAUTOLOAD_LIST_END = SDK_LTDAUTOLOAD_LIST + SIZEOF(.binary.LTDAUTOLOAD_INFO); + SDK_LTDAUTOLOAD_SIZE = SDK_LTDAUTOLOAD_SIZE + SIZEOF(.binary.LTDAUTOLOAD_INFO); + + ########################### LTDOVERLAYS ############################# + SDK_LTDOVERLAY_NUMBER = ; + + + .: + { + ALIGNALL(4); + . = ALIGN(32); + + # + # Definition to refer overlay segment, when same name symbols exist in multiple overlays. + # + + SEARCH_SYMBOL ; + + + SDK_LTDOVERLAY__ID =; + SDK_LTDOVERLAY..ID =; + SDK_LTDOVERLAY..START =.; + # + # TEXT BLOCK: READ ONLY + # + SDK_LTDOVERLAY..TEXT_START =.; + #:::::::::: text/rodata + + + + + + + + + + + + + + + + + + + . = ALIGN(4); + SDK_LTDOVERLAY..SINIT_START =.; + #:::::::::: ctor + + + + + + + + + + + + + WRITEW 0; + #:::::::::: ctor + SDK_LTDOVERLAY..SINIT_END =.; + #:::::::::: text/rodata + SDK_LTDOVERLAY..TEXT_END =.; + + # + # DATA BLOCK: READ WRITE + # + . = ALIGN(32); + SDK_LTDOVERLAY..DATA_START =.; + #:::::::::: data + + + + + + + + + + + + + #:::::::::: data + SDK_LTDOVERLAY..DATA_END =.; + . = ALIGN(32); + SDK_LTDOVERLAY..END =.; + + SDK_LTDOVERLAY..TEXT_SIZE = SDK_LTDOVERLAY..TEXT_END - SDK_LTDOVERLAY..TEXT_START; + SDK_LTDOVERLAY..DATA_SIZE = SDK_LTDOVERLAY..DATA_END - SDK_LTDOVERLAY..DATA_START; + SDK_LTDOVERLAY..SIZE = SDK_LTDOVERLAY..END - SDK_LTDOVERLAY..START; + + } > + + ..bss: + { + ALIGNALL(4); + . = ALIGN(32); + + # + # Definition to refer overlay segment, when same name symbols exist in multiple overlays. + # + + SEARCH_SYMBOL ; + + + # + # BSS BLOCK + # + SDK_LTDOVERLAY..BSS_START =.; + #:::::::::: bss + + + + + + + + + + + + + #:::::::::: bss + . = ALIGN(32); + SDK_LTDOVERLAY..BSS_END =.; + + SDK_LTDOVERLAY..BSS_SIZE = SDK_LTDOVERLAY..BSS_END - SDK_LTDOVERLAY..BSS_START; + + } >> + + + + ########################## LTDOVERLAYDEFS ########################### + .L: + { + ### TWL limited extended static module information + WRITEW SDK_LTDAUTOLOAD_TOP_START; # load address + WRITEW 0; # padding + WRITEW SDK_LTDAUTOLOAD_SIZE + SDK_LTDAUTOLOAD_TOP_SIZE; # size of module + WRITEW 0; # padding + + ### TWL limited overlay filename + + WRITES (""); + + + } > L + + ######################### LTDOVERLAYTABLE ########################### + .L: + { + + WRITEW ; # overlay ID + WRITEW ADDR(.); # load address + WRITEW SDK_LTDOVERLAY..SIZE; # size of module + WRITEW SDK_LTDOVERLAY..BSS_SIZE; # size of bss + WRITEW SDK_LTDOVERLAY..SINIT_START; # start address of static init + WRITEW SDK_LTDOVERLAY..SINIT_END; # end address of static init + WRITEW ; # ROM file ID + WRITEW 0; # compressed state + + + } > L + + ############################ ARENA ################################## + .dummy.MAIN_EX.TWL: + { + . = ALIGN(32); + + } > dummy.MAIN_EX.TWL + + .arena.MAIN.TWL: + { + . = ALIGN(32); + SDK_LTDMAIN_ARENA_LO =.; + + } > arena.MAIN.TWL + + .arena.MAIN_EX.TWL: + { + . = ALIGN(32); + SDK_LTDMAIN_EX_ARENA_LO =.; + + } > arena.MAIN_EX.TWL + + .check.MAIN.TWL: + { + . = SDK_LTDMAIN_ARENA_LO; + + } > check.MAIN.TWL + + ############################ OTHERS ################################# + # Module filelist + .binary.MODULE_FILES: + { + WRITES (""); + WRITES (""); + WRITES (""); + WRITES (""); + WRITES (""); + WRITES (""); + + } > binary.MODULE_FILES + +} diff --git a/build/tests/SimpleBenchmark/ARM9/ARM9-TS.lsf b/build/tests/SimpleBenchmark/ARM9/ARM9-TS.lsf new file mode 100644 index 00000000..b4de7a96 --- /dev/null +++ b/build/tests/SimpleBenchmark/ARM9/ARM9-TS.lsf @@ -0,0 +1,53 @@ +#---------------------------------------------------------------------------- +# Project: TwlSDK - include +# File: ARM9-BB.lsf +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded insructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev$ +# $Author$ +#---------------------------------------------------------------------------- +# +# TWL LCF SPEC FILE +# + +Static $(TARGET_NAME) +{ + Address 0x02680200 + Object $(OBJS_STATIC) + Library $(LLIBS) $(GLIBS) $(CW_LIBS) +} + +Autoload ITCM +{ + Address 0x01ff8000 + Object * (.itcm) + Object $(OBJS_AUTOLOAD) (.text) + Object $(OBJS_AUTOLOAD) (.rodata) +} + +Autoload DTCM +{ + Address $(ADDRESS_DTCM) + Object * (.dtcm) + Object $(OBJS_AUTOLOAD) (.data) + Object $(OBJS_AUTOLOAD) (.sdata) + Object $(OBJS_AUTOLOAD) (.bss) + Object $(OBJS_AUTOLOAD) (.sbss) +} + +Ltdautoload LTDMAIN +{ + # NITRO/TWL 共有のオーバーレイが在る場合は、さらにその後ろに配置する必要があります。 + After $(TARGET_NAME) + Object * (.ltdmain) + Object $(OBJS_LTDAUTOLOAD) + Library $(LLIBS_EX) $(GLIBS_EX) +} diff --git a/build/tests/SimpleBenchmark/ARM9/Makefile b/build/tests/SimpleBenchmark/ARM9/Makefile new file mode 100644 index 00000000..4144a38b --- /dev/null +++ b/build/tests/SimpleBenchmark/ARM9/Makefile @@ -0,0 +1,32 @@ +#! make -f +#---------------------------------------------------------------------------- +# Project: TwlSDK - demos - simpleShoot-1 +# File: Makefile +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded instructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev$ +# $Author$ +#---------------------------------------------------------------------------- + +SUBDIRS = +SUBMAKES = Makefile.0 Makefile.1 + +include $(TWL_IPL_RED_ROOT)/build/tests/RelocateChecker/buildtools/commondefs + +#---------------------------------------------------------------------------- + +do-build : $(TARGETS) + +include $(TWL_IPL_RED_ROOT)/build/tests/RelocateChecker/buildtools/modulerules + +#---------------------------------------------------------------------------- + +#===== End of Makefile ===== diff --git a/build/tests/SimpleBenchmark/ARM9/Makefile.0 b/build/tests/SimpleBenchmark/ARM9/Makefile.0 new file mode 100644 index 00000000..4f65a23a --- /dev/null +++ b/build/tests/SimpleBenchmark/ARM9/Makefile.0 @@ -0,0 +1,74 @@ +#! make -f +#---------------------------------------------------------------------------- +# Project: TwlSDK - demos - simpleShoot-1 +# File: Makefile +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded instructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev$ +# $Author$ +#---------------------------------------------------------------------------- + +SUBDIRS = + +#---------------------------------------------------------------------------- +# コンポーネント選択 ( jackal ) + +export DEFAULT_COMP_ARM7 = jackal + +COMPONENT_DIR = $(TWL_IPL_RED_ROOT)/build/components/$(DEFAULT_COMP_ARM7).TWL +WRAM_MAP_FILE = $(COMPONENT_DIR)/wram_regs/wram_regs.rbin + +#---------------------------------------------------------------------------- + +TARGET_FIRM = SYSTEMMENU +TARGET_PLATFORM = TWL +TWL_ARCHGEN = LIMITED + +TARGET_NUMBER = 0 +TARGET_NAME = SimpleBenchmark$(TARGET_NUMBER) +BINDIR = ./bin/$(TWL_BUILDTYPE)/$(TARGET_NAME) +TARGET_BIN = $(TARGET_NAME).srl +LCFILE_SPEC = ARM9-TS.lsf +LCFILE_TEMPLATE = ARM9-TS.lcf.template + +TITLEID_LO = SB$(TARGET_NUMBER)A +#TARGET_TAD = $(BINDIR)/$(TITLEID_LO).$(TWL_BUILD_DIR)$(CODEGEN_ARCH).tad + +ROM_SPEC = main$(TARGET_NUMBER).rsf + +MISC_DIR = ../../../systemMenu_RED/misc + +SRCS = main.c SimpleBenchmark.c \ + $(MISC_DIR)/src/misc.c $(MISC_DIR)/src/cmn.c + +LINCLUDES = $(MISC_DIR)/include + +MAKEROM_FLAGS += -DTITLEID_LO='$(TITLEID_LO)' +#MAKETAD_FLAGS += -s + +include $(TWL_IPL_RED_ROOT)/build/buildtools/commondefs + +#MAKEROM = $(TWL_TOOLSDIR)/bin/makerom.TWL.secure.exe + +#LDIRT_CLEAN = $(TARGET_TAD) +ADDRESS_DTCM = 0x0e000000 + +MAKEROM_FLAGS += -DWRAM_MAP_FILE='$(WRAM_MAP_FILE)' +#---------------------------------------------------------------------------- + +do-build : $(TARGETS) + + +include $(TWL_IPL_RED_ROOT)/build/buildtools/modulerules + +#---------------------------------------------------------------------------- + +#===== End of Makefile ===== diff --git a/build/tests/SimpleBenchmark/ARM9/Makefile.1 b/build/tests/SimpleBenchmark/ARM9/Makefile.1 new file mode 100644 index 00000000..48db108c --- /dev/null +++ b/build/tests/SimpleBenchmark/ARM9/Makefile.1 @@ -0,0 +1,61 @@ +#! make -f +#---------------------------------------------------------------------------- +# Project: TwlSDK - demos - simpleShoot-1 +# File: Makefile +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded instructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev$ +# $Author$ +#---------------------------------------------------------------------------- + +SUBDIRS = + +#---------------------------------------------------------------------------- + +TARGET_FIRM = SYSTEMMENU +TARGET_PLATFORM = TWL +TWL_ARCHGEN = LIMITED + +TARGET_NUMBER = 1 +TARGET_NAME = SimpleBenchmark$(TARGET_NUMBER) +BINDIR = ./bin/$(TWL_BUILDTYPE)/$(TARGET_NAME) +TARGET_BIN = $(TARGET_NAME).srl +TITLEID_LO = SB$(TARGET_NUMBER)A +#TARGET_TAD = $(BINDIR)/$(TITLEID_LO).$(TWL_BUILD_DIR)$(CODEGEN_ARCH).tad + +ROM_SPEC = main$(TARGET_NUMBER).rsf + +MISC_DIR = ../../../systemMenu_RED/misc + +SRCS = main.c SimpleBenchmark.c \ + $(MISC_DIR)/src/misc.c $(MISC_DIR)/src/cmn.c + +LINCLUDES = $(MISC_DIR)/include + +MAKEROM_FLAGS += -DTITLEID_LO='$(TITLEID_LO)' +#MAKETAD_FLAGS += -s + +include $(TWL_IPL_RED_ROOT)/build/buildtools/commondefs + +#MAKEROM = $(TWL_TOOLSDIR)/bin/makerom.TWL.secure.exe + +#LDIRT_CLEAN = $(TARGET_TAD) + +#---------------------------------------------------------------------------- + +do-build : $(TARGETS) + + +include $(TWL_IPL_RED_ROOT)/build/buildtools/modulerules + +#---------------------------------------------------------------------------- + +#===== End of Makefile ===== diff --git a/build/tests/SimpleBenchmark/ARM9/main0.rsf b/build/tests/SimpleBenchmark/ARM9/main0.rsf new file mode 100644 index 00000000..7b576398 --- /dev/null +++ b/build/tests/SimpleBenchmark/ARM9/main0.rsf @@ -0,0 +1,204 @@ +#---------------------------------------------------------------------------- +# Project: TwlSDK - include +# File: ROM-BB.rsf +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded insructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev$ +# $Author$ +#---------------------------------------------------------------------------- +# +# TWL ROM SPEC FILE +# + +Arm9 +{ + Static "$(MAKEROM_ARM9:r).TWL.FLX.sbin$(COMPSUFFIX9)" + OverlayDefs "$(MAKEROM_ARM9:r)_defs.TWL.FLX.sbin$(COMPSUFFIX9)" + OverlayTable "$(MAKEROM_ARM9:r)_table.TWL.FLX.sbin$(COMPSUFFIX9)" + Elf "$(MAKEROM_ARM9:r).tef" +} + +Arm7 +{ + Static "$(MAKEROM_ARM7_BASE:r).TWL.FLX.sbin$(COMPSUFFIX7)" + OverlayDefs "$(MAKEROM_ARM7_BASE:r)_defs.TWL.FLX.sbin$(COMPSUFFIX7)" + OverlayTable "$(MAKEROM_ARM7_BASE:r)_table.TWL.FLX.sbin$(COMPSUFFIX7)" + Elf "$(MAKEROM_ARM7_BASE:r).tef" +} + +Arm9.Ltd +{ + Static "$(MAKEROM_ARM9:r).TWL.LTD.sbin$(COMPSUFFIX9)" + OverlayDefs "$(MAKEROM_ARM9:r)_defs.TWL.LTD.sbin$(COMPSUFFIX9)" + OverlayTable "$(MAKEROM_ARM9:r)_table.TWL.LTD.sbin$(COMPSUFFIX9)" +} + +Arm7.Ltd +{ + Static "$(MAKEROM_ARM7_BASE:r).TWL.LTD.sbin$(COMPSUFFIX7)" + OverlayDefs "$(MAKEROM_ARM7_BASE:r)_defs.TWL.LTD.sbin$(COMPSUFFIX7)" + OverlayTable "$(MAKEROM_ARM7_BASE:r)_table.TWL.LTD.sbin$(COMPSUFFIX7)" +} + +Property +{ + ### + ### Settings for FinalROM + ### + #### BEGIN + # + # TITLE NAME: Your product name within 12bytes + # + #TitleName "YourAppName" + + # + # MAKER CODE: Your company ID# in 2 ascii words + # issued by NINTENDO + # + #MakerCode "00" + + # + # REMASTER VERSION: Mastering version + # + #RomVersion 0 + + # + # ROM SPEED TYPE: [MROM/1TROM/UNDEFINED] + # + RomSpeedType $(MAKEROM_ROMSPEED) + + # + # ROM SIZE: in bit [64M/128M/256M/512M/1G/2G] + # + #RomSize 128M + #RomSize 256M + + # + # ROM PADDING: TRUE if finalrom + # + #RomFootPadding TRUE + + # + # ROM HEADER TEMPLATE: Provided to every product by NINTENDO + # + #RomHeaderTemplate ./etc/rom_header.template.sbin + + # + # BANNER FILE: generated from Banner Spec File + # + BannerFile ../banner/banner_0.bnr + + ### + ### Setting for TWL + ### + + # + # ROM HEADER Ltd: Provided to every product by NINTENDO + # + RomHeaderLtd $(TWLSDK_ROOT)/tools/bin/rom_header.LTD.sbin + + # + # Digest parameters: + # + DigestParam 1024 32 + + # + # WRAM mapping: [MAP_BB_HYB/MAP_BB_LTD/MAP_TS_HYB/MAP_TS_LTD] + # don't have to edit + # + WramMappingDirect $(WRAM_MAP_FILE) + + # + # CardRegion: card region [Japan/America/Europe/Australia/China/Korea] + # + CardRegion ALL + + # + # Codec mode: + # don't have to edit + # + CodecMode $(MAKEROM_CODEC_MODE) + + # + # SDCardAccess: sd card access control [TRUE/FALSE] + # + SDCardAccess TRUE + #SDCardAccess FALSE + + # + # NandAccess: nand access control [TRUE/FALSE] + # + #NANDAccess FALSE + + ### + #### END +} + + +AppendProperty +{ + # + # Publisher : "Nintendo" + # don't have to edit + Publisher Nintendo + + # + # Application type : [USER/SYSTEM] + # don't have to edit + AppType USER + #AppType SYSTEM + + # + # launch title on the launcher : [TRUE/FALSE] + # don't have to edit + Launch TRUE + + # + # Boot allowed Media: [GameCard/NAND] + # + #Media GameCard + Media NAND + + # + # Secure title : [TRUE/FALSE] + # don't have to edit + #Secure TRUE + Secure FALSE + + # + # GameCode for TitleID : Your GameCode in 4 ascii words + # + GameCode $(TITLEID_LO) + + # + # Public save data size: [16K/32K/64K/128K/256K/512K/1M/2M/4M/8M] + # + #PublicSaveDataSize 32K + + # + # Private save data size: [16K/32K/64K/128K/256K/512K/1M/2M/4M/8M] + # + #PrivateSaveDataSize 16K + + # + # Enable SubBannerFile + #SubBannerFile TRUE +} + + +RomSpec +{ + Offset 0x00000000 + Segment ALL + HostRoot ../../../systemMenu_RED/data + Root /data + File NTR_IPL_font_m.NFTR +} diff --git a/build/tests/SimpleBenchmark/ARM9/main1.rsf b/build/tests/SimpleBenchmark/ARM9/main1.rsf new file mode 100644 index 00000000..8045315d --- /dev/null +++ b/build/tests/SimpleBenchmark/ARM9/main1.rsf @@ -0,0 +1,204 @@ +#---------------------------------------------------------------------------- +# Project: TwlSDK - include +# File: ROM-BB.rsf +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded insructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev$ +# $Author$ +#---------------------------------------------------------------------------- +# +# TWL ROM SPEC FILE +# + +Arm9 +{ + Static "$(MAKEROM_ARM9:r).TWL.FLX.sbin$(COMPSUFFIX9)" + OverlayDefs "$(MAKEROM_ARM9:r)_defs.TWL.FLX.sbin$(COMPSUFFIX9)" + OverlayTable "$(MAKEROM_ARM9:r)_table.TWL.FLX.sbin$(COMPSUFFIX9)" + Elf "$(MAKEROM_ARM9:r).tef" +} + +Arm7 +{ + Static "$(MAKEROM_ARM7_BASE:r).TWL.FLX.sbin$(COMPSUFFIX7)" + OverlayDefs "$(MAKEROM_ARM7_BASE:r)_defs.TWL.FLX.sbin$(COMPSUFFIX7)" + OverlayTable "$(MAKEROM_ARM7_BASE:r)_table.TWL.FLX.sbin$(COMPSUFFIX7)" + Elf "$(MAKEROM_ARM7_BASE:r).tef" +} + +Arm9.Ltd +{ + Static "$(MAKEROM_ARM9:r).TWL.LTD.sbin$(COMPSUFFIX9)" + OverlayDefs "$(MAKEROM_ARM9:r)_defs.TWL.LTD.sbin$(COMPSUFFIX9)" + OverlayTable "$(MAKEROM_ARM9:r)_table.TWL.LTD.sbin$(COMPSUFFIX9)" +} + +Arm7.Ltd +{ + Static "$(MAKEROM_ARM7_BASE:r).TWL.LTD.sbin$(COMPSUFFIX7)" + OverlayDefs "$(MAKEROM_ARM7_BASE:r)_defs.TWL.LTD.sbin$(COMPSUFFIX7)" + OverlayTable "$(MAKEROM_ARM7_BASE:r)_table.TWL.LTD.sbin$(COMPSUFFIX7)" +} + +Property +{ + ### + ### Settings for FinalROM + ### + #### BEGIN + # + # TITLE NAME: Your product name within 12bytes + # + #TitleName "YourAppName" + + # + # MAKER CODE: Your company ID# in 2 ascii words + # issued by NINTENDO + # + #MakerCode "00" + + # + # REMASTER VERSION: Mastering version + # + #RomVersion 0 + + # + # ROM SPEED TYPE: [MROM/1TROM/UNDEFINED] + # + RomSpeedType $(MAKEROM_ROMSPEED) + + # + # ROM SIZE: in bit [64M/128M/256M/512M/1G/2G] + # + #RomSize 128M + #RomSize 256M + + # + # ROM PADDING: TRUE if finalrom + # + #RomFootPadding TRUE + + # + # ROM HEADER TEMPLATE: Provided to every product by NINTENDO + # + #RomHeaderTemplate ./etc/rom_header.template.sbin + + # + # BANNER FILE: generated from Banner Spec File + # + BannerFile ../banner/banner_1.bnr + + ### + ### Setting for TWL + ### + + # + # ROM HEADER Ltd: Provided to every product by NINTENDO + # + RomHeaderLtd $(TWLSDK_ROOT)/tools/bin/rom_header.LTD.sbin + + # + # Digest parameters: + # + DigestParam 1024 32 + + # + # WRAM mapping: [MAP_BB_HYB/MAP_BB_LTD/MAP_TS_HYB/MAP_TS_LTD] + # don't have to edit + # + WramMapping $(MAKEROM_WRAM_MAPPING) + + # + # CardRegion: card region [Japan/America/Europe/Australia/China/Korea] + # + CardRegion ALL + + # + # Codec mode: + # don't have to edit + # + CodecMode $(MAKEROM_CODEC_MODE) + + # + # SDCardAccess: sd card access control [TRUE/FALSE] + # + SDCardAccess TRUE + #SDCardAccess FALSE + + # + # NandAccess: nand access control [TRUE/FALSE] + # + NANDAccess TRUE + + ### + #### END +} + + +AppendProperty +{ + # + # Publisher : "Nintendo" + # don't have to edit + Publisher Nintendo + + # + # Application type : [USER/SYSTEM] + # don't have to edit + AppType USER + #AppType SYSTEM + + # + # launch title on the launcher : [TRUE/FALSE] + # don't have to edit + Launch TRUE + + # + # Boot allowed Media: [GameCard/NAND] + # + #Media GameCard + Media NAND + + # + # Secure title : [TRUE/FALSE] + # don't have to edit + #Secure TRUE + Secure FALSE + + # + # GameCode for TitleID : Your GameCode in 4 ascii words + # + GameCode $(TITLEID_LO) + + # + # Public save data size: [16K/32K/64K/128K/256K/512K/1M/2M/4M/8M] + # + #PublicSaveDataSize 32K + + # + # Private save data size: [16K/32K/64K/128K/256K/512K/1M/2M/4M/8M] + # + #PrivateSaveDataSize 16K + + # + # Enable SubBannerFile + #SubBannerFile TRUE +} + + +RomSpec +{ + Offset 0x00000000 + Segment ALL + HostRoot ../../../systemMenu_RED/data + Root /data + File NTR_IPL_font_m.NFTR +} diff --git a/build/tests/SimpleBenchmark/ARM9/src/SimpleBenchmark.c b/build/tests/SimpleBenchmark/ARM9/src/SimpleBenchmark.c new file mode 100644 index 00000000..39e8b06a --- /dev/null +++ b/build/tests/SimpleBenchmark/ARM9/src/SimpleBenchmark.c @@ -0,0 +1,81 @@ +/*---------------------------------------------------------------------------* + Project: TwlIPL + File: DS_Chat.c + + Copyright 2007 Nintendo. All rights reserved. + + These coded instructions, statements, and computer programs contain + proprietary information of Nintendo of America Inc. and/or Nintendo + Company Ltd., and are protected by Federal copyright law. They may + not be disclosed to third parties or copied or duplicated in any form, + in whole or in part, without the prior written consent of Nintendo. + + $Date:: $ + $Rev$ + $Author$ + *---------------------------------------------------------------------------*/ + +#include +#include +#include "misc.h" +#include "SimpleBenchmark.h" + +// define data------------------------------------------ +#define RETURN_BUTTON_TOP_X 2 +#define RETURN_BUTTON_TOP_Y 21 +#define RETURN_BUTTON_BOTTOM_X ( RETURN_BUTTON_TOP_X + 8 ) +#define RETURN_BUTTON_BOTTOM_Y ( RETURN_BUTTON_TOP_Y + 2 ) + +// extern data------------------------------------------ + +// function's prototype declaration--------------------- + +// global variable ------------------------------------- +RTCDrawProperty g_rtcDraw = { + TRUE, RTC_DATE_TOP_X, RTC_DATE_TOP_Y, RTC_TIME_TOP_X, RTC_TIME_TOP_Y +}; + +// テストプログラムの初期化 +void SimpleBenchmarkInit( void ) +{ + GX_DispOff(); + GXS_DispOff(); + NNS_G2dCharCanvasClear( &gCanvas, TXT_COLOR_WHITE ); + + PutStringUTF16( 1 * 8, 0 * 8, TXT_COLOR_BLUE, (const u16 *)L"SimpleBenchmarkTest"); + GetAndDrawRTCData( &g_rtcDraw, TRUE ); + + GXS_SetVisiblePlane( GX_PLANEMASK_BG0 ); + GX_DispOn(); + GXS_DispOn(); +} + + +// テストプログラムのメインループ +void SimpleBenchmarkMain(void) +{ + BOOL tp_cancel = FALSE; + + + ReadTP(); // タッチパネル入力の取得 + + // [RETURN]ボタン押下チェック + if(tpd.disp.touch) { + tp_cancel = WithinRangeTP( RETURN_BUTTON_TOP_X * 8, RETURN_BUTTON_TOP_Y * 8 - 4, + RETURN_BUTTON_BOTTOM_X * 8, RETURN_BUTTON_BOTTOM_Y * 8 - 4, &tpd.disp ); + } + + if( ( pad.trg & PAD_BUTTON_A ) ) { + } + + if( ( pad.trg & PAD_BUTTON_X ) ) { + } + + if( ( pad.trg & PAD_BUTTON_B ) || tp_cancel ) { +// SYSM_RebootLauncher(); + } + + GetAndDrawRTCData( &g_rtcDraw, FALSE ); +} + + diff --git a/build/tests/SimpleBenchmark/ARM9/src/SimpleBenchmark.h b/build/tests/SimpleBenchmark/ARM9/src/SimpleBenchmark.h new file mode 100644 index 00000000..c62094e6 --- /dev/null +++ b/build/tests/SimpleBenchmark/ARM9/src/SimpleBenchmark.h @@ -0,0 +1,36 @@ +/*---------------------------------------------------------------------------* + Project: TwlIPL + File: RomTypeTest.h + + Copyright 2007 Nintendo. All rights reserved. + + These coded instructions, statements, and computer programs contain + proprietary information of Nintendo of America Inc. and/or Nintendo + Company Ltd., and are protected by Federal copyright law. They may + not be disclosed to third parties or copied or duplicated in any form, + in whole or in part, without the prior written consent of Nintendo. + + $Date:: $ + $Rev$ + $Author$ + *---------------------------------------------------------------------------*/ + +#ifndef __SIMPLE_BENCHMARK_H__ +#define __SIMPLE_BENCHMARK_H__ + +#ifdef __cplusplus +extern "C" { +#endif + +#include + +// define data---------------------------------------------------------- + +void SimpleBenchmarkInit( void ); +void SimpleBenchmarkMain( void ); + +#ifdef __cplusplus +} +#endif + +#endif // __SIMPLE_BENCHMARK_H__ diff --git a/build/tests/SimpleBenchmark/ARM9/src/main.c b/build/tests/SimpleBenchmark/ARM9/src/main.c new file mode 100644 index 00000000..7bac66bc --- /dev/null +++ b/build/tests/SimpleBenchmark/ARM9/src/main.c @@ -0,0 +1,86 @@ +/*---------------------------------------------------------------------------* + Project: TwlIPL + File: main.c + + Copyright 2007 Nintendo. All rights reserved. + + These coded instructions, statements, and computer programs contain + proprietary information of Nintendo of America Inc. and/or Nintendo + Company Ltd., and are protected by Federal copyright law. They may + not be disclosed to third parties or copied or duplicated in any form, + in whole or in part, without the prior written consent of Nintendo. + + $Date:: $ + $Rev$ + $Author$ + *---------------------------------------------------------------------------*/ + +#include +#include "misc.h" +#include "SimpleBenchmark.h" + +// extern data----------------------------------------------------------------- + +// define data----------------------------------------------------------------- + +// function's prototype------------------------------------------------------- +static void INTR_VBlank( void ); + +// global variable------------------------------------------------------------- + +// static variable------------------------------------------------------------- + +// const data------------------------------------------------------------------ + + +// ============================================================================ +// function's description +// ============================================================================ +void TwlMain(void) +{ + + // 初期化---------------------------------- + OS_Init(); + + (void)OS_EnableIrq(); + (void)OS_EnableInterrupts(); + + GX_Init(); + GX_SetPower(GX_POWER_ALL); // 各ロジック パワーON + + // 割り込み許可---------------------------- + (void)OS_SetIrqFunction(OS_IE_V_BLANK, INTR_VBlank); + (void)OS_EnableIrqMask(OS_IE_V_BLANK); + (void)GX_VBlankIntr(TRUE); + + // デバイス初期化------------------------------- + TP_Init(); + (void)RTC_Init(); + + // システムの初期化------------------ + InitAllocator(); + + InitBG(); + SimpleBenchmarkInit(); + // メインループ---------------------------- + while(1){ + OS_WaitIrq(1, OS_IE_V_BLANK); // Vブランク割り込み待ち + + ReadKeyPad(); // キー入力の取得 + ReadTP(); // TP入力の取得 + + SimpleBenchmarkMain(); + } +} + + +// ============================================================================ +// 割り込み処理 +// ============================================================================ + +// Vブランク割り込み +static void INTR_VBlank(void) +{ + OS_SetIrqCheckFlag(OS_IE_V_BLANK); // Vブランク割込チェックのセット +} + diff --git a/build/tests/SimpleBenchmark/Makefile b/build/tests/SimpleBenchmark/Makefile new file mode 100644 index 00000000..66754bca --- /dev/null +++ b/build/tests/SimpleBenchmark/Makefile @@ -0,0 +1,30 @@ +#! make -f +#---------------------------------------------------------------------------- +# Project: TwlIPL +# File: Makefile +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded instructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev$ +# $Author$ +#---------------------------------------------------------------------------- + +include $(TWLSDK_ROOT)/build/buildtools/commondefs + +#---------------------------------------------------------------------------- + +SUBDIRS = banner ARM9 + +#---------------------------------------------------------------------------- + +include $(TWLSDK_ROOT)/build/buildtools/modulerules + + +#===== End of Makefile ===== diff --git a/build/tests/SimpleBenchmark/banner/Makefile b/build/tests/SimpleBenchmark/banner/Makefile new file mode 100644 index 00000000..a11fb47a --- /dev/null +++ b/build/tests/SimpleBenchmark/banner/Makefile @@ -0,0 +1,32 @@ +#! make -f +#---------------------------------------------------------------------------- +# Project: TwlIPL +# File: Makefile +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded instructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev$ +# $Author$ +#---------------------------------------------------------------------------- + +include $(TWL_IPL_RED_ROOT)/build/buildtools/commondefs + +SUBDIRS = +SUBMAKES = Makefile.0 Makefile.1 + +include $(TWL_IPL_RED_ROOT)/build/buildtools/modulerules + +#---------------------------------------------------------------------------- +# build +#---------------------------------------------------------------------------- +do-build: $(TARGETS) + + +# diff --git a/build/tests/SimpleBenchmark/banner/Makefile.0 b/build/tests/SimpleBenchmark/banner/Makefile.0 new file mode 100644 index 00000000..97c32d52 --- /dev/null +++ b/build/tests/SimpleBenchmark/banner/Makefile.0 @@ -0,0 +1,48 @@ +#! make -f +#---------------------------------------------------------------------------- +# Project: TwlIPL +# File: Makefile +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded instructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev$ +# $Author$ +#---------------------------------------------------------------------------- + +include $(TWL_IPL_RED_ROOT)/build/buildtools/commondefs + +BNRNUM = 0 + +ICON_DIR = ./icon + +BANNER_SPEC = test-utf16_$(BNRNUM)_v3.TWL.bsf + +MAKEBANNER = $(TWL_TOOLSDIR)/bin/makebanner.TWL.exe + +TARGETS = banner_$(BNRNUM).bnr +INSTALL_DIR = ./ +INSTALL_TARGETS = $(TARGETS) + +BANNER_ICON_NAME = $(basename $(BANNER_ICON)) + +LDIRT_CLEAN = $(TARGETS) \ + $(TARGETS:.bnr=.srl) + +include $(TWL_IPL_RED_ROOT)/build/buildtools/modulerules + +#---------------------------------------------------------------------------- +# build +#---------------------------------------------------------------------------- +do-build: $(TARGETS) + +$(TARGETS): $(BANNER_SPEC) + $(MAKEBANNER) -p TWL $(BANNER_SPEC) $(TARGETS) + +# diff --git a/build/tests/SimpleBenchmark/banner/Makefile.1 b/build/tests/SimpleBenchmark/banner/Makefile.1 new file mode 100644 index 00000000..54f8cd07 --- /dev/null +++ b/build/tests/SimpleBenchmark/banner/Makefile.1 @@ -0,0 +1,48 @@ +#! make -f +#---------------------------------------------------------------------------- +# Project: TwlIPL +# File: Makefile +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded instructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev$ +# $Author$ +#---------------------------------------------------------------------------- + +include $(TWL_IPL_RED_ROOT)/build/buildtools/commondefs + +BNRNUM = 1 + +ICON_DIR = ./icon + +BANNER_SPEC = test-utf16_$(BNRNUM)_v3.TWL.bsf + +MAKEBANNER = $(TWL_TOOLSDIR)/bin/makebanner.TWL.exe + +TARGETS = banner_$(BNRNUM).bnr +INSTALL_DIR = ./ +INSTALL_TARGETS = $(TARGETS) + +BANNER_ICON_NAME = $(basename $(BANNER_ICON)) + +LDIRT_CLEAN = $(TARGETS) \ + $(TARGETS:.bnr=.srl) + +include $(TWL_IPL_RED_ROOT)/build/buildtools/modulerules + +#---------------------------------------------------------------------------- +# build +#---------------------------------------------------------------------------- +do-build: $(TARGETS) + +$(TARGETS): $(BANNER_SPEC) + $(MAKEBANNER) -p TWL $(BANNER_SPEC) $(TARGETS) + +# diff --git a/build/tests/SimpleBenchmark/banner/banner_v3.bsf b/build/tests/SimpleBenchmark/banner/banner_v3.bsf new file mode 100644 index 0000000000000000000000000000000000000000..d595b6d35b72e52619f29b85a7cea0a85f471335 GIT binary patch literal 762 zcmc(dK}!QM5QX2hg8v~<5IkrR!9$Ohu3Abdt_mL0tb9)y>^dE zV93mSJNw>be!jc9Rjy1%7x5T!s}<)>71dmy+zM`)oR-{Ab)s&=PT%}ZO#d}{(gGzl ziryPVMy1wNJhd4LjkaiaMXc>L03@c^nuYz(jhut!^0RvH$F0knzW#q9$U~moFDJ}z>JQgd8?{HqiSEC9Y(wJ*Wly6 zRcU(T6b&w`xQjJ=XX9JWnaNCF#09x$H~Z>ww#=h~HP(I-nf#Th!L($%5DJTha5`L6s@6ybjn%yN? zRVW_*0osgCYX1V0`n@z_{lZ=Hx%bU`@A8@_&L(AYupeOU!w*rG$gwV8ui2t-`7iaqoEDpxIr^P)f#UzZs0(QsSQt*9@9H z*U3v5MlA`>$3ypd0Ws4kX6(5P%~hCrn6d8-ZIr0!CTmG}KJ`8Ox(K$a)mjo=1^(DR zlKT~IHO*QIp87UQG{g@FzWx6i%$v+YJPf8_r_m8j%SxZFq9Ev^d_#&;uyeTxf$IPUVA8!~?UxO+tjABKw#Pv@%p@SbJx+)K&RSUtYI zM^R?D(L7gj@riN8O5JOQK|)+$ERN>6Qcw6G>w%}RDy5=41OJE4wek$NdgyDSZ$-Qi AC;$Ke literal 0 HcmV?d00001 diff --git a/build/tests/SimpleBenchmark/banner/icon/msk_pictchat_icon.bin b/build/tests/SimpleBenchmark/banner/icon/msk_pictchat_icon.bin new file mode 100644 index 0000000000000000000000000000000000000000..5b2734aa29fe5a7cc1474fd910a9f00b579e0a4b GIT binary patch literal 4480 zcmeHKJ#Q015Ou!H6)6~qMFFxP5(P>HS0O5hMMHJPrU*((r$~Vi#T7C5Z_VA>o4@S`d;40Nt*5jG@JWUM3#MJ4q~&_3TU_60<<4u z(vY8HU>0jS59BGzd6q4m1s*wsXtfRkNWu_4eh7W8EL(0>N)YKXU{^PsxCBni8~dtE^N z*MIc&54F!dKx>~K`psO>Hq@jT>VJXPnuMqR=w!(H&sUu*LVVkbMD3$@RE zpji979$f#nKJ)r_{p)jD($%l6f6d;P?^FMUcw7Iv_tW>Qf9^ACsM}ze+iTqa1#7^< ztk#7{2T|HBg@zQz5Vb_Hs1$jW{ImiE#gy3bEM|~ELTKJz-XMoV z>%a)k01LMQ5Izd}3(kOn^{>yPI-@C9gGa7=;FY3>!3|aat{2x47a=p+e*M4#k4&T; zn~&>?^-ukU_3xCjKl4kh4;uBiHw!dh9k_aww`YH!{huK>Nq@ZQV7T^?y>riRCxUZP zpxMB&xEfM_?LP~K8O;>9@-~3ZhSmRkzkduD^l$hjcej{~sTpJU(0NHom2wJ~ZAfu0CJ+wfuc?XW{m%2P@s>wT03@ vZsoCPTro5DtQ5^h6V=kWJCo5=wbavUBATz3s^#*nGVr<_O+}N{E6vnzcJN>n literal 0 HcmV?d00001 diff --git a/build/tests/SimpleBenchmark/banner/test-utf16_0_v3.TWL.bsf b/build/tests/SimpleBenchmark/banner/test-utf16_0_v3.TWL.bsf new file mode 100644 index 0000000000000000000000000000000000000000..1e2379a91e4012ab13b5fa7993a407d9b3872cdd GIT binary patch literal 786 zcmbVKO$&lR6r8I;|3TcazMA(o3py^#>g;o7-n_-v zvxNy__;AtD2*rUV+TV|D7#eHViij|tv#f~`pCJYfV zhpQ7x(p+boFkhx>NnOxWrVWYr#0fcao?&UF^;Fqb4<9Q_4^bMAIsI&A@E}U#5nyfU dAxh&BTi&I|zbpE9Os(%!lqSc*+C!Aa;|rVGl|wlXTJ7SLfbIgOc#=%X^4mH0IQ^(-5Z72(Y%) d5T?B-xYo}rq*XFOp{|_tszXK@d2_TdaM8d literal 0 HcmV?d00001