Skip to content

Fix object-search warnings on Unity 6000.4 - #629

Closed
Eli Pinkerton (wallstop) wants to merge 1 commit into
masterfrom
codex/465-object-search
Closed

Eli Pinkerton (wallstop) wants to merge 1 commit into
masterfrom
codex/465-object-search

Conversation

@wallstop

@wallstop Eli Pinkerton (wallstop) commented Oct 14, 2026 •

Copy link
Copy Markdown
Collaborator

Why

Unity 6000.4 prints obsolete API warnings when the diagnostics windows and sample compile.

What changed

Use the replacement object-search APIs starting with Unity 6000.4. Preserve inactive-object filters and all older Unity branches. Extend both existing window discovery tests with active and inactive scene cases.

How we know

  • Unity 6000.4.6f1: both affected window fixtures and seven sample source contracts pass twice, 282 tests per run.
  • All four active/inactive discovery cases pass. Native cleanup restores the original clean scene after every run.
  • Offline C# 9 sample compilation against actual Unity references reduces seven obsolete warnings to zero. Three existing serialized-field warnings remain.
  • All four supported Unity versions pass EditMode, PlayMode, and standalone tests in run 38549357506.
  • Static checks, C# formatting, spelling, package validation, and commit hooks pass.

Continued in PR619

PR619 now includes this correction in commit 885f51de.
Its published head is a4cb3a98.
All seven source and test blobs match this PR exactly.
The exact changelog entry is preserved with the other release entries.

This draft is closed as superseded.
Issue #628 remains open for wallstop review and final integrated backend qualification.
The prior CI results above qualify this PR's original head.

@github-actions

Copy link
Copy Markdown
Contributor

Performance Numbers

Measured commit: 88e7d4d
Trusted reporting code (PR base): 916f0d7
Measured historical baseline: 1234a39
Workflow run: 38549357495 attempt 1

Benchmark methodology and execution profile are unchanged; the historical Standalone comparison is diagnostic regression smoke.

Historical Standalone delta

Delta direction: + is better; - is worse.

Scenario Baseline Current Delta
Empty Bus Dispatch 49.84 M emits/sec 51.40 M emits/sec +3.12%
Untargeted Flood (One Handler) 46.39 M emits/sec 47.49 M emits/sec +2.39%
Untargeted Flood (One Direct Handler) 47.90 M emits/sec 48.45 M emits/sec +1.14%
Untargeted Flood (Two Handlers, One Priority) 43.33 M emits/sec 44.24 M emits/sec +2.10%
Untargeted Flood (Three Handlers, One Priority) 40.80 M emits/sec 41.38 M emits/sec +1.42%
Untargeted Flood (Four Handlers, One Priority) 38.90 M emits/sec 37.70 M emits/sec -3.08%
Untargeted Flood (Four Handlers, Four Priorities) 38.89 M emits/sec 38.31 M emits/sec -1.50%
Untargeted Flood (Sixteen Handlers, One Priority) 20.51 M emits/sec 21.23 M emits/sec +3.50%
Untargeted Flood (One Inactive Handler) 49.04 M emits/sec 50.14 M emits/sec +2.25%
Untargeted First Dispatch (Cold, Distinct Types) 0.191 ms 0.191 ms 0.00%
Targeted Flood (No Matching Target) 17.55 M emits/sec 17.88 M emits/sec +1.93%
Targeted Flood (One Listener) 14.65 M emits/sec 15.07 M emits/sec +2.88%
Targeted Flood (Sixteen Listeners) 11.12 M emits/sec 11.36 M emits/sec +2.10%
Targeted First Dispatch (Cold, Distinct Types) 0.185 ms 0.185 ms 0.00%
Broadcast Flood (One Handler) 31.65 M emits/sec 31.60 M emits/sec -0.14%
Broadcast First Dispatch (Cold, Distinct Types) 0.177 ms 0.178 ms -0.56%
Targeted Post Route (Stable) 27.28 M emits/sec 26.44 M emits/sec -3.08%
Targeted Post Route (Rewritten, Empty Final Route) 23.20 M emits/sec 22.97 M emits/sec -0.99%
Targeted Post Route (Rewritten, Populated Final Route) 16.63 M emits/sec 16.50 M emits/sec -0.75%
Broadcast Post Route (Stable) 28.02 M emits/sec 28.00 M emits/sec -0.07%
Broadcast Post Route (Rewritten, Empty Final Route) 24.65 M emits/sec 24.77 M emits/sec +0.48%
Broadcast Post Route (Rewritten, Populated Final Route) 17.22 M emits/sec 17.83 M emits/sec +3.56%
Interceptor Heavy (Four Interceptors) 34.28 M emits/sec 35.60 M emits/sec +3.86%
Post-Processing Heavy (Four Post-Processors) 28.07 M emits/sec 29.03 M emits/sec +3.43%
Message Bus Construction (1000) 19.154 ms 17.901 ms +6.54%
Registration Token Construction (1000, Prebuilt Handler + Bus) 0.050 ms 0.048 ms +4.00%
Registration Flood (1000 Types, Cold Bus) 474.809 ms 465.120 ms +2.04%
Registration Flood (1000 Types, Warm JIT) 2.753 ms 3.181 ms -15.55%
Untargeted Registration (Marginal, 1000 Same-Type) 0.403 ms 0.431 ms -6.95%
Targeted Registration (Marginal, 1000 Same-Type) 0.449 ms 0.486 ms -8.24%
Broadcast Registration (Marginal, 1000 Same-Type) 0.481 ms 0.487 ms -1.25%
Deregistration Flood (1000 Types, Cold) 1.754 ms 1.842 ms -5.02%
Deregistration Flood (1000 Types, Warm JIT) 0.928 ms 1.134 ms -22.20%
Registration Attribution (Direct Bus, 131072) 29.663 ms 29.409 ms +0.86%
Registration Attribution (Direct Handler, 131072) 67.177 ms 63.947 ms +4.81%
Registration Attribution (Token Stage, 131072) 11.295 ms 10.796 ms +4.42%
Registration Attribution (Token Active, 131072) 91.167 ms 93.866 ms -2.96%
Deregistration Attribution (Direct Bus, 131072) 6.976 ms 6.980 ms -0.06%
Deregistration Attribution (Direct Handler, 131072) 27.839 ms 25.726 ms +7.59%
Deregistration Attribution (Token Remove, 131072) 30.623 ms 30.117 ms +1.65%
Deregistration Attribution (Token Disable, 131072) 32.334 ms 33.902 ms -4.85%
Global -> 1 subscriber 44.15 M emits/sec 44.34 M emits/sec +0.43%
Global -> 16 subscribers 22.01 M emits/sec 22.62 M emits/sec +2.78%
Keyed/targeted -> 1 of many 14.18 M emits/sec 14.85 M emits/sec +4.73%
Priority-ordered dispatch 37.20 M emits/sec 37.07 M emits/sec -0.33%
Filtered/intercepted dispatch 35.74 M emits/sec 35.06 M emits/sec -1.91%
Post-processing dispatch 32.30 M emits/sec 33.39 M emits/sec +3.37%
Intercepted + post-processed dispatch 30.19 M emits/sec 29.04 M emits/sec -3.83%
Subscribe/unsubscribe churn 1.38 M emits/sec 1.43 M emits/sec +3.60%
Struct message (no boxing) 45.13 M emits/sec 45.61 M emits/sec +1.07%

Current TargetMap evidence

These raw rows are current-run diagnostics. Use fresh bracketed controls before accepting a micro-optimization.

[Standalone] DXM_TARGET_MAP_BENCHMARK scenario=TargetMap_16_Churn keyCount=16 operation=Churn totalOperations=2150000 operationsPerSecond=429683.504 wallClockMs=5003.683 gcAllocations=-1 gcAllocatedBytes=-1 targetMapEntries=16 targetMapCapacity=32 observedInvocations=2170000
[Standalone] DXM_TARGET_MAP_BENCHMARK scenario=TargetMap_16_Hit keyCount=16 operation=Hit totalOperations=76040000 operationsPerSecond=15207373.152 wallClockMs=5000.206 gcAllocations=-1 gcAllocatedBytes=-1 targetMapEntries=16 targetMapCapacity=32 observedInvocations=76060000
[Standalone] DXM_TARGET_MAP_BENCHMARK scenario=TargetMap_16_Miss keyCount=16 operation=Miss totalOperations=89280000 operationsPerSecond=17854887.641 wallClockMs=5000.312 gcAllocations=-1 gcAllocatedBytes=-1 targetMapEntries=16 targetMapCapacity=32 observedInvocations=0
[Standalone] DXM_TARGET_MAP_BENCHMARK scenario=TargetMap_1_Churn keyCount=1 operation=Churn totalOperations=2180000 operationsPerSecond=435577.359 wallClockMs=5004.852 gcAllocations=-1 gcAllocatedBytes=-1 targetMapEntries=1 targetMapCapacity=4 observedInvocations=2200000
[Standalone] DXM_TARGET_MAP_BENCHMARK scenario=TargetMap_1_Hit keyCount=1 operation=Hit totalOperations=75430000 operationsPerSecond=15085155.533 wallClockMs=5000.280 gcAllocations=-1 gcAllocatedBytes=-1 targetMapEntries=1 targetMapCapacity=4 observedInvocations=75450000
[Standalone] DXM_TARGET_MAP_BENCHMARK scenario=TargetMap_1_Miss keyCount=1 operation=Miss totalOperations=87200000 operationsPerSecond=17437247.007 wallClockMs=5000.789 gcAllocations=-1 gcAllocatedBytes=-1 targetMapEntries=1 targetMapCapacity=4 observedInvocations=0
[Standalone] DXM_TARGET_MAP_BENCHMARK scenario=TargetMap_256_Churn keyCount=256 operation=Churn totalOperations=2080000 operationsPerSecond=415665.531 wallClockMs=5004.023 gcAllocations=-1 gcAllocatedBytes=-1 targetMapEntries=256 targetMapCapacity=512 observedInvocations=2100000
[Standalone] DXM_TARGET_MAP_BENCHMARK scenario=TargetMap_256_Hit keyCount=256 operation=Hit totalOperations=68540000 operationsPerSecond=13707810.832 wallClockMs=5000.069 gcAllocations=-1 gcAllocatedBytes=-1 targetMapEntries=256 targetMapCapacity=512 observedInvocations=68560000
[Standalone] DXM_TARGET_MAP_BENCHMARK scenario=TargetMap_256_Miss keyCount=256 operation=Miss totalOperations=84390000 operationsPerSecond=16877433.593 wallClockMs=5000.168 gcAllocations=-1 gcAllocatedBytes=-1 targetMapEntries=256 targetMapCapacity=512 observedInvocations=0
[Standalone] DXM_TARGET_MAP_BENCHMARK scenario=TargetMap_4096_Churn keyCount=4096 operation=Churn totalOperations=1890000 operationsPerSecond=375992.688 wallClockMs=5026.694 gcAllocations=-1 gcAllocatedBytes=-1 targetMapEntries=4096 targetMapCapacity=8192 observedInvocations=1910000
[Standalone] DXM_TARGET_MAP_BENCHMARK scenario=TargetMap_4096_Hit keyCount=4096 operation=Hit totalOperations=63520000 operationsPerSecond=12702796.537 wallClockMs=5000.474 gcAllocations=-1 gcAllocatedBytes=-1 targetMapEntries=4096 targetMapCapacity=8192 observedInvocations=63540000
[Standalone] DXM_TARGET_MAP_BENCHMARK scenario=TargetMap_4096_Miss keyCount=4096 operation=Miss totalOperations=81950000 operationsPerSecond=16388356.903 wallClockMs=5000.501 gcAllocations=-1 gcAllocatedBytes=-1 targetMapEntries=4096 targetMapCapacity=8192 observedInvocations=0
[Standalone] DXM_TARGET_MAP_BENCHMARK scenario=TargetMap_4_Churn keyCount=4 operation=Churn totalOperations=2160000 operationsPerSecond=430736.357 wallClockMs=5014.668 gcAllocations=-1 gcAllocatedBytes=-1 targetMapEntries=4 targetMapCapacity=8 observedInvocations=2180000
[Standalone] DXM_TARGET_MAP_BENCHMARK scenario=TargetMap_4_Hit keyCount=4 operation=Hit totalOperations=75370000 operationsPerSecond=15073108.275 wallClockMs=5000.296 gcAllocations=-1 gcAllocatedBytes=-1 targetMapEntries=4 targetMapCapacity=8 observedInvocations=75390000
[Standalone] DXM_TARGET_MAP_BENCHMARK scenario=TargetMap_4_Miss keyCount=4 operation=Miss totalOperations=86170000 operationsPerSecond=17233476.102 wallClockMs=5000.152 gcAllocations=-1 gcAllocatedBytes=-1 targetMapEntries=4 targetMapCapacity=8 observedInvocations=0
[Standalone] DXM_TARGET_MAP_CONSTRUCTION keyCount=1 wallClockMs=0.000102 operationsPerSecond=9842519.685 gcAllocations=-1 gcAllocatedBytes=-1 targetMapCapacity=4
[Standalone] DXM_TARGET_MAP_CONSTRUCTION keyCount=16 wallClockMs=0.000633 operationsPerSecond=1580246.914 gcAllocations=-1 gcAllocatedBytes=-1 targetMapCapacity=32
[Standalone] DXM_TARGET_MAP_CONSTRUCTION keyCount=256 wallClockMs=0.008325 operationsPerSecond=120120.120 gcAllocations=-1 gcAllocatedBytes=-1 targetMapCapacity=512
[Standalone] DXM_TARGET_MAP_CONSTRUCTION keyCount=4 wallClockMs=0.000226 operationsPerSecond=4416961.131 gcAllocations=-1 gcAllocatedBytes=-1 targetMapCapacity=8
[Standalone] DXM_TARGET_MAP_CONSTRUCTION keyCount=4096 wallClockMs=0.127100 operationsPerSecond=7867.821 gcAllocations=-1 gcAllocatedBytes=-1 targetMapCapacity=8192

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