Align the metadata table on all platforms
authortzagallo@apple.com <tzagallo@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 8 Dec 2018 01:12:57 +0000 (01:12 +0000)
committertzagallo@apple.com <tzagallo@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 8 Dec 2018 01:12:57 +0000 (01:12 +0000)
commit4d29fdd724e3f3b9dffe99956aa28cce281150a0
treee9fd5b35a66ca732c9cf0e93c2e1089940e5d501
parent1e29632ddb1558bf7f7984b447c655d64b38a394
Align the metadata table on all platforms
https://bugs.webkit.org/show_bug.cgi?id=192050
<rdar://problem/46312674>

Reviewed by Mark Lam.

Although certain platforms don't require the metadata to be aligned,
values were being concurrently read and written to ValueProfiles,
which caused crashes since these operations are not atomic on unaligned
addresses.

* bytecode/Opcode.cpp:
(JSC::metadataAlignment):
* bytecode/Opcode.h:
* bytecode/UnlinkedMetadataTableInlines.h:
(JSC::UnlinkedMetadataTable::finalize):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@238997 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/bytecode/Opcode.cpp
Source/JavaScriptCore/bytecode/Opcode.h
Source/JavaScriptCore/bytecode/UnlinkedMetadataTableInlines.h