<reponame>loveemu/ida-scripts-vg
regs = [
    (0x4000004, "DISPSTAT", "General LCD Status (Read/Write)"),
    (0x4000006, "VCOUNT", "General LCD Status (Read/Write)"),
    (0x40000b0, "DMA0SAD", "DMA 0 Source Address"),
    (0x40000b4, "DMA0DAD", "DMA 0 Destination Address"),
    (0x40000b8, "DMA0CNT_L", "DMA 0 Word Count"),
    (0x40000ba, "DMA0CNT_H", "DMA 0 Control"),
    (0x40000bc, "DMA1SAD", "DMA 1 Source Address"),
    (0x40000c0, "DMA1DAD", "DMA 1 Destination Address"),
    (0x40000c4, "DMA1CNT_L", "DMA 1 Word Count"),
    (0x40000c6, "DMA1CNT_H", "DMA 1 Control"),
    (0x40000c8, "DMA2SAD", "DMA 2 Source Address"),
    (0x40000cc, "DMA2DAD", "DMA 2 Destination Address"),
    (0x40000d0, "DMA2CNT_L", "DMA 2 Word Count"),
    (0x40000d2, "DMA2CNT_H", "DMA 2 Control"),
    (0x40000d4, "DMA3SAD", "DMA 3 Source Address"),
    (0x40000d8, "DMA3DAD", "DMA 3 Destination Address"),
    (0x40000dc, "DMA3CNT_L", "DMA 3 Word Count"),
    (0x40000de, "DMA3CNT_H", "DMA 3 Control"),
    (0x4000100, "TM0D", "Timer 0 Counter/Reload"),
    (0x4000102, "TM0CNT", "Timer 0 Control"),
    (0x4000104, "TM1D", "Timer 1 Counter/Reload"),
    (0x4000106, "TM1CNT", "Timer 1 Control"),
    (0x4000108, "TM2D", "Timer 2 Counter/Reload"),
    (0x400010a, "TM2CNT", "Timer 2 Control"),
    (0x400010c, "TM3D", "Timer 3 Counter/Reload"),
    (0x400010e, "TM3CNT", "Timer 3 Control"),
    (0x4000120, "SIOMULTI0", "SIO Data 0 (Parent)    (Multi-Player Mode; shared with SIODATA32)"),
    (0x4000122, "SIOMULTI1", "SIO Data 1 (1st Child) (Multi-Player Mode)"),
    (0x4000124, "SIOMULTI2", "SIO Data 1 (2nd Child) (Multi-Player Mode)"),
    (0x4000126, "SIOMULTI3", "SIO Data 1 (3rd Child) (Multi-Player Mode)"),
    (0x4000128, "SIOCNT", "SIO Control Register"),
    (0x400012a, "SIOMLT_SEND", "SIO Data (Local of MultiPlayer; shared with SIODATA8)"),
    (0x400012c, "SIOSEL", ""),
    (0x4000130, "KEYINPUT", "Key Status"),
    (0x4000132, "KEYCNT", "Key Interrupt Control"),
    (0x4000134, "RCNT", "SIO Mode Select/General Purpose Data"),
    (0x4000136, "EXTKEYIN", "Key X/Y Input"),
    (0x4000138, "RTC_CR", "RTC Realtime Clock Bus"),
    (0x4000140, "JOYCNT", "JOY BUS Control Register"),
    (0x4000180, "IPCSYNC", "IPC Synchronize Register (R/W)"),
    (0x4000184, "IPCFIFOCNT", "IPC Fifo Control Register (R/W)"),
    (0x4000188, "IPCFIFOSEND", "IPC Send Fifo (W)"),
    (0x40001a0, "AUXSPICNT", "Gamecard ROM and SPI Control"),
    (0x40001a2, "AUXSPIDATA", "Gamecard SPI Bus Data/Strobe"),
    (0x40001a4, "CARD_CR2", "Gamecard bus timing/control"),
    (0x40001a8, "CARD_COMMAND", "Gamecard bus 8-byte command out"),
    (0x40001b0, "CARD_1B0", "Gamecard Encryption Seed 0 Lower 32bit"),
    (0x40001b4, "CARD_1B4", "Gamecard Encryption Seed 1 Lower 32bit"),
    (0x40001b8, "CARD_1B8", "Gamecard Encryption Seed 0 Upper 7bit (bit7-15 unused)"),
    (0x40001ba, "CARD_1BA", "Gamecard Encryption Seed 1 Upper 7bit (bit7-15 unused)"),
    (0x40001c0, "SPICNT", "SPI bus Control (Firmware, Touchscreen, Powerman)"),
    (0x40001c2, "SPIDATA", "SPI bus Data"),
    (0x4000204, "EXMEMSTAT", "External Memory Status"),
    (0x4000206, "WIFIWAITCNT", "Wifi Waitstate Control"),
    (0x4000208, "IME", "Interrupt Master Enable (R/W)"),
    (0x4000210, "IE", "Interrupt Enable (R/W)"),
    (0x4000214, "IF", "Interrupt Request Flags (R/W)"),
    (0x4000240, "VRAMSTAT", "VRAM-C,D Bank Status (R)"),
    (0x4000241, "WRAMSTAT", "WRAM Bank Status (R)"),
    (0x4000300, "POSTFLG", "Post Boot Flag"),
    (0x4000301, "HALTCNT", "Power Down Control"),
    (0x4000304, "POWCNT2", "Sound/Wifi Power Control Register (R/W)"),
    (0x4000308, "BIOSPROT", "Bios-data-read-protection address"),
    (0x4000400, "SOUND0CNT", "Sound Channel 0 Control Register (R/W)"),
    (0x4000404, "SOUND0SAD", "Sound Channel 0 Data Source Register (W)"),
    (0x4000408, "SOUND0TMR", "Sound Channel 0 Timer Register (W)"),
    (0x400040a, "SOUND0PNT", "Sound Channel 0 Loopstart Register (W)"),
    (0x400040c, "SOUND0LEN", "Sound Channel 0 Length Register (W)"),
    (0x4000410, "SOUND1CNT", "Sound Channel 1 Control Register (R/W)"),
    (0x4000414, "SOUND1SAD", "Sound Channel 1 Data Source Register (W)"),
    (0x4000418, "SOUND1TMR", "Sound Channel 1 Timer Register (W)"),
    (0x400041a, "SOUND1PNT", "Sound Channel 1 Loopstart Register (W)"),
    (0x400041c, "SOUND1LEN", "Sound Channel 1 Length Register (W)"),
    (0x4000420, "SOUND2CNT", "Sound Channel 2 Control Register (R/W)"),
    (0x4000424, "SOUND2SAD", "Sound Channel 2 Data Source Register (W)"),
    (0x4000428, "SOUND2TMR", "Sound Channel 2 Timer Register (W)"),
    (0x400042a, "SOUND2PNT", "Sound Channel 2 Loopstart Register (W)"),
    (0x400042c, "SOUND2LEN", "Sound Channel 2 Length Register (W)"),
    (0x4000430, "SOUND3CNT", "Sound Channel 3 Control Register (R/W)"),
    (0x4000434, "SOUND3SAD", "Sound Channel 3 Data Source Register (W)"),
    (0x4000438, "SOUND3TMR", "Sound Channel 3 Timer Register (W)"),
    (0x400043a, "SOUND3PNT", "Sound Channel 3 Loopstart Register (W)"),
    (0x400043c, "SOUND3LEN", "Sound Channel 3 Length Register (W)"),
    (0x4000440, "SOUND4CNT", "Sound Channel 4 Control Register (R/W)"),
    (0x4000444, "SOUND4SAD", "Sound Channel 4 Data Source Register (W)"),
    (0x4000448, "SOUND4TMR", "Sound Channel 4 Timer Register (W)"),
    (0x400044a, "SOUND4PNT", "Sound Channel 4 Loopstart Register (W)"),
    (0x400044c, "SOUND4LEN", "Sound Channel 4 Length Register (W)"),
    (0x4000450, "SOUND5CNT", "Sound Channel 5 Control Register (R/W)"),
    (0x4000454, "SOUND5SAD", "Sound Channel 5 Data Source Register (W)"),
    (0x4000458, "SOUND5TMR", "Sound Channel 5 Timer Register (W)"),
    (0x400045a, "SOUND5PNT", "Sound Channel 5 Loopstart Register (W)"),
    (0x400045c, "SOUND5LEN", "Sound Channel 5 Length Register (W)"),
    (0x4000460, "SOUND6CNT", "Sound Channel 6 Control Register (R/W)"),
    (0x4000464, "SOUND6SAD", "Sound Channel 6 Data Source Register (W)"),
    (0x4000468, "SOUND6TMR", "Sound Channel 6 Timer Register (W)"),
    (0x400046a, "SOUND6PNT", "Sound Channel 6 Loopstart Register (W)"),
    (0x400046c, "SOUND6LEN", "Sound Channel 6 Length Register (W)"),
    (0x4000470, "SOUND7CNT", "Sound Channel 7 Control Register (R/W)"),
    (0x4000474, "SOUND7SAD", "Sound Channel 7 Data Source Register (W)"),
    (0x4000478, "SOUND7TMR", "Sound Channel 7 Timer Register (W)"),
    (0x400047a, "SOUND7PNT", "Sound Channel 7 Loopstart Register (W)"),
    (0x400047c, "SOUND7LEN", "Sound Channel 7 Length Register (W)"),
    (0x4000480, "SOUND8CNT", "Sound Channel 8 Control Register (R/W)"),
    (0x4000484, "SOUND8SAD", "Sound Channel 8 Data Source Register (W)"),
    (0x4000488, "SOUND8TMR", "Sound Channel 8 Timer Register (W)"),
    (0x400048a, "SOUND8PNT", "Sound Channel 8 Loopstart Register (W)"),
    (0x400048c, "SOUND8LEN", "Sound Channel 8 Length Register (W)"),
    (0x4000490, "SOUND9CNT", "Sound Channel 9 Control Register (R/W)"),
    (0x4000494, "SOUND9SAD", "Sound Channel 9 Data Source Register (W)"),
    (0x4000498, "SOUND9TMR", "Sound Channel 9 Timer Register (W)"),
    (0x400049a, "SOUND9PNT", "Sound Channel 9 Loopstart Register (W)"),
    (0x400049c, "SOUND9LEN", "Sound Channel 9 Length Register (W)"),
    (0x40004a0, "SOUND10CNT", "Sound Channel 10 Control Register (R/W)"),
    (0x40004a4, "SOUND10SAD", "Sound Channel 10 Data Source Register (W)"),
    (0x40004a8, "SOUND10TMR", "Sound Channel 10 Timer Register (W)"),
    (0x40004aa, "SOUND10PNT", "Sound Channel 10 Loopstart Register (W)"),
    (0x40004ac, "SOUND10LEN", "Sound Channel 10 Length Register (W)"),
    (0x40004b0, "SOUND11CNT", "Sound Channel 11 Control Register (R/W)"),
    (0x40004b4, "SOUND11SAD", "Sound Channel 11 Data Source Register (W)"),
    (0x40004b8, "SOUND11TMR", "Sound Channel 11 Timer Register (W)"),
    (0x40004ba, "SOUND11PNT", "Sound Channel 11 Loopstart Register (W)"),
    (0x40004bc, "SOUND11LEN", "Sound Channel 11 Length Register (W)"),
    (0x40004c0, "SOUND12CNT", "Sound Channel 12 Control Register (R/W)"),
    (0x40004c4, "SOUND12SAD", "Sound Channel 12 Data Source Register (W)"),
    (0x40004c8, "SOUND12TMR", "Sound Channel 12 Timer Register (W)"),
    (0x40004ca, "SOUND12PNT", "Sound Channel 12 Loopstart Register (W)"),
    (0x40004cc, "SOUND12LEN", "Sound Channel 12 Length Register (W)"),
    (0x40004d0, "SOUND13CNT", "Sound Channel 13 Control Register (R/W)"),
    (0x40004d4, "SOUND13SAD", "Sound Channel 13 Data Source Register (W)"),
    (0x40004d8, "SOUND13TMR", "Sound Channel 13 Timer Register (W)"),
    (0x40004da, "SOUND13PNT", "Sound Channel 13 Loopstart Register (W)"),
    (0x40004dc, "SOUND13LEN", "Sound Channel 13 Length Register (W)"),
    (0x40004e0, "SOUND14CNT", "Sound Channel 14 Control Register (R/W)"),
    (0x40004e4, "SOUND14SAD", "Sound Channel 14 Data Source Register (W)"),
    (0x40004e8, "SOUND14TMR", "Sound Channel 14 Timer Register (W)"),
    (0x40004ea, "SOUND14PNT", "Sound Channel 14 Loopstart Register (W)"),
    (0x40004ec, "SOUND14LEN", "Sound Channel 14 Length Register (W)"),
    (0x40004f0, "SOUND15CNT", "Sound Channel 15 Control Register (R/W)"),
    (0x40004f4, "SOUND15SAD", "Sound Channel 15 Data Source Register (W)"),
    (0x40004f8, "SOUND15TMR", "Sound Channel 15 Timer Register (W)"),
    (0x40004fa, "SOUND15PNT", "Sound Channel 15 Loopstart Register (W)"),
    (0x40004fc, "SOUND15LEN", "Sound Channel 15 Length Register (W)"),
    (0x4000500, "SOUNDCNT", "Sound Control Register (R/W)"),
    (0x4000504, "SOUNDBIAS", "Sound Bias Register (R/W)"),
    (0x4000508, "SNDCAP0CNT", "Sound Capture 0 Control Register (R/W)"),
    (0x4000509, "SNDCAP1CNT", "Sound Capture 1 Control Register (R/W)"),
    (0x4000510, "SNDCAP0DAD", "Sound Capture 0 Destination Address (R/W)"),
    (0x4000514, "SNDCAP0LEN", "Sound Capture 0 Length (W)"),
    (0x4000518, "SNDCAP1DAD", "Sound Capture 1 Destination Address (R/W)"),
    (0x400051c, "SNDCAP1LEN", "Sound Capture 1 Length (W)"),
    (0x4100000, "IPCFIFORECV", "IPC Receive Fifo (R)"),
    (0x4100010, "CARD_DATA_RD", "Gamecard bus 4-byte data in, for manual or dma read"),
]

for (ea, name, comment) in regs:
    if name:
        idc.set_name(ea, name, SN_CHECK)
    if comment:
        idc.set_cmt(ea, comment, 1)

regs = [
    (0x4000004, "DISPSTAT", "General LCD Status (Read/Write)"),
    (0x4000006, "VCOUNT", "General LCD Status (Read/Write)"),
    (0x40000b0, "DMA0SAD", "DMA 0 Source Address"),
    (0x40000b4, "DMA0DAD", "DMA 0 Destination Address"),
    (0x40000b8, "DMA0CNT_L", "DMA 0 Word Count"),
    (0x40000ba, "DMA0CNT_H", "DMA 0 Control"),
    (0x40000bc, "DMA1SAD", "DMA 1 Source Address"),
    (0x40000c0, "DMA1DAD", "DMA 1 Destination Address"),
    (0x40000c4, "DMA1CNT_L", "DMA 1 Word Count"),
    (0x40000c6, "DMA1CNT_H", "DMA 1 Control"),
    (0x40000c8, "DMA2SAD", "DMA 2 Source Address"),
    (0x40000cc, "DMA2DAD", "DMA 2 Destination Address"),
    (0x40000d0, "DMA2CNT_L", "DMA 2 Word Count"),
    (0x40000d2, "DMA2CNT_H", "DMA 2 Control"),
    (0x40000d4, "DMA3SAD", "DMA 3 Source Address"),
    (0x40000d8, "DMA3DAD", "DMA 3 Destination Address"),
    (0x40000dc, "DMA3CNT_L", "DMA 3 Word Count"),
    (0x40000de, "DMA3CNT_H", "DMA 3 Control"),
    (0x4000100, "TM0D", "Timer 0 Counter/Reload"),
    (0x4000102, "TM0CNT", "Timer 0 Control"),
    (0x4000104, "TM1D", "Timer 1 Counter/Reload"),
    (0x4000106, "TM1CNT", "Timer 1 Control"),
    (0x4000108, "TM2D", "Timer 2 Counter/Reload"),
    (0x400010a, "TM2CNT", "Timer 2 Control"),
    (0x400010c, "TM3D", "Timer 3 Counter/Reload"),
    (0x400010e, "TM3CNT", "Timer 3 Control"),
    (0x4000120, "SIOMULTI0", "SIO Data 0 (Parent)    (Multi-Player Mode; shared with SIODATA32)"),
    (0x4000122, "SIOMULTI1", "SIO Data 1 (1st Child) (Multi-Player Mode)"),
    (0x4000124, "SIOMULTI2", "SIO Data 1 (2nd Child) (Multi-Player Mode)"),
    (0x4000126, "SIOMULTI3", "SIO Data 1 (3rd Child) (Multi-Player Mode)"),
    (0x4000128, "SIOCNT", "SIO Control Register"),
    (0x400012a, "SIOMLT_SEND", "SIO Data (Local of MultiPlayer; shared with SIODATA8)"),
    (0x400012c, "SIOSEL", ""),
    (0x4000130, "KEYINPUT", "Key Status"),
    (0x4000132, "KEYCNT", "Key Interrupt Control"),
    (0x4000134, "RCNT", "SIO Mode Select/General Purpose Data"),
    (0x4000136, "EXTKEYIN", "Key X/Y Input"),
    (0x4000138, "RTC_CR", "RTC Realtime Clock Bus"),
    (0x4000140, "JOYCNT", "JOY BUS Control Register"),
    (0x4000180, "IPCSYNC", "IPC Synchronize Register (R/W)"),
    (0x4000184, "IPCFIFOCNT", "IPC Fifo Control Register (R/W)"),
    (0x4000188, "IPCFIFOSEND", "IPC Send Fifo (W)"),
    (0x40001a0, "AUXSPICNT", "Gamecard ROM and SPI Control"),
    (0x40001a2, "AUXSPIDATA", "Gamecard SPI Bus Data/Strobe"),
    (0x40001a4, "CARD_CR2", "Gamecard bus timing/control"),
    (0x40001a8, "CARD_COMMAND", "Gamecard bus 8-byte command out"),
    (0x40001b0, "CARD_1B0", "Gamecard Encryption Seed 0 Lower 32bit"),
    (0x40001b4, "CARD_1B4", "Gamecard Encryption Seed 1 Lower 32bit"),
    (0x40001b8, "CARD_1B8", "Gamecard Encryption Seed 0 Upper 7bit (bit7-15 unused)"),
    (0x40001ba, "CARD_1BA", "Gamecard Encryption Seed 1 Upper 7bit (bit7-15 unused)"),
    (0x40001c0, "SPICNT", "SPI bus Control (Firmware, Touchscreen, Powerman)"),
    (0x40001c2, "SPIDATA", "SPI bus Data"),
    (0x4000204, "EXMEMSTAT", "External Memory Status"),
    (0x4000206, "WIFIWAITCNT", "Wifi Waitstate Control"),
    (0x4000208, "IME", "Interrupt Master Enable (R/W)"),
    (0x4000210, "IE", "Interrupt Enable (R/W)"),
    (0x4000214, "IF", "Interrupt Request Flags (R/W)"),
    (0x4000240, "VRAMSTAT", "VRAM-C,D Bank Status (R)"),
    (0x4000241, "WRAMSTAT", "WRAM Bank Status (R)"),
    (0x4000300, "POSTFLG", "Post Boot Flag"),
    (0x4000301, "HALTCNT", "Power Down Control"),
    (0x4000304, "POWCNT2", "Sound/Wifi Power Control Register (R/W)"),
    (0x4000308, "BIOSPROT", "Bios-data-read-protection address"),
    (0x4000400, "SOUND0CNT", "Sound Channel 0 Control Register (R/W)"),
    (0x4000404, "SOUND0SAD", "Sound Channel 0 Data Source Register (W)"),
    (0x4000408, "SOUND0TMR", "Sound Channel 0 Timer Register (W)"),
    (0x400040a, "SOUND0PNT", "Sound Channel 0 Loopstart Register (W)"),
    (0x400040c, "SOUND0LEN", "Sound Channel 0 Length Register (W)"),
    (0x4000410, "SOUND1CNT", "Sound Channel 1 Control Register (R/W)"),
    (0x4000414, "SOUND1SAD", "Sound Channel 1 Data Source Register (W)"),
    (0x4000418, "SOUND1TMR", "Sound Channel 1 Timer Register (W)"),
    (0x400041a, "SOUND1PNT", "Sound Channel 1 Loopstart Register (W)"),
    (0x400041c, "SOUND1LEN", "Sound Channel 1 Length Register (W)"),
    (0x4000420, "SOUND2CNT", "Sound Channel 2 Control Register (R/W)"),
    (0x4000424, "SOUND2SAD", "Sound Channel 2 Data Source Register (W)"),
    (0x4000428, "SOUND2TMR", "Sound Channel 2 Timer Register (W)"),
    (0x400042a, "SOUND2PNT", "Sound Channel 2 Loopstart Register (W)"),
    (0x400042c, "SOUND2LEN", "Sound Channel 2 Length Register (W)"),
    (0x4000430, "SOUND3CNT", "Sound Channel 3 Control Register (R/W)"),
    (0x4000434, "SOUND3SAD", "Sound Channel 3 Data Source Register (W)"),
    (0x4000438, "SOUND3TMR", "Sound Channel 3 Timer Register (W)"),
    (0x400043a, "SOUND3PNT", "Sound Channel 3 Loopstart Register (W)"),
    (0x400043c, "SOUND3LEN", "Sound Channel 3 Length Register (W)"),
    (0x4000440, "SOUND4CNT", "Sound Channel 4 Control Register (R/W)"),
    (0x4000444, "SOUND4SAD", "Sound Channel 4 Data Source Register (W)"),
    (0x4000448, "SOUND4TMR", "Sound Channel 4 Timer Register (W)"),
    (0x400044a, "SOUND4PNT", "Sound Channel 4 Loopstart Register (W)"),
    (0x400044c, "SOUND4LEN", "Sound Channel 4 Length Register (W)"),
    (0x4000450, "SOUND5CNT", "Sound Channel 5 Control Register (R/W)"),
    (0x4000454, "SOUND5SAD", "Sound Channel 5 Data Source Register (W)"),
    (0x4000458, "SOUND5TMR", "Sound Channel 5 Timer Register (W)"),
    (0x400045a, "SOUND5PNT", "Sound Channel 5 Loopstart Register (W)"),
    (0x400045c, "SOUND5LEN", "Sound Channel 5 Length Register (W)"),
    (0x4000460, "SOUND6CNT", "Sound Channel 6 Control Register (R/W)"),
    (0x4000464, "SOUND6SAD", "Sound Channel 6 Data Source Register (W)"),
    (0x4000468, "SOUND6TMR", "Sound Channel 6 Timer Register (W)"),
    (0x400046a, "SOUND6PNT", "Sound Channel 6 Loopstart Register (W)"),
    (0x400046c, "SOUND6LEN", "Sound Channel 6 Length Register (W)"),
    (0x4000470, "SOUND7CNT", "Sound Channel 7 Control Register (R/W)"),
    (0x4000474, "SOUND7SAD", "Sound Channel 7 Data Source Register (W)"),
    (0x4000478, "SOUND7TMR", "Sound Channel 7 Timer Register (W)"),
    (0x400047a, "SOUND7PNT", "Sound Channel 7 Loopstart Register (W)"),
    (0x400047c, "SOUND7LEN", "Sound Channel 7 Length Register (W)"),
    (0x4000480, "SOUND8CNT", "Sound Channel 8 Control Register (R/W)"),
    (0x4000484, "SOUND8SAD", "Sound Channel 8 Data Source Register (W)"),
    (0x4000488, "SOUND8TMR", "Sound Channel 8 Timer Register (W)"),
    (0x400048a, "SOUND8PNT", "Sound Channel 8 Loopstart Register (W)"),
    (0x400048c, "SOUND8LEN", "Sound Channel 8 Length Register (W)"),
    (0x4000490, "SOUND9CNT", "Sound Channel 9 Control Register (R/W)"),
    (0x4000494, "SOUND9SAD", "Sound Channel 9 Data Source Register (W)"),
    (0x4000498, "SOUND9TMR", "Sound Channel 9 Timer Register (W)"),
    (0x400049a, "SOUND9PNT", "Sound Channel 9 Loopstart Register (W)"),
    (0x400049c, "SOUND9LEN", "Sound Channel 9 Length Register (W)"),
    (0x40004a0, "SOUND10CNT", "Sound Channel 10 Control Register (R/W)"),
    (0x40004a4, "SOUND10SAD", "Sound Channel 10 Data Source Register (W)"),
    (0x40004a8, "SOUND10TMR", "Sound Channel 10 Timer Register (W)"),
    (0x40004aa, "SOUND10PNT", "Sound Channel 10 Loopstart Register (W)"),
    (0x40004ac, "SOUND10LEN", "Sound Channel 10 Length Register (W)"),
    (0x40004b0, "SOUND11CNT", "Sound Channel 11 Control Register (R/W)"),
    (0x40004b4, "SOUND11SAD", "Sound Channel 11 Data Source Register (W)"),
    (0x40004b8, "SOUND11TMR", "Sound Channel 11 Timer Register (W)"),
    (0x40004ba, "SOUND11PNT", "Sound Channel 11 Loopstart Register (W)"),
    (0x40004bc, "SOUND11LEN", "Sound Channel 11 Length Register (W)"),
    (0x40004c0, "SOUND12CNT", "Sound Channel 12 Control Register (R/W)"),
    (0x40004c4, "SOUND12SAD", "Sound Channel 12 Data Source Register (W)"),
    (0x40004c8, "SOUND12TMR", "Sound Channel 12 Timer Register (W)"),
    (0x40004ca, "SOUND12PNT", "Sound Channel 12 Loopstart Register (W)"),
    (0x40004cc, "SOUND12LEN", "Sound Channel 12 Length Register (W)"),
    (0x40004d0, "SOUND13CNT", "Sound Channel 13 Control Register (R/W)"),
    (0x40004d4, "SOUND13SAD", "Sound Channel 13 Data Source Register (W)"),
    (0x40004d8, "SOUND13TMR", "Sound Channel 13 Timer Register (W)"),
    (0x40004da, "SOUND13PNT", "Sound Channel 13 Loopstart Register (W)"),
    (0x40004dc, "SOUND13LEN", "Sound Channel 13 Length Register (W)"),
    (0x40004e0, "SOUND14CNT", "Sound Channel 14 Control Register (R/W)"),
    (0x40004e4, "SOUND14SAD", "Sound Channel 14 Data Source Register (W)"),
    (0x40004e8, "SOUND14TMR", "Sound Channel 14 Timer Register (W)"),
    (0x40004ea, "SOUND14PNT", "Sound Channel 14 Loopstart Register (W)"),
    (0x40004ec, "SOUND14LEN", "Sound Channel 14 Length Register (W)"),
    (0x40004f0, "SOUND15CNT", "Sound Channel 15 Control Register (R/W)"),
    (0x40004f4, "SOUND15SAD", "Sound Channel 15 Data Source Register (W)"),
    (0x40004f8, "SOUND15TMR", "Sound Channel 15 Timer Register (W)"),
    (0x40004fa, "SOUND15PNT", "Sound Channel 15 Loopstart Register (W)"),
    (0x40004fc, "SOUND15LEN", "Sound Channel 15 Length Register (W)"),
    (0x4000500, "SOUNDCNT", "Sound Control Register (R/W)"),
    (0x4000504, "SOUNDBIAS", "Sound Bias Register (R/W)"),
    (0x4000508, "SNDCAP0CNT", "Sound Capture 0 Control Register (R/W)"),
    (0x4000509, "SNDCAP1CNT", "Sound Capture 1 Control Register (R/W)"),
    (0x4000510, "SNDCAP0DAD", "Sound Capture 0 Destination Address (R/W)"),
    (0x4000514, "SNDCAP0LEN", "Sound Capture 0 Length (W)"),
    (0x4000518, "SNDCAP1DAD", "Sound Capture 1 Destination Address (R/W)"),
    (0x400051c, "SNDCAP1LEN", "Sound Capture 1 Length (W)"),
    (0x4100000, "IPCFIFORECV", "IPC Receive Fifo (R)"),
    (0x4100010, "CARD_DATA_RD", "Gamecard bus 4-byte data in, for manual or dma read"),
]

for (ea, name, comment) in regs:
    if name:
        idc.set_name(ea, name, SN_CHECK)
    if comment:
        idc.set_cmt(ea, comment, 1)