Hello

I noticed a weird behavior when I'm benchmarking with testing.B.Loop() code 
that uses iterators .
The benchmark shows allocations where I start to iterate the iterator, and 
where I declare variables (before the loop) that are used inside the 
iterator loop.
I know that my code is not doing any allocation, so it's strange.
If I change my benchmark to use the old "range b.N", then it doesn't show 
this strange behavior.
If I check allocations with "testing.AllocsPerRun", I don't see any 
allocation.

Is that a know issue ? Should I open a bug ?
What should I do ? Use the old benchmarking method ?

Regards

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion visit 
https://groups.google.com/d/msgid/golang-nuts/70456dc1-3380-40fd-951d-e52275bc48a5n%40googlegroups.com.

Reply via email to