diff --git a/README.md b/README.md
index 4c4c60df..2844d4a4 100644
--- a/README.md
+++ b/README.md
@@ -1,4 +1,4 @@
-# banjo (93.9924%)
+# banjo (94.0107%)
diff --git a/progress/progress_core1.svg b/progress/progress_core1.svg
index 63d4f030..b284e866 100644
--- a/progress/progress_core1.svg
+++ b/progress/progress_core1.svg
@@ -17,7 +17,7 @@
core1
- 88.5362%
- 88.5362%
+ 88.6623%
+ 88.6623%
\ No newline at end of file
diff --git a/progress/progress_total.svg b/progress/progress_total.svg
index ca5fa56b..ad110aa5 100644
--- a/progress/progress_total.svg
+++ b/progress/progress_total.svg
@@ -17,7 +17,7 @@
Banjo-Kazooie (us.v10)
- 93.9924%
- 93.9924%
+ 94.0107%
+ 94.0107%
\ No newline at end of file
diff --git a/src/core1/memory.c b/src/core1/memory.c
index 278d7368..9ca222f5 100644
--- a/src/core1/memory.c
+++ b/src/core1/memory.c
@@ -430,17 +430,13 @@ void func_80254F90(void){
}
}
-#ifndef NONMATCHING
-#pragma GLOBAL_ASM("asm/nonmatchings/core1/memory/_heap_sortEmptyBlock.s")
-#else
-//moves empty block (arg0) to keep empty block list sorted by size
void _heap_sortEmptyBlock(EmptyHeapBlock * arg0){
EmptyHeapBlock *v0 = arg0;
EmptyHeapBlock *v1;
EmptyHeapBlock *a2 = &D_8002D500[LAST_HEAP_BLOCK];
//move arg0 back while larger than next
- while( arg0->next_free < a2
+ while( arg0->next_free < &D_8002D500[LAST_HEAP_BLOCK]
&& (s32)chunkSize(&v0->next_free->hdr) + 0x10 < (s32)chunkSize(&v0->hdr) + 0x10
){
v1 = arg0->next_free;
@@ -453,10 +449,11 @@ void _heap_sortEmptyBlock(EmptyHeapBlock * arg0){
}
//move arg0 foward while smaller prev
- while( ( arg0->prev_free >= (EmptyHeapBlock *)((u8*)D_8002D500 + 1))
+ while( ( (v1 = arg0->prev_free) > &D_8002D500[0])
&& (s32)chunkSize(&v0->hdr) + 0x10 < (s32)chunkSize(&v0->prev_free->hdr) + 0x10
){
a2 = arg0->prev_free;
+
arg0->next_free->prev_free = a2;
a2->next_free = arg0->next_free;
arg0->next_free = a2;
@@ -465,7 +462,6 @@ void _heap_sortEmptyBlock(EmptyHeapBlock * arg0){
a2->prev_free = arg0;
}
}
-#endif
void free(void * ptr){
HeapHeader *sPtr; //stack_ptr