mirror of
https://github.com/RaySollium99/picodrive.git
synced 2025-10-26 16:29:37 -04:00
arm asm syntax fixes for open2x
This commit is contained in:
parent
340e528ff8
commit
2c479106af
3 changed files with 11 additions and 16 deletions
5
Makefile
5
Makefile
|
|
@ -1,9 +1,9 @@
|
||||||
TARGET ?= PicoDrive
|
TARGET ?= PicoDrive
|
||||||
DEBUG ?= 0
|
DEBUG ?= 0
|
||||||
CFLAGS += -Wall -g
|
CFLAGS += -Wall -ggdb -ffunction-sections -fdata-sections
|
||||||
CFLAGS += -I.
|
CFLAGS += -I.
|
||||||
ifeq "$(DEBUG)" "0"
|
ifeq "$(DEBUG)" "0"
|
||||||
CFLAGS += -O3 -DNDEBUG
|
CFLAGS += -O2 -finline-functions -DNDEBUG
|
||||||
endif
|
endif
|
||||||
|
|
||||||
# This is actually needed, bevieve me.
|
# This is actually needed, bevieve me.
|
||||||
|
|
@ -11,6 +11,7 @@ endif
|
||||||
ifndef NO_ALIGN_FUNCTIONS
|
ifndef NO_ALIGN_FUNCTIONS
|
||||||
CFLAGS += -falign-functions=2
|
CFLAGS += -falign-functions=2
|
||||||
endif
|
endif
|
||||||
|
LDFLAGS += -Wl,--gc-sections
|
||||||
|
|
||||||
all: config.mak target_
|
all: config.mak target_
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,7 @@
|
||||||
|
|
||||||
#include "../../arm_features.h"
|
#include "../../arm_features.h"
|
||||||
|
|
||||||
.syntax unified
|
@.syntax unified
|
||||||
.text
|
.text
|
||||||
.align 2
|
.align 2
|
||||||
|
|
||||||
|
|
@ -281,8 +281,8 @@ ssp_hle_902_loop:
|
||||||
bgt ssp_hle_902_loop
|
bgt ssp_hle_902_loop
|
||||||
|
|
||||||
tst r12, #1
|
tst r12, #1
|
||||||
ldrhne r0, [r2], #2
|
ldrneh r0, [r2], #2
|
||||||
strhne r0, [r3], #2
|
strneh r0, [r3], #2
|
||||||
|
|
||||||
ldr r0, [r7, #SSP_OFFS_IRAM_ROM]
|
ldr r0, [r7, #SSP_OFFS_IRAM_ROM]
|
||||||
add r1, r7, #0x200
|
add r1, r7, #0x200
|
||||||
|
|
@ -501,7 +501,7 @@ FUNCTION(ssp_hle_07_036):
|
||||||
mov r12, #0x4000
|
mov r12, #0x4000
|
||||||
orr r12,r12,#0x0018
|
orr r12,r12,#0x0018
|
||||||
subs r12,r3, r12
|
subs r12,r3, r12
|
||||||
subsne r12,r12,#0x0400
|
subnes r12,r12,#0x0400
|
||||||
blne tr_unhandled
|
blne tr_unhandled
|
||||||
|
|
||||||
orr r2, r2, r2, lsl #16
|
orr r2, r2, r2, lsl #16
|
||||||
|
|
@ -510,7 +510,7 @@ FUNCTION(ssp_hle_07_036):
|
||||||
|
|
||||||
hle_07_036_no_ovrwr:
|
hle_07_036_no_ovrwr:
|
||||||
tst r1, #2
|
tst r1, #2
|
||||||
strhne r2, [r1], #0x3e @ align
|
strneh r2, [r1], #0x3e @ align
|
||||||
subne r0, r0, #1
|
subne r0, r0, #1
|
||||||
subs r0, r0, #4
|
subs r0, r0, #4
|
||||||
blt hle_07_036_l2
|
blt hle_07_036_l2
|
||||||
|
|
@ -525,7 +525,7 @@ hle_07_036_l2:
|
||||||
tst r0, #2
|
tst r0, #2
|
||||||
strne r2, [r1], #0x40
|
strne r2, [r1], #0x40
|
||||||
tst r0, #1
|
tst r0, #1
|
||||||
strhne r2, [r1], #2
|
strneh r2, [r1], #2
|
||||||
b hle_07_036_end_copy
|
b hle_07_036_end_copy
|
||||||
|
|
||||||
hle_07_036_ovrwr:
|
hle_07_036_ovrwr:
|
||||||
|
|
@ -562,10 +562,10 @@ hle_07_036_ol1:
|
||||||
|
|
||||||
hle_07_036_ol2:
|
hle_07_036_ol2:
|
||||||
tst r0, #1
|
tst r0, #1
|
||||||
ldrhne r3, [r1]
|
ldrneh r3, [r1]
|
||||||
andne r3, r3, r12
|
andne r3, r3, r12
|
||||||
orrne r3, r3, r2
|
orrne r3, r3, r2
|
||||||
strhne r3, [r1], #2
|
strneh r3, [r1], #2
|
||||||
|
|
||||||
hle_07_036_end_copy:
|
hle_07_036_end_copy:
|
||||||
ldr r2, [r7, #SSP_OFFS_DRAM]
|
ldr r2, [r7, #SSP_OFFS_DRAM]
|
||||||
|
|
|
||||||
|
|
@ -14,12 +14,6 @@
|
||||||
extern const unsigned char hcounts_32[];
|
extern const unsigned char hcounts_32[];
|
||||||
extern const unsigned char hcounts_40[];
|
extern const unsigned char hcounts_40[];
|
||||||
|
|
||||||
#ifndef UTYPES_DEFINED
|
|
||||||
typedef unsigned char u8;
|
|
||||||
typedef unsigned short u16;
|
|
||||||
typedef unsigned int u32;
|
|
||||||
#define UTYPES_DEFINED
|
|
||||||
#endif
|
|
||||||
|
|
||||||
int (*PicoDmaHook)(unsigned int source, int len, unsigned short **base, unsigned int *mask) = NULL;
|
int (*PicoDmaHook)(unsigned int source, int len, unsigned short **base, unsigned int *mask) = NULL;
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue