re: r0 is not a base register - the last shortlisted row withdrawn

sub_825F2CF0 / sub_825F2F88 (r0, 30 names each, 97% disc names) are not
name-block readers at all: they are the compiler's VMX save/restore helper
pair. 145 instructions each, 72 differ, every difference stvx<->lvx over
v14..v127.

Root cause: in `addi rD, rA, N` the rA slot reads as literal zero when it
names r0, so `addi r11, r0, -N` is `li r11, -N` - vector spill offsets, not
displacements. The solver excluded r1 only; the bogus base landed inside the
stage-settings name block, dense enough to "resolve" 30 real field names.

name_block_bases.py now skips r0 as well. Rows 277 -> 261, functions 190 ->
176, non-64K bases 170 -> 154, data-table rows 53 -> 50; 154+107=261 and
277-16=261. Artefact diff -100/+3, every removed row line carries r0, control
sub_82341A20 r30 = 0x82088F94 217/226 untouched.

Nothing lost: all 30 names are a strict subset of sub_8230D1F8 r29 (129
names), the stage-settings loader already in the corpus. String-xref join
agrees - FinalPassBG, FogMinDistance, ScreenColorR, ExposureKey_BeginValue
each exist once with exactly one xref, from sub_8230D1F8.

Fourteen other artefacts byte-identical; name-block-bases.txt byte-identical
on a second run.
This commit is contained in:
Sylpheed RE agent
2026-08-28 00:21:26 +00:00
parent aeec0dab8f
commit bb6fb9024b
5 changed files with 149 additions and 113 deletions

View File

@@ -4,7 +4,7 @@
strings in the image: 7140 addi instructions: 282736
## 277 functions read a name block through a base register
## 261 functions read a name block through a base register
function reg base resolved / displacements
sub_82341A20 r30 0x82088F94 217 / 226
sub_822215D0 r11 0x820A0000 205 / 206
@@ -81,14 +81,11 @@
sub_8284B398 r11 0x820B0000 40 / 42
sub_822F9498 r31 0x82026F24 39 / 83
sub_826FBC38 r11 0x82050000 38 / 60
sub_826AE390 r0 0x82026F74 37 / 306
sub_82338EE0 r31 0x82026F18 36 / 78
sub_823AE908 r31 0x82026F24 33 / 71
sub_823BDAA8 r11 0x820B0000 33 / 35
sub_826AB050 r11 0x82040000 31 / 33
sub_82561C70 r11 0x820A90D8 30 / 93
sub_825F2CF0 r0 0x8209EB30 30 / 64
sub_825F2F88 r0 0x8209EB30 30 / 64
sub_822E3EC8 r11 0x820B0000 29 / 32
sub_82627B70 r11 0x82030000 29 / 29
sub_82297550 r11 0x820B0000 27 / 41
@@ -174,8 +171,6 @@
sub_8257E270 r5 0x820AE7AC 21 / 31
sub_8257E6C0 r5 0x820AE7AC 21 / 31
sub_82658790 r11 0x82030000 21 / 26
sub_82780C10 r0 0x820A9EAD 21 / 51
sub_827D9DD0 r0 0x82074503 21 / 149
sub_821A8578 r11 0x82023F00 20 / 25
sub_8233C368 r28 0x8208583C 20 / 21
sub_8236B608 r11 0x820B0000 20 / 20
@@ -190,7 +185,6 @@
sub_8232BAA0 r31 0x82034220 17 / 25
sub_823B63E0 r31 0x820AE72C 17 / 30
sub_82440878 r31 0x82026FF0 17 / 33
sub_824B4908 r0 0x82073D58 17 / 122
sub_8265A260 r11 0x82030000 17 / 18
sub_827A5058 r11 0x82050000 17 / 18
sub_8219BB30 r11 0x820244AC 16 / 26
@@ -201,10 +195,8 @@
sub_82324178 r31 0x82026F14 16 / 28
sub_82473448 r31 0x8202EBFC 16 / 29
sub_82562BB8 r3 0x820A918C 16 / 20
sub_825C2980 r0 0x82052A40 16 / 22
sub_826A0040 r11 0x820A01AC 16 / 32
sub_82804AD0 r11 0x820A792C 16 / 43
sub_82222E70 r0 0x8209E6D8 15 / 27
sub_8227F8E0 r31 0x820A0E9C 15 / 20
sub_82282DB0 r31 0x820A0E8C 15 / 20
sub_822E3EC8 r10 0x820B0000 15 / 15
@@ -216,9 +208,7 @@
sub_823C0C58 r31 0x82034270 15 / 18
sub_82565C80 r11 0x820A5574 15 / 42
sub_825DA790 r26 0x820A3B4C 15 / 20
sub_8265DFB8 r0 0x82074ECA 15 / 98
sub_82664700 r11 0x82030000 15 / 16
sub_82787E38 r0 0x82074B66 15 / 76
sub_8285F2C8 r5 0x820AE7AC 15 / 15
sub_82860290 r3 0x820AE7AC 15 / 15
sub_82860670 r3 0x820AE7AC 15 / 15
@@ -226,7 +216,6 @@
sub_8220ED30 r31 0x820A0E9C 14 / 21
sub_8221F700 r11 0x820A0000 14 / 18
sub_82288E70 r11 0x820B0000 14 / 23
sub_822CC130 r0 0x82026F74 14 / 31
sub_822F2E58 r31 0x820A97E4 14 / 27
sub_82308AB8 r31 0x82034200 14 / 27
sub_8230BB58 r11 0x820B0000 14 / 15
@@ -241,7 +230,6 @@
sub_823B2620 r31 0x8209E710 14 / 24
sub_823D3BE0 r31 0x820B47D4 14 / 24
sub_82529708 r25 0x820AAA6C 14 / 20
sub_8252C4E8 r0 0x82074617 14 / 70
sub_825635C8 r31 0x8209E230 14 / 22
sub_8261F2C0 r11 0x8208AB54 14 / 21
sub_82659DF0 r11 0x82030000 14 / 14
@@ -254,8 +242,6 @@
sub_823800A8 r31 0x82001C4C 13 / 21
sub_823A3C30 r31 0x82034270 13 / 18
sub_823BF6D8 r31 0x82034270 13 / 17
sub_82435448 r0 0x82027040 13 / 52
sub_824B42E8 r0 0x820743A3 13 / 66
sub_824E76D0 r10 0x8209FC64 13 / 22
sub_8257DD20 r4 0x820342D0 13 / 15
sub_8257DD20 r5 0x820342D0 13 / 15
@@ -266,7 +252,6 @@
sub_82621400 r11 0x82030000 13 / 14
sub_82622448 r11 0x8202B13C 13 / 18
sub_8263D478 r11 0x82030000 13 / 16
sub_826A7BF0 r0 0x82074DCE 13 / 85
sub_827030F8 r11 0x82050000 13 / 13
sub_827B0098 r11 0x82050000 13 / 15
sub_82193648 r11 0x820A8278 12 / 22
@@ -280,12 +265,11 @@
sub_82625890 r11 0x82030000 12 / 14
sub_826ACC98 r11 0x82040000 12 / 18
sub_826FA758 r11 0x820A81F0 12 / 26
sub_82766DB0 r0 0x8207454A 12 / 71
sub_82766DB0 r11 0x82050000 12 / 29
sub_827D7C00 r11 0x82060000 12 / 14
## Confidence split
bases with a non-zero low half (a real `addis`+`addi` pair): 170
bases with a non-zero low half (a real `addis`+`addi` pair): 154
bases on a 64K boundary (LOW CONFIDENCE, see below) : 107
0x820B0000 x82 rows
0x82030000 x10 rows
@@ -297,7 +281,7 @@
## Is the row a DATA-TABLE schema? (names that are IDXD record/field names on the disc)
distinct IDXD record+field names disc-wide: 13450
rows that are >=50% disc names and >=8 names: 53 / 277
rows that are >=50% disc names and >=8 names: 50 / 261
sub_82341A20 r30 0x82088F94 217 names 89% disc
sub_822215D0 r11 0x820A0000 205 names 98% disc
sub_8230D1F8 r29 0x8209FD28 129 names 97% disc
@@ -306,8 +290,6 @@
sub_822AE628 r11 0x820B0000 81 names 67% disc
sub_823BDAA8 r11 0x820B0000 33 names 88% disc
sub_82561C70 r11 0x820A90D8 30 names 50% disc
sub_825F2CF0 r0 0x8209EB30 30 names 97% disc
sub_825F2F88 r0 0x8209EB30 30 names 97% disc
sub_82297550 r11 0x820B0000 27 names 67% disc
sub_822A2F00 r11 0x820B0000 27 names 70% disc
sub_823BDAA8 r10 0x820B0000 25 names 100% disc
@@ -328,7 +310,6 @@
sub_82286BC8 r11 0x820B0000 18 names 100% disc
sub_821AA1B0 r31 0x820A97CC 16 names 94% disc
sub_82804AD0 r11 0x820A792C 16 names 88% disc
sub_82222E70 r0 0x8209E6D8 15 names 100% disc
sub_8227F8E0 r31 0x820A0E9C 15 names 100% disc
sub_82282DB0 r31 0x820A0E8C 15 names 100% disc
sub_823479B8 r28 0x820864F4 15 names 100% disc
@@ -1118,12 +1099,6 @@
assembler.prd_stack->Size() == 1 , ExpAdjust=%d MiniFetch=FALSE, PrefetchCount=%d
MiniFetch=TRUE
sub_826AE390 (r0, base 0x82026F74) names 37:
vs_3_sw vs_3_0 vs_2_x vs_2_sw vs_2_a vs_1_1 vs_1_0 vs.3.xps vs.3.swx vs.3.sw
vs.3.0 vs.2.x vs.2.sw vs.2.a vs.1.1 vs.1.0 tx_1_0 ps_3_sw ps_3_0 ps_2_x ps_2_sw
ps_2_b ps_2_alpha2 ps_2_a ps_1_4 ps_1_3 ps_1_2 ps_1_1 ps_1_0 ps.3.sw ps.3.0
ps.2.x ps.2.sw ps.2.b ps.2.a ps.1.4 ps.1.3
sub_82338EE0 (r31, base 0x82026F18) names 36:
ps.1.3 vs_3_swx vs_3_0 ps_3_sw vs_2_x vs_2_sw ps_3_0 vs_2_a ps.2.b vs_1_1 ps_2_x
vs_1_0 vs.3.xps ps_2_sw ps_2_b vs.3.sw vs.3.0 ps_2_alpha2 vs.2.x vs.2.sw vs.2.a
@@ -1252,22 +1227,6 @@ float4 FontPixelShader( VS_OUT In ) : COLOR0
C_PAD_DECODER \x8F\x89\x8A\xFA\x89\xBB
Pattern
sub_825F2CF0 (r0, base 0x8209EB30) names 30:
FinalPassBG FinalPassToneRatio FogMinDistance FogMaxDistance FogMinAmount FogMaxAmount
FirstAdaptedLuminance ExposureKey_BeginValue NoseCameraFOV NoseCameraPosX
NoseCameraPosY NoseCameraPosZ NearCameraFOV NearCameraPosX NearCameraPosY
NearCameraPosZ FarCameraFOV FarCameraPosX FarCameraPosY FarCameraPosZ SplinterCell
BGRotateScale_%1d GlareType Contrast ColorLayerA ScreenColorR ScreenColorG
ScreenColorB FinalPassType FinalPassDR
sub_825F2F88 (r0, base 0x8209EB30) names 30:
FinalPassBG FinalPassToneRatio FogMinDistance FogMaxDistance FogMinAmount FogMaxAmount
FirstAdaptedLuminance ExposureKey_BeginValue NoseCameraFOV NoseCameraPosX
NoseCameraPosY NoseCameraPosZ NearCameraFOV NearCameraPosX NearCameraPosY
NearCameraPosZ FarCameraFOV FarCameraPosX FarCameraPosY FarCameraPosZ SplinterCell
BGRotateScale_%1d GlareType Contrast ColorLayerA ScreenColorR ScreenColorG
ScreenColorB FinalPassType FinalPassDR
sub_822E3EC8 (r11, base 0x820B0000) names 29:
g_mWorldViewProjection g_mWorldViewProjectionLast g_mObjectToView g_mObjectToViewLast
g_mWorld g_Params g_UVParams g_LayerParams g_MapEnable g_MapLayerEnable ColorMap
@@ -2145,16 +2104,6 @@ float4 FontPixelShader( VS_OUT In ) : COLOR0
Constant is both a struct member and an array element. defconst: %s
Register type not found. Multi-dimensional arrays are not supported. Bad variable name.
sub_82780C10 (r0, base 0x820A9EAD) names 21:
757,228 rou_e009 rou_e008 rou_e006 rou_e005 rou_e003 rou_e004 rou_f202 rou_f201
rou_f105 rou_f101 rou_f003 rou_f001 rou_e201 ConditionToDevelop rou_e108 rou_e106
rou_e105 rou_e015 rou_e010 rou_e007
sub_827D9DD0 (r0, base 0x82074503) names 21:
hyphensuperior Gravesmall Asmall Msmall colonmonetary notequal sixinferior
Dotaccentsmall Ringsmall seveneighths onethird centinferior Aacutesmall 001.002
Semibold greaterequal Acircumflex Uacute Ugrave eacute edieresis
sub_821A8578 (r11, base 0x82023F00) names 20:
texdp3 vs_3_sw vs_3_0 vs_2_x vs_2_sw vs_2_a vs_1_1 vs_1_0 vs.3.xps vs.3.sw vs.3.0
vs.2.x vs.2.sw vs.2.a vs.1.1 vs.1.0 ps_3_sw ps_3_0 ps_2_x ps_2_sw
@@ -2274,10 +2223,6 @@ float4 FontPixelShader( VS_OUT In ) : COLOR0
ps_2_a ps.2.x ps_1_4 ps_1_2 ps.1.0 ps.1.2 ps_1_1 ps.2.b ps_1_0 ps.1.3 ps.3.sw
ps.2.a ps.3.0 ps.1.1 ps_1_3 ps.1.4 ps.2.sw
sub_824B4908 (r0, base 0x82073D58) names 17:
Ntilde Lslash acircumflex onesuperior logicalnot fouroldstyle Uacute adieresis
atilde ccedilla eacute Ugrave Ydieresis Zcaron notequal product bracketleft
sub_8265A260 (r11, base 0x82030000) names 17:
More than one buffer type specified.
Buffer type "%s" does not use a size value.
@@ -2347,11 +2292,6 @@ float4 FontPixelShader( VS_OUT In ) : COLOR0
mob_n040 rou_e202 rob_e001 mob_n500 mob_n043 mob_n042 mob_n041 rob_f001 rou_f104
rou_f102 rou_e107 1092,457 FlightTime 1066,491 ClearTimes rob_f002
sub_825C2980 (r0, base 0x82052A40) names 16:
FOGEND BORDERCOLORA FOGCOLORA BORDERCOLORG BORDERCOLORB YUVCONSTANTSC33
YUVCONSTANTSC31 YUVCONSTANTSC22 YUVCONSTANTSC23 YUVCONSTANTSC32 YUVCONSTANTSC03
YUVCONSTANTSC13 YUVCONSTANTSC21 YUVCONSTANTSC11 YUVCONSTANTSC12 FOGCOLORG
sub_826A0040 (r11, base 0x820A01AC) names 16:
PGHUD_RANGE_BAR STAGE_ID_7 PGHUD_RANGE_BAR_EM AsteroidDefinition STAGE_ID_8 STAGE_ID_9
STAGE_ID_10 STAGE_ID_11 StageResource STAGE_ID_12 STAGE_ID_13 STAGE_ID_14 STAGE_ID_15
@@ -2362,11 +2302,6 @@ float4 FontPixelShader( VS_OUT In ) : COLOR0
PGMANUVA_NUM3EFF PGHUD_ARMS_NUM%d EnumerateUnit SilhouetteModel PGMANUVA_NUM3
PGHUD_TYPE_CN WEAPONS SE_main_arm1_attach 903,343 PGTARGET_SP_READY_DLH
sub_82222E70 (r0, base 0x8209E6D8) names 15:
Generic NearCameraPosY Nebura_Size GravityFactor FarCameraPosX FarCameraFOV
YawAdjustment EnumerateAIParams RollAdjustment Player NoseCameraFOV FogMinAmount
FinalPassToneRatio NearCameraPosZ FarCameraPosZ
sub_8227F8E0 (r31, base 0x820A0E9C) names 15:
ForceBootPlayerCharacterID_11 ForceBootPlayerCharacterID_15 ForceBootPlayerCharacterID_12
ForceBootPlayerCharacterID_14 ForceBootPlayerCharacterID_13 ForceBootPlayerCharacterID_3
@@ -2429,10 +2364,6 @@ float4 FontPixelShader( VS_OUT In ) : COLOR0
Camera TYPE_END_EVENT A/START MISSION11 MISSION12 MISSION7 MISSION8 MISSION9
MISSION10 MISSION15 MISSION16 MISSION17 MISSION18 MISSION13 MISSION14
sub_8265DFB8 (r0, base 0x82074ECA) names 15:
Asmall Bsmall Csmall Dsmall Esmall Fsmall Gsmall Hsmall Ismall Jsmall Ksmall
Lsmall Msmall Nsmall Osmall
sub_82664700 (r11, base 0x82030000) names 15:
p->xUR1 = __vspltisw(1);
%s = __vmsum3fp(%s, %s);
@@ -2448,10 +2379,6 @@ float4 FontPixelShader( VS_OUT In ) : COLOR0
%s = __vsel(%s, %s, %s);
sub_82787E38 (r0, base 0x82074B66) names 15:
Ucircumflex bsuperior Zcaron osuperior ssuperior atilde nineoldstyle icircumflex
Yacute Udieresis edieresis Psmall zerosuperior aacute dsuperior
sub_8285F2C8 (r5, base 0x820AE7AC) names 15:
%4d / %4d
%4d / %4d
@@ -2558,10 +2485,6 @@ float4 FontPixelShader( VS_OUT In ) : COLOR0
199,333 360,333 BrokenData 260,367 441,367 AUTO_SAVED CLEARED 260,333 441,333
%03d:%02d:%02d 513,367 FlightTime 703,367 RatioOfClear
sub_822CC130 (r0, base 0x82026F74) names 14:
vs_3_sw vs.3.sw vs_1_0 ps_2_alpha2 vs.1.0 vs.2.a vs_2_x vs_1_1 vs.3.xps ps.1.1
vs_2_sw vs_3_0 vs.2.x ps.1.3
sub_822F2E58 (r31, base 0x820A97E4) names 14:
STAGE14 STATE_GAME_CLEAR STAGE04 STAGE06 MISSION_SELECT LOAD_BASES STATE_STAND_BY
STAGE13 STAGE11 STAGE07 STAGE10 STAGE09 STAGE12 STAGE08
@@ -2692,10 +2615,6 @@ float4 FontPixelShader( VS_OUT In ) : COLOR0
LuminanceFX_BrightB LuminanceFX_TonedRatio LuminanceFX_Vignetting
LuminanceFX_VignetSharpness
sub_8252C4E8 (r0, base 0x82074617) names 14:
scedilla cacute parenright semicolon quoteright .notdef percent parenleft hyphen
Scedilla dcroat Ccaron asciicircum exclam
sub_825635C8 (r31, base 0x8209E230) names 14:
DOF_FarFocal FogLinear FogMinDistance Nebura_Size Nebura_MiddleNear FogMaxAmount
Nebura_SpeedScale UnsharpMask_R Nebura_NearAmount FinalPassDB FinalPassBR FinalPassBG
@@ -2773,14 +2692,6 @@ float4 FontPixelShader( VS_OUT In ) : COLOR0
__vspltw(%s, 0) __vspltw(%s, 1) __vsel(%s, %s, %s) __vcfux(%s, %d) __vspltisw(0)
__vspltw(%s, 2) p->xSR2 __lvx(%s, 0)
sub_82435448 (r0, base 0x82027040) names 13:
ps_1_1 ps_1_4 ps_2_a ps_1_3 ps_1_2 ps.2.x ps_1_0 ps.3.sw ps.3.0 ps.2.sw ps.2.b
ps.1.4 ps.2.a
sub_824B42E8 (r0, base 0x820743A3) names 13:
Dieresissmall figuredash dollarinferior Medium Adieresissmall Atildesmall Aringsmall
Agravesmall Aacutesmall Ethsmall threequartersemdash agrave partialdiff
sub_824E76D0 (r10, base 0x8209FC64) names 13:
AccPitchFactor AV_AxisMode_Min DecPitchFactor AV_AxisMode_Max GaugeMaximum
ChargeMinimum ChargeMaximum AttackTime_Minimum StageResource BackGroundID
@@ -2842,10 +2753,6 @@ float4 FontPixelShader( VS_OUT In ) : COLOR0
Internal error 0x%08X while generating code. Please send this shader to xboxds@xbox.com.
Microcode comparison failed. Please send your HLSL code to xboxds@xbox.com.
sub_826A7BF0 (r0, base 0x82074DCE) names 13:
periodsuperior Ksmall Jsmall Lsmall Bsmall Csmall Dsmall Esmall Fsmall Gsmall
Hsmall Ismall Msmall
sub_827030F8 (r11, base 0x82050000) names 13:
Assertion failed: %s (%s:%u)
d:\xenon\jun06\core\private\xtl\graphics\xgraphics\ucode\ssm\statecompiler\ssmstatecompiler.cpp
@@ -2925,10 +2832,6 @@ float4 FontPixelShader( VS_OUT In ) : COLOR0
LANGUAGE PGMARKTGT PGMARKLOCKON PGMANUVA_EFF3 PGMARK_GAUGE_SUB_BASE FrameAnimationType
SYSTEM PGMARK_SHIELD_SUB_BASE PGMARK_GAUGE_BAR PGMARK4 PGMARK3 PGMARK2
sub_82766DB0 (r0, base 0x8207454A) names 12:
notequal lessequal product \x82\x42[`.null Scedilla cacute scedilla B[`.null Cacute
Oslashsmall Uacutesmall Udieresissmall
sub_82766DB0 (r11, base 0x82050000) names 12:
instruction options arrays are not supported in inline microcode predication
alloc option setGradient instructions muls_prev2 instruction kill instructions