[v8-users] Native string#hashCode?

2020-11-20 Thread pawel.b...@gmail.com
I've been recently wondering whether there's plans to add native 
implementation of hashCode to string (similar to Java)?

Context: we're using hash based data structures quite extensively. The lack 
of builtin hashCode is a bit of a pain on performance side and it's quite 
hard to get around this.

Thanks,
Pawel

-- 
-- 
v8-users mailing list
v8-users@googlegroups.com
http://groups.google.com/group/v8-users
--- 
You received this message because you are subscribed to the Google Groups 
"v8-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to v8-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/v8-users/96f6a6c3-db46-4462-a017-9e22c6f72591n%40googlegroups.com.


[v8-users] Recompute handler

2021-02-08 Thread pawel.b...@gmail.com
I tried searching on the group, v8.dev, search engine... could someone give 
a short explanation on what recompute handler is (in terms of IC states), 
when it triggers and how is it different from Premonomorphic state?

In my case it seems to be triggered between Premonomorphic and monomorphic 
state - and I can't quite understand what that means.

Thanks,
Pawel

-- 
-- 
v8-users mailing list
v8-users@googlegroups.com
http://groups.google.com/group/v8-users
--- 
You received this message because you are subscribed to the Google Groups 
"v8-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to v8-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/v8-users/d0a104dd-00ac-4de7-bcc0-321dfde48cdcn%40googlegroups.com.


Re: [v8-users] Recompute handler

2021-02-08 Thread pawel.b...@gmail.com
Oh ok, I understand, thanks! Is there some (hopefully relatively easy...) 
way to see what triggered recompute handler?

On Monday, 8 February 2021 at 16:33:14 UTC Toon Verwaest wrote:

> This is a crutch to ensure we don't go poly/megamorphic in the case some 
> assumptions have changed. We use it when e.g., someone modified the 
> prototype chain of the current receiver. The map of the receiver isn't 
> different from the map that we checked in the inline cache. Something else 
> caused us to miss. The idea is that such changes hopefully happen fairly 
> infrequently (properties are rarely added/deleted from objects on the 
> prototype chain).
>
> On Mon, Feb 8, 2021 at 5:25 PM pawel.b...@gmail.com  
> wrote:
>
>> I tried searching on the group, v8.dev, search engine... could someone 
>> give a short explanation on what recompute handler is (in terms of IC 
>> states), when it triggers and how is it different from Premonomorphic state?
>>
>> In my case it seems to be triggered between Premonomorphic and 
>> monomorphic state - and I can't quite understand what that means.
>>
>> Thanks,
>> Pawel
>>
>> -- 
>> -- 
>> v8-users mailing list
>> v8-u...@googlegroups.com
>> http://groups.google.com/group/v8-users
>> --- 
>> You received this message because you are subscribed to the Google Groups 
>> "v8-users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to v8-users+u...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/v8-users/d0a104dd-00ac-4de7-bcc0-321dfde48cdcn%40googlegroups.com
>>  
>> <https://groups.google.com/d/msgid/v8-users/d0a104dd-00ac-4de7-bcc0-321dfde48cdcn%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
>

-- 
-- 
v8-users mailing list
v8-users@googlegroups.com
http://groups.google.com/group/v8-users
--- 
You received this message because you are subscribed to the Google Groups 
"v8-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to v8-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/v8-users/e78d87a1-e099-4668-9e3c-7415bdeff3d4n%40googlegroups.com.


[v8-users] Are switch-case statements optimised for up to 10 cases?

2021-05-16 Thread pawel.b...@gmail.com
Hi,

I noticed a performance cliff when using switch case statements longer than 
10 cases. I did a bit of poking around and noticed that different 
instructions are used to handle cases above the 10th. Until the 10th its 
"JumpIfTrue" and above "JumpIfTrueConstant".

Two questions:
 - are people aware of performance optimisation where switch-case 
statements might deteriorate after 10 cases?
 - might those different bytecode instructions be causing this?

Thanks,
Pawel

-- 
-- 
v8-users mailing list
v8-users@googlegroups.com
http://groups.google.com/group/v8-users
--- 
You received this message because you are subscribed to the Google Groups 
"v8-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to v8-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/v8-users/7ac7c50a-3572-4ec2-9b42-cab21215ff9an%40googlegroups.com.