2025-07-23 01:29 CEST

View Issue Details Jump to Notes ]
IDProjectCategoryView StatusLast Update
0005296Spring engineGeneralpublic2016-10-09 21:52
Reporterlamer 
Assigned Toabma 
PrioritynormalSeveritymajorReproducibilityalways
StatusresolvedResolutionfixed 
Product Version102.0+git 
Target Version104.0Fixed in Version 
Summary0005296: SCOPED_TIMER hash collision
Descriptionname: "PathManager::Update"
hash: 1842

name: "AI t:3 id:3 CircuitAI 0.9"
hash: 1842

And so profiler lies about AI's time.
Steps To Reproduce1) Add 4+ CircuitAI's
2) /debug
Additional InformationFailer: https://github.com/spring/spring/blob/102.0/rts/System/TimeProfiler.cpp#L31
TagsNo tags attached.
Checked infolog.txt for Errors
Attached Files

-Relationships
+Relationships

-Notes

~0016489

hokomoko (developer)

:D

~0016522

abma (administrator)

Last edited: 2016-07-19 00:46

View 2 revisions

IMHO major as these values are very important. any error here will cost us A LOT of time.

~0016523

abma (administrator)

@lamer:

thanks a lot for finding + reporting this!

~0016524

abma (administrator)

one of the FNV-variants could be an alternative:
http://isthe.com/chongo/tech/comp/fnv/

(replacing the function is low prio i guess, but adding the assert imo was important)

~0016677

abma (administrator)

would be using an enum for this the best?

-> no hashing needed at all

~0016684

hokomoko (developer)

1) hash function was improved considerably here:
https://github.com/spring/spring/commit/741aa393454a738d57e0c04f224108040bfaaa07
so I believe we won't hit any collision in the foreseeable future.
2) I prefer not using enums since they prevent creating new timers on the fly (like AIs do).

~0016757

abma (administrator)

the asserts hopefully alert us when we hit the next collision :)
+Notes

-Issue History
Date Modified Username Field Change
2016-07-10 13:43 lamer New Issue
2016-07-10 14:03 hokomoko Note Added: 0016489
2016-07-19 00:46 abma Severity minor => major
2016-07-19 00:46 abma Note Added: 0016522
2016-07-19 00:46 abma Note Edited: 0016522 View Revisions
2016-07-19 00:48 abma Target Version => 103.0
2016-07-19 01:03 abma Note Added: 0016523
2016-07-19 02:07 abma Note Added: 0016524
2016-07-19 15:28 abma Target Version 103.0 => 104.0
2016-09-17 03:16 abma Note Added: 0016677
2016-09-18 11:11 hokomoko Note Added: 0016684
2016-09-18 11:12 hokomoko Changeset attached => spring develop 741aa393
2016-10-09 21:52 abma Note Added: 0016757
2016-10-09 21:52 abma Status new => resolved
2016-10-09 21:52 abma Resolution open => fixed
2016-10-09 21:52 abma Assigned To => abma
+Issue History