Skip to content

More miscellaneous TU improvements#2665

Merged
hatal175 merged 1 commit intozeldaret:mainfrom
caseif:misc-7
Sep 17, 2025
Merged

More miscellaneous TU improvements#2665
hatal175 merged 1 commit intozeldaret:mainfrom
caseif:misc-7

Conversation

@caseif
Copy link
Copy Markdown
Contributor

@caseif caseif commented Sep 17, 2025

This PR includes some more random TU improvements with few now fully linked.

@decomp-dev
Copy link
Copy Markdown

decomp-dev bot commented Sep 17, 2025

Report for ShieldD (2106c56 - aaddf44)

📈 Matched code: 19.36% (+0.10%, +14896 bytes)

✅ 123 new matches
Unit Function Bytes Before After
framework/d/d_kankyo dKy_WaterIn_Light_set() +518 61.17% 100.00%
framework/m_Do/m_Do_ext calcColorChanID(unsigned short, unsigned char, unsigned char, unsigned char, unsigned char, unsigned char) +440 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevStage::setTevStageInfo(const J3DTevStageInfo&) +236 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevStage::setTevAlphaOp(unsigned char, unsigned char, unsigned char, unsigned char, unsigned char) +204 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevStage::setTevColorOp(unsigned char, unsigned char, unsigned char, unsigned char, unsigned char) +204 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndTevStage::setIndTevStageInfo(const J3DIndTevStageInfo&) +196 0.00% 100.00%
framework/m_Do/m_Do_ext J3DColorChan::setColorChanInfo(const J3DColorChanInfo&) +152 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevStage::setAlphaABCD(unsigned char, unsigned char, unsigned char, unsigned char) +104 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevStage::setTevSwapModeInfo(const J3DTevSwapModeInfo&) +84 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndTexCoordScale::~J3DIndTexCoordScale() +76 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndTexMtx::~J3DIndTexMtx() +76 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevStage::J3DTevStage() +72 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndTevStage::J3DIndTevStage() +68 0.00% 100.00%
framework/m_Do/m_Do_ext mDoExt_3Dline_c::init(unsigned short, int, int) +61 90.43% 100.00%
framework/m_Do/m_Do_ext J3DIndTexMtx::J3DIndTexMtx() +60 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevStage::setAlphaC(unsigned char) +60 0.00% 100.00%
framework/m_Do/m_Do_ext J3DColorChan::J3DColorChan() +56 0.00% 100.00%
framework/m_Do/m_Do_ext J3DAlphaComp::J3DAlphaComp() +32 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevStage::setTexSel(unsigned char) +32 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevStage::setAlphaD(unsigned char) +32 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevStage::setAlphaB(unsigned char) +32 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevStage::setAlphaA(unsigned char) +32 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndTevStage::setAlphaSel(unsigned char) +28 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndTevStage::setLod(unsigned char) +28 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndTevStage::setPrev(unsigned char) +28 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndTevStage::setWrapT(unsigned char) +28 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndTevStage::setWrapS(unsigned char) +28 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndTevStage::setMtxSel(unsigned char) +28 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndTevStage::setBiasSel(unsigned char) +28 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndTevStage::setIndFormat(unsigned char) +28 0.00% 100.00%

...and 93 more new matches

📈 238 improvements in unmatched functions
Unit Function Bytes Before After
d_a_npc_ykm/d/actor/d_a_npc_ykm daNpc_ykM_c::setAttnPos() +371 76.03% 98.36%
framework/d/d_ev_camera dCamera_c::transEvCamera(int) +357 95.47% 98.56%
d_a_npc_ykm/d/actor/d_a_npc_ykm daNpc_ykM_c::CreateHeap() +243 84.55% 98.63%
framework/d/d_kankyo_rain drawVrkumo(float(*)[4], _GXColor&, unsigned char**) +188 96.52% 99.90%
d_a_L7op_demo_dr/d/actor/d_a_L7op_demo_dr daL7ODR_c::dr_fly() +118 98.25% 99.83%
d_a_e_pz/d/actor/d_a_e_pz daE_PZ_c::executeOpeningDemo() +77 97.22% 98.03%
d_a_npc_ykw/d/actor/d_a_npc_ykw daNpc_ykW_c::race(void*) +66 94.96% 97.74%
d_a_npc_ykm/d/actor/d_a_npc_ykm daNpc_ykM_c::race(void*) +65 92.13% 94.67%
framework/d/d_kankyo dKy_setLight_nowroom_common(char, float) +56 75.95% 77.30%
framework/m_Do/m_Do_ext J3DTexCoord::J3DTexCoord() +52 0.00% 76.47%
framework/d/d_kankyo setLightTevColorType_MAJI_sub(J3DMaterial*, dKy_tevstr_c*, int) +38 79.62% 80.89%
framework/m_Do/m_Do_ext J3DBlend::J3DBlend() +37 0.00% 67.64%
framework/m_Do/m_Do_ext J3DIndTexCoordScale::J3DIndTexCoordScale() +37 0.00% 67.64%
framework/m_Do/m_Do_ext J3DIndTexOrder::J3DIndTexOrder() +37 0.00% 67.64%
framework/m_Do/m_Do_ext J3DTevOrder::J3DTevOrder() +37 0.00% 67.64%
framework/d/d_kankyo dKy_setLight_nowroom_grass(char, float) +37 71.69% 81.49%
framework/d/actor/d_a_alink daAlink_c::setHookshotPos() +32 95.88% 96.55%
framework/m_Do/m_Do_ext J3DIndTexMtx::J3DIndTexMtx(const J3DIndTexMtx&) +26 0.00% 44.33%
d_a_npc_ykm/d/actor/d_a_npc_ykm daNpc_ykM_c::reset() +11 94.05% 95.78%
d_a_npc_ykm/d/actor/d_a_npc_ykm daNpc_ykM_c::cutLv5DungeonClear(int) +5 97.46% 97.64%
framework/d/d_kankyo dKankyo_lightHIO_c::dKankyo_lightHIOInfoUpDateF() +3 0.00% 0.10%
d_a_e_dn/d/actor/d_a_e_dn daE_DN_Execute(e_dn_class*) +2 98.20% 98.26%
d_a_e_mf/d/actor/d_a_e_mf action(e_mf_class*) +2 84.80% 84.82%
framework/d/actor/d_a_alink daAlink_c::procHorseGetOffInit(int) +1 93.57% 93.60%
framework/d/actor/d_a_alink daAlink_c::procHookshotFly() +1 54.21% 54.22%
framework/d/actor/d_a_alink daAlink_c::wolfFootBgCheck() +1 91.89% 91.91%
framework/d/actor/d_a_alink daAlink_c::procWolfHangWallCatchInit(int) +1 98.27% 98.30%
framework/d/actor/d_a_alink daAlink_c::setShapeAngleOnGround() +1 96.48% 96.53%
framework/d/actor/d_a_alink daAlink_c::setFrontWallType() +1 96.39% 96.41%
framework/d/actor/d_a_alink daAlink_c::procCoMetamorphoseInit() +1 98.83% 98.85%

...and 208 more improvements in unmatched functions

📉 8 regressions in unmatched functions
Unit Function Bytes Before After
d_a_e_rdy/d/actor/d_a_e_rdy daE_RDY_Execute(e_rdy_class*) -100 98.46% 96.87%
d_a_obj_lv4chandelier/d/actor/d_a_obj_lv4chandelier daObjLv4Chan_c::Execute(float(**)[3][4]) -76 88.42% 87.40%
d_a_b_gnd/d/actor/d_a_b_gnd daB_GND_Execute(b_gnd_class*) -40 82.07% 81.67%
d_a_obj_brg/d/actor/d_a_obj_brg obj_brg_move(obj_brg_class*) -22 96.88% 96.37%
framework/d/d_camera dCamera_c::talktoCamera(long) -17 89.21% 89.16%
d_a_e_rd/d/actor/d_a_e_rd daE_RD_Execute(e_rd_class*) -6 96.17% 96.10%
d_a_npc_ykm/d/actor/d_a_npc_ykm daNpc_ykM_c::create() -3 94.96% 94.59%
framework/d/actor/d_a_alink daAlink_c::setIronBallPos() -1 97.80% 97.79%

Report for GZ2J01 (2106c56 - aaddf44)

📈 Matched code: 83.25% (+0.40%, +46336 bytes)
📈 Linked code: 51.54% (+1.09%, +125196 bytes)

✅ 68 new matches
Unit Function Bytes Before After
framework/m_Do/m_Do_ext J3DTevStage::setTevStageInfo(const J3DTevStageInfo&) +456 0.00% 100.00%
d_a_npc_ykm/d/actor/d_a_npc_ykm daNpc_ykM_c::race(void*) +121 95.96% 100.00%
d_a_e_pz/d/actor/d_a_e_pz daE_PZ_c::executeOpeningDemo() +111 98.80% 100.00%
framework/m_Do/m_Do_ext J3DTevStage::J3DTevStage() +104 0.00% 100.00%
framework/d/d_kankyo dKy_setLight_nowroom_common(char, float) +66 97.34% 100.00%
framework/m_Do/m_Do_ext J3DIndTexCoordScale::~J3DIndTexCoordScale() +60 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndTexMtx::~J3DIndTexMtx() +60 0.00% 100.00%
framework/d/d_kankyo_rain drawVrkumo(float(*)[4], _GXColor&, unsigned char**) +38 99.15% 100.00%
d_a_npc_ykm/d/actor/d_a_npc_ykm daNpc_ykM_c::CreateHeap() +36 97.46% 100.00%
framework/d/d_kankyo_rain dKyr_drawStar(float(*)[4], unsigned char**) +21 99.49% 100.00%
framework/d/d_kankyo_rain dKyr_drawLenzflare(float(*)[4], cXyz*, _GXColor&, unsigned char**) +20 99.56% 100.00%
framework/d/d_ev_camera cXyz::operator-=(const Vec&) +17 68.85% 100.00%
d_a_npc_ykw/d/actor/d_a_npc_ykw daNpc_ykW_c::race(void*) +17 99.40% 100.00%
framework/d/d_kankyo setLightTevColorType_MAJI_sub(J3DMaterial*, dKy_tevstr_c*, int) +15 99.26% 100.00%
framework/d/d_kankyo_rain dKyr_drawSun(float(*)[4], cXyz*, _GXColor&, unsigned char**) +13 99.66% 100.00%
framework/m_Do/m_Do_ext J3DTevBlock::getTexNo(unsigned long) const +12 0.00% 100.00%
d_a_obj_toby/d/actor/d_a_obj_toby useHeapInit(fopAc_ac_c*) +11 97.98% 100.00%
framework/d/d_kankyo dKy_setLight_nowroom_grass(char, float) +9 96.56% 100.00%
d_a_npc_ykm/d/actor/d_a_npc_ykm daNpc_ykM_c::cutLv5DungeonClear(int) +9 99.69% 100.00%
framework/m_Do/m_Do_ext J3DPEBlock::getZCompLoc() const +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DPEBlock::getZMode() +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DPEBlock::getBlend() +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DPEBlock::getAlphaComp() +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DPEBlock::getFog() +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndBlock::getIndTexCoordScale(unsigned long) +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndBlock::getIndTexMtx(unsigned long) +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndBlock::getIndTexOrder(unsigned long) +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndBlock::getIndTexStageNum() const +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevBlock::getIndTevStage(unsigned long) +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevBlock::getTevStage(unsigned long) +8 0.00% 100.00%

...and 38 more new matches


Report for GZ2P01 (2106c56 - aaddf44)

📈 Matched code: 83.46% (+0.30%, +34260 bytes)

✅ 65 new matches
Unit Function Bytes Before After
framework/m_Do/m_Do_ext J3DTevStage::setTevStageInfo(const J3DTevStageInfo&) +456 0.00% 100.00%
d_a_npc_ykm/d/actor/d_a_npc_ykm daNpc_ykM_c::race(void*) +121 95.96% 100.00%
d_a_e_pz/d/actor/d_a_e_pz daE_PZ_c::executeOpeningDemo() +111 98.80% 100.00%
framework/m_Do/m_Do_ext J3DTevStage::J3DTevStage() +104 0.00% 100.00%
framework/d/d_kankyo dKy_setLight_nowroom_common(char, float) +66 97.34% 100.00%
framework/m_Do/m_Do_ext J3DIndTexCoordScale::~J3DIndTexCoordScale() +60 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndTexMtx::~J3DIndTexMtx() +60 0.00% 100.00%
d_a_npc_ykm/d/actor/d_a_npc_ykm daNpc_ykM_c::CreateHeap() +36 97.46% 100.00%
framework/d/d_kankyo_rain drawVrkumo(float(*)[4], _GXColor&, unsigned char**) +25 99.43% 100.00%
framework/d/d_ev_camera cXyz::operator-=(const Vec&) +17 68.85% 100.00%
d_a_npc_ykw/d/actor/d_a_npc_ykw daNpc_ykW_c::race(void*) +17 99.40% 100.00%
framework/d/d_kankyo setLightTevColorType_MAJI_sub(J3DMaterial*, dKy_tevstr_c*, int) +15 99.26% 100.00%
framework/m_Do/m_Do_ext J3DTevBlock::getTexNo(unsigned long) const +12 0.00% 100.00%
d_a_obj_toby/d/actor/d_a_obj_toby useHeapInit(fopAc_ac_c*) +11 97.98% 100.00%
framework/d/d_kankyo dKy_setLight_nowroom_grass(char, float) +9 96.56% 100.00%
d_a_npc_ykm/d/actor/d_a_npc_ykm daNpc_ykM_c::cutLv5DungeonClear(int) +9 99.69% 100.00%
framework/m_Do/m_Do_ext J3DPEBlock::getZCompLoc() const +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DPEBlock::getZMode() +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DPEBlock::getBlend() +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DPEBlock::getAlphaComp() +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DPEBlock::getFog() +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndBlock::getIndTexCoordScale(unsigned long) +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndBlock::getIndTexMtx(unsigned long) +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndBlock::getIndTexOrder(unsigned long) +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndBlock::getIndTexStageNum() const +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevBlock::getIndTevStage(unsigned long) +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevBlock::getTevStage(unsigned long) +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevBlock::getTevSwapModeTable(unsigned long) +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevBlock::getTevKAlphaSel(unsigned long) +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevBlock::getTevKColorSel(unsigned long) +8 0.00% 100.00%

...and 35 more new matches


Report for GZ2E01 (2106c56 - aaddf44)

📈 Matched code: 85.36% (+0.30%, +34324 bytes)
📈 Linked code: 55.73% (+1.62%, +186188 bytes)

✅ 67 new matches
Unit Function Bytes Before After
framework/m_Do/m_Do_ext J3DTevStage::setTevStageInfo(const J3DTevStageInfo&) +456 0.00% 100.00%
d_a_npc_ykm/d/actor/d_a_npc_ykm daNpc_ykM_c::race(void*) +121 95.96% 100.00%
d_a_e_pz/d/actor/d_a_e_pz daE_PZ_c::executeOpeningDemo() +111 98.80% 100.00%
framework/m_Do/m_Do_ext J3DTevStage::J3DTevStage() +104 0.00% 100.00%
framework/d/d_kankyo dKy_setLight_nowroom_common(char, float) +66 97.34% 100.00%
framework/m_Do/m_Do_ext J3DIndTexCoordScale::~J3DIndTexCoordScale() +60 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndTexMtx::~J3DIndTexMtx() +60 0.00% 100.00%
framework/d/d_ev_camera dCamera_c::@class$5983d_ev_camera_cpp::~@class$5983d_ev_camera_cpp() +60 0.00% 100.00%
d_a_npc_ykm/d/actor/d_a_npc_ykm daNpc_ykM_c::CreateHeap() +36 97.46% 100.00%
framework/d/d_kankyo_rain drawVrkumo(float(*)[4], _GXColor&, unsigned char**) +25 99.43% 100.00%
framework/d/d_ev_camera cXyz::operator-=(const Vec&) +17 68.85% 100.00%
d_a_npc_ykw/d/actor/d_a_npc_ykw daNpc_ykW_c::race(void*) +17 99.40% 100.00%
framework/d/d_kankyo setLightTevColorType_MAJI_sub(J3DMaterial*, dKy_tevstr_c*, int) +15 99.26% 100.00%
framework/m_Do/m_Do_ext J3DTevBlock::getTexNo(unsigned long) const +12 0.00% 100.00%
d_a_obj_toby/d/actor/d_a_obj_toby useHeapInit(fopAc_ac_c*) +11 97.98% 100.00%
framework/d/d_kankyo dKy_setLight_nowroom_grass(char, float) +9 96.56% 100.00%
d_a_npc_ykm/d/actor/d_a_npc_ykm daNpc_ykM_c::cutLv5DungeonClear(int) +9 99.69% 100.00%
framework/m_Do/m_Do_ext J3DPEBlock::getZCompLoc() const +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DPEBlock::getZMode() +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DPEBlock::getBlend() +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DPEBlock::getAlphaComp() +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DPEBlock::getFog() +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndBlock::getIndTexCoordScale(unsigned long) +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndBlock::getIndTexMtx(unsigned long) +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndBlock::getIndTexOrder(unsigned long) +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DIndBlock::getIndTexStageNum() const +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevBlock::getIndTevStage(unsigned long) +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevBlock::getTevStage(unsigned long) +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevBlock::getTevSwapModeTable(unsigned long) +8 0.00% 100.00%
framework/m_Do/m_Do_ext J3DTevBlock::getTevKAlphaSel(unsigned long) +8 0.00% 100.00%

...and 37 more new matches

@hatal175 hatal175 merged commit fe5e8af into zeldaret:main Sep 17, 2025
4 checks passed
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.

2 participants