Thanks, I changed and with the leak detection on the console is possible to
see it's trying to allocate a lot of memory.

It should be only a insert of a pointer / integer in the unordered map, but
for some reason it tries to allocate a lot of memory for that - until it
tries to allocate more memory than it's possible.

It still crashes around the same point.

On Tue, Oct 20, 2020, 06:59 eri0o o <[email protected]> wrote:

> If code is needed this can be seen here:
>
> https://ericoporto.github.io/agsjs/
>
> Code that was used to generate that:
> https://github.com/ericoporto/ags/tree/ags3-emscripten
>
> You can see it crash after 25 allocations of managed objects, which is
> this line here:
>
>
> https://github.com/ericoporto/ags/blob/9e9229fc26fcce9f365e2a60f0f87e20a298113c/Engine/ac/dynobj/managedobjectpool.cpp#L158
>
> On Tue, Oct 20, 2020, 00:11 eri0o o <[email protected]> wrote:
>
>> Hello,
>>
>> I am using std::unordered_map<const char*,int32_t> and my wasm result has
>> a really slow insert time. Is there something to that I should be aware of?
>> My code crashes after 25 inserts for lack of memory, no matter what.
>>
>> It's a bit crazy because everything else works great.
>>
>> Regards,
>>
>> Érico
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"emscripten-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/emscripten-discuss/CAG1KTJeAuuD5Y%3DF0VQN4a9sgBROTEDiqRo%3DXJ1A7bsXLRO7g0Q%40mail.gmail.com.

Reply via email to