way more memory and fix tree counts

This commit is contained in:
ManDude
2023-09-03 09:53:33 +01:00
parent ea11a338df
commit 7e031fe4c7
7 changed files with 27 additions and 27 deletions
+1 -1
View File
@@ -84,7 +84,7 @@ constexpr u32 GOAL_RELOC_METHOD = 7; // method ID of GOAL relocate
constexpr u32 GOAL_MEMUSAGE_METHOD = 8; // method ID of GOAL mem-usage
constexpr int EE_MAIN_MEM_LOW_PROTECT = 512 * 1024;
constexpr int EE_MAIN_MEM_SIZE = 128 * (1 << 20); // 128 MB, same as PS2 TOOL
constexpr int EE_MAIN_MEM_SIZE = 256 * (1 << 20); // 128 MB, same as PS2 TOOL (changed to 256 MB)
constexpr u64 EE_MAIN_MEM_MAP = 0x2123000000; // intentionally > 32-bit to catch pointer bugs
// when true, attempt to map the EE memory in the low 2 GB of RAM
+3 -3
View File
@@ -16,7 +16,7 @@ constexpr u32 DEBUG_HEAP_SPACE_FOR_STACK = 0x10000;
constexpr u32 HEAP_START = 0x13fd20;
//! Where to end the global heap so it doesn't overlap with the stack.
constexpr u32 GLOBAL_HEAP_END = 0x1ffc000 + (BIG_MEMORY ? (0x1ffc000 - HEAP_START) : 0); // doubled
constexpr u32 GLOBAL_HEAP_END = 0x1ffc000 + (BIG_MEMORY ? (0x1ffc000 - HEAP_START) * 3 : 0); // doubled
//! Location of kglobalheap, kdebugheap kheapinfo structures.
constexpr u32 GLOBAL_HEAP_INFO_ADDR = 0x13AD00;
@@ -24,8 +24,8 @@ constexpr u32 DEBUG_HEAP_INFO_ADDR = 0x13AD10;
constexpr u32 LINK_CONTROL_NAME_ADDR = 0x13AD80;
//! Where to place the debug heap
constexpr u32 DEBUG_HEAP_START = 0x5000000;
constexpr u32 DEBUG_HEAP_START = 0x8000000;
namespace jak2 {
constexpr u32 DEBUG_HEAP_SIZE = 0x2f00000;
}
}
@@ -10,23 +10,23 @@
;; DECOMP BEGINS
(deftype background-work (basic)
((tfrag-tree-count int32 :offset-assert 4)
(tfrag-trees drawable-tree-tfrag 8 :offset-assert 8)
(tfrag-levels level 8 :offset-assert 40)
(tfrag-trans-tree-count int32 :offset-assert 72)
(tfrag-trans-trees drawable-tree-tfrag-trans 8 :offset-assert 76)
(tfrag-trans-levels level 8 :offset-assert 108)
(tfrag-water-tree-count int32 :offset-assert 140)
(tfrag-water-trees drawable-tree-tfrag-water 8 :offset-assert 144)
(tfrag-water-levels level 8 :offset-assert 176)
(shrub-tree-count int32 :offset-assert 208)
(shrub-trees drawable-tree-instance-shrub 8 :offset-assert 212)
(shrub-levels level 8 :offset-assert 244)
(tie-tree-count int32 :offset-assert 276)
(tie-trees drawable-tree-instance-tie 12);:offset-assert 280) ;; guessed by decompiler
(tie-levels level 12);:offset-assert 312) ;; guessed by decompiler
(tie-generic basic 12);:offset-assert 344) ;; guessed by decompiler
(tie-generic-trans basic 12);:offset-assert 376)
((tfrag-tree-count int32 );:offset-assert 4)
(tfrag-trees drawable-tree-tfrag 32);:offset-assert 8)
(tfrag-levels level 32);:offset-assert 40)
(tfrag-trans-tree-count int32 );:offset-assert 72)
(tfrag-trans-trees drawable-tree-tfrag-trans 32);:offset-assert 76)
(tfrag-trans-levels level 32);:offset-assert 108)
(tfrag-water-tree-count int32 );:offset-assert 140)
(tfrag-water-trees drawable-tree-tfrag-water 32);:offset-assert 144)
(tfrag-water-levels level 32);:offset-assert 176)
(shrub-tree-count int32 );:offset-assert 208)
(shrub-trees drawable-tree-instance-shrub 32);:offset-assert 212)
(shrub-levels level 32);:offset-assert 244)
(tie-tree-count int32 );:offset-assert 276)
(tie-trees drawable-tree-instance-tie 32);:offset-assert 280) ;; guessed by decompiler
(tie-levels level 32);:offset-assert 312) ;; guessed by decompiler
(tie-generic basic 32);:offset-assert 344) ;; guessed by decompiler
(tie-generic-trans basic 32);:offset-assert 376)
(wait-to-vu0 uint32 );:offset-assert 408)
)
:method-count-assert 9
+1 -1
View File
@@ -1842,7 +1842,7 @@ additionally, some texture pages have a chunk system that allows more specific c
;; to hold the dma chain - doesn't hold textures, just DMA :ref tags and similar.
(kmemopen global "texture-dma-buffers")
(define *txt-dma-list* (new 'global 'dma-buffer 4096))
(define *txt-dma-list* (new 'global 'dma-buffer 8192))
(kmemclose)
(defmethod upload-now! texture-page ((obj texture-page) (arg0 tex-upload-mode))
+3 -3
View File
@@ -1039,7 +1039,7 @@
(the-as
(function script-context object)
(lambda ((arg0 script-context))
(let ((s5-0 6)
(let ((s5-0 LEVEL_MAX)
(a0-1 (-> arg0 param 1))
)
(cond
@@ -1053,8 +1053,8 @@
)
)
)
(let ((s5-2 (new 'static 'boxed-array :type symbol :length 0 :allocated-length 6)))
(dotimes (s4-0 6)
(let ((s5-2 (new 'static 'boxed-array :type symbol :length 0 :allocated-length LEVEL_MAX)))
(dotimes (s4-0 LEVEL_MAX)
(let ((a1-3 (ref (-> arg0 param 1) s4-0)))
(set! (-> s5-2 s4-0) (the-as symbol (if (not (null? a1-3))
(eval! arg0 (the-as pair a1-3))
+1 -1
View File
@@ -43,7 +43,7 @@
)
;; pointers larger than this are invalid by valid?
(defconstant END_OF_MEMORY #x8000000)
(defconstant END_OF_MEMORY #x10000000)
(defun identity ((arg0 object))
"Return the input. Works for any 64-bit value."
@@ -25,7 +25,7 @@
(break!)
0
)
(when (< (the-as uint #x8000000) (the-as uint v1-4))
(when (< END_OF_MEMORY (the-as uint v1-4))
(break!)
0
)