mirror of
https://github.com/RGBCube/serenity
synced 2025-06-01 08:28:11 +00:00
LibJS/Bytecode: Invalidate inline caches on unique shape mutation
Since we can't rely on shape identity (i.e its pointer address) for unique shapes, give them a serial number that increments whenever a mutation occurs. Inline caches can then compare this serial number against what they have seen before.
This commit is contained in:
parent
17d23e76e5
commit
cf6792ec40
6 changed files with 38 additions and 5 deletions
|
@ -48,6 +48,7 @@ struct CacheablePropertyMetadata {
|
|||
};
|
||||
Type type { Type::NotCacheable };
|
||||
Optional<u32> property_offset;
|
||||
u64 unique_shape_serial_number { 0 };
|
||||
};
|
||||
|
||||
class Object : public Cell {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue