Skip to content

Match eight PAL object data accessors - #58

Open
Sumaiter wants to merge 1 commit into
OpenRAC:mainfrom
Sumaiter:decomp/pal-object-accessors
Open

Sumaiter wants to merge 1 commit into
OpenRAC:mainfrom
Sumaiter:decomp/pal-object-accessors

Conversation

@Sumaiter

@Sumaiter Sumaiter commented Nov 1, 2026

Copy link
Copy Markdown
Contributor

Reconstruct eight previously unmatched functions from the SCES_532.85 main image. They share a partial object layout: flags at 0x34 and a data pointer at 0xAC. The shared layout is in include/pal/object_data.h.

Function Bytes Behavior
func_00476E90 52 Read data offset 0x38 after object/data/flag checks
func_00476ED0 52 Read data offset 0x1C after the same checks
func_00476F08 52 Read data offset 0x3C after the same checks
func_00476F40 44 Read data offset 0x10 after object/flag checks; retain the original unchecked data-pointer access
func_00476F70 112 Search ten object-table entries, then fall back to data offset 0x00
func_00478908 52 Read data offset 0x08 after object/flag/data checks
func_0047C510 52 Read data offset 0x0C after object/data/flag checks
func_0048FEF8 52 Read data offset 0x28 after the same checks

Validation:

  • Built all eight final files through the existing tools/cc.sh pipeline, without new flags or changes to compiler output.
  • Seven functions have no relocations and match all original code bytes directly.
  • func_00476F70 matches using the repository's relocation masks; independently resolved its three HI16/LO16 relocations to the original table address 0x003367B8. The remaining instructions and constants match.
  • Checked the final source hashes against the files used for verification.
  • Added only the eight verified PAL match rows and corresponding US other rows; every existing map row is retained unchanged.
  • Regenerated the reports with tools/progress.py. PAL progress increases by eight functions and 468 bytes (5,138 -> 5,146 functions; 396,888 -> 397,356 bytes). The US report is unchanged.
  • Both tools/progress.py --version us --check and --version pal --check passed, as did git diff --check.

This branch is independent of PR #57 and does not include its two drawing wrappers. Validation is limited to this PAL batch; a full rebuild, global audits and US-disc comparisons were not run. No retail binaries, assets or disassembly are included.

Reconstruct seven object-data field accessors and the object table lookup
in the SCES_532.85 main image. Share the partial layout for flags at 0x34
and the data pointer at 0xAC.

The eight final functions reproduce 468 bytes through tools/cc.sh. Seven
match without any relocations; the lookup's three HI16/LO16 relocations
were checked against the original global address 0x003367B8.

Add the proven PAL map rows and US other rows, retaining all existing
entries, and regenerate the PAL progress report and README counts.

Co-Authored-By: Codex <noreply@openai.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant