Open tkoolen opened 6 years ago
Note that
foo!(a, b) = a .= b
@testset ".=" begin
a = zeros(3)
b = 1.0
foo!(a,b)
@test (@allocated foo!(a, b)) == 0
end
passes, so I wouldn't expect it to cause unexpected allocations in production code, but I don't know what the root cause is.
I found this while trying to get TypeSortedCollections up to speed with the new
broadcast
framework. Consider the following two test sets:On 0.6.2, both tests pass, but on
the first test passes, but the second fails with 3408 bytes of allocation returned from
@allocated
.Just wondering if this is expected, what the root cause might be, and whether this could lead to actual performance problems in production code.