MCPcopy Create free account
hub / github.com/EngoEngine/ecs / BenchmarkIdiomatic

Function BenchmarkIdiomatic

entity_test.go:454–467  ·  view source on GitHub ↗
(b *testing.B)

Source from the content-addressed store, hash-verified

452}
453
454func BenchmarkIdiomatic(b *testing.B) {
455 preload := func() {}
456 setup := func(w *World) {
457 sys12 := &MySystemOneTwo{}
458 w.AddSystem(sys12)
459
460 e1 := MyEntity1{}
461 e1.BasicEntity = NewBasic()
462
463 sys12.Add(&e1.BasicEntity, &e1.MyComponent1, nil)
464 }
465
466 Bench(b, preload, setup)
467}
468
469func BenchmarkIdiomaticDouble(b *testing.B) {
470 preload := func() {}

Callers

nothing calls this directly

Calls 4

AddMethod · 0.95
NewBasicFunction · 0.85
BenchFunction · 0.85
AddSystemMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…