2024-03-29 16:14 CET

View Issue Details Jump to Notes ]
IDProjectCategoryView StatusLast Update
0004788Spring engineGeneralpublic2015-06-10 11:01
Reporterabma 
Assigned TojK 
PrioritynormalSeveritycrashReproducibilityalways
StatusresolvedResolutionfixed 
Product Version98.0.1+git 
Target VersionFixed in Version 
Summary0004788: crash / "Failed to allocate memory" when doing /cheat /give 500 aafus + ctrl-d
Descriptionthats a maybe stupid test / edge condition, but imo it shouldn't crash.

when i change in
rts/Game/GameHelper.cpp,

CGameHelper::DoExplosionDamage()

so all damages "damage later", it works. also it runs a lot smoother.
Steps To Reproduce/cheat
/give 500 aafus

select one aafus + ctrl + d
TagsNo tags attached.
Checked infolog.txt for Errors
Attached Files

-Relationships
+Relationships

-Notes

~0014505

abma (administrator)

[f=0000288] [GiveUnits] spawned 500 aafus unit(s) for team 0
[f=0000391] Advanced Fusion Reactor: self-destruct in 5s
[f=0000421] Advanced Fusion Reactor: self-destruct in 4s
[f=0000451] Advanced Fusion Reactor: self-destruct in 3s
[f=0000481] Advanced Fusion Reactor: self-destruct in 2s
[f=0000511] Advanced Fusion Reactor: self-destruct in 1s
[f=0000526] -> Advanced Fusion Reactor is being attacked!
src/central_freelist.cc:333] tcmalloc: allocation failed 16384
[f=0000526] [CrashHandler] Error: Failed to allocate memory
[f=0000526] [CrashHandler] Error: Stacktrace for Spring 98.0.1-695-gbc9298a develop:
src/central_freelist.cc:333] tcmalloc: allocation failed 16384
src/central_freelist.cc:333] tcmalloc: allocation failed 16384
src/central_freelist.cc:333] tcmalloc: allocation failed 16384
src/central_freelist.cc:333] tcmalloc: allocation failed 16384
src/central_freelist.cc:333] tcmalloc: allocation failed 16384
src/central_freelist.cc:333] tcmalloc: allocation failed 16384
src/central_freelist.cc:333] tcmalloc: allocation failed 16384
src/central_freelist.cc:333] tcmalloc: allocation failed 16384
src/central_freelist.cc:333] tcmalloc: allocation failed 16384
src/central_freelist.cc:333] tcmalloc: allocation failed 16384
src/central_freelist.cc:333] tcmalloc: allocation failed 16384
src/central_freelist.cc:333] tcmalloc: allocation failed 16384
src/central_freelist.cc:333] tcmalloc: allocation failed 16384
src/central_freelist.cc:333] tcmalloc: allocation failed 16384
src/central_freelist.cc:333] tcmalloc: allocation failed 16384
src/central_freelist.cc:333] tcmalloc: allocation failed 16384
src/central_freelist.cc:333] tcmalloc: allocation failed 16384
src/central_freelist.cc:333] tcmalloc: allocation failed 16384
Speicherzugriffsfehler

~0014509

abma (administrator)

Last edited: 2015-06-02 01:55

View 2 revisions

i guess it crashes because of stack limit, my computer has 16GB RAM...

~0014510

abma (administrator)

yep, with ulimit -s 16000 it works (default is 8192)

~0014516

jK (developer)

uploaded a profile graph

~0014517

jK (developer)

Last edited: 2015-06-02 11:30

View 2 revisions

k, the cause is:

All `that` (explosion, particle creation) happens in a _single_ gameframe.
And particleSaturation is only updated in drawFrames. So it goes FAR over the maximum particle count (120k CProjectiles in a fast test).

Solution: make particleSaturation update independent of drawFrames

~0014563

jK (developer)

Fix b930c6a183400c4d882060a93a8e6d0bf3ca27c1 committed to develop branch: fix 0004788: fix particleSaturation, repo: spring changeset id: 5058
+Notes

-Issue History
Date Modified Username Field Change
2015-06-01 23:59 abma New Issue
2015-06-02 00:00 abma Note Added: 0014505
2015-06-02 00:00 abma Steps to Reproduce Updated View Revisions
2015-06-02 01:52 abma Description Updated View Revisions
2015-06-02 01:54 abma Note Added: 0014509
2015-06-02 01:55 abma Note Edited: 0014509 View Revisions
2015-06-02 01:57 abma Note Added: 0014510
2015-06-02 01:58 abma Description Updated View Revisions
2015-06-02 02:14 abma Summary crash / "Failed to allocate memory" when doing /cheat /give 500 aafus => crash / "Failed to allocate memory" when doing /cheat /give 500 aafus + ctrl-d
2015-06-02 10:58 jK File Added: profile.png
2015-06-02 10:59 jK Note Added: 0014516
2015-06-02 11:29 jK Note Added: 0014517
2015-06-02 11:30 jK Note Edited: 0014517 View Revisions
2015-06-10 11:01 jK Changeset attached => spring develop b930c6a1
2015-06-10 11:01 jK Note Added: 0014563
2015-06-10 11:01 jK Assigned To => jK
2015-06-10 11:01 jK Status new => resolved
2015-06-10 11:01 jK Resolution open => fixed
+Issue History