Modified: trunk/Source/_javascript_Core/ChangeLog (280686 => 280687)
--- trunk/Source/_javascript_Core/ChangeLog 2021-08-05 15:02:38 UTC (rev 280686)
+++ trunk/Source/_javascript_Core/ChangeLog 2021-08-05 15:14:42 UTC (rev 280687)
@@ -1,3 +1,20 @@
+2021-08-05 Zan Dobersek <[email protected]>
+
+ Use reinterpret_cast_ptr in KeywordLookupGenerator, PropertyMapHashTable
+ https://bugs.webkit.org/show_bug.cgi?id=228819
+
+ Reviewed by Adrian Perez de Castro.
+
+ Switch to using reinterpret_cast_ptr in KeywordLookupGenerator (which
+ generates the KeywordLookup.h header) and PropertyMapHashTable, reducing
+ a bit the GCC warning spewage when compiling for targets benefitting
+ from the reinterpret_cast_ptr workaround.
+
+ * KeywordLookupGenerator.py:
+ * runtime/PropertyMapHashTable.h:
+ (JSC::PropertyTable::table):
+ (JSC::PropertyTable::table const):
+
2021-08-04 Yijia Huang <[email protected]>
[ARM64] Fix Zoom black screen during video meeting on Safari
Modified: trunk/Source/_javascript_Core/KeywordLookupGenerator.py (280686 => 280687)
--- trunk/Source/_javascript_Core/KeywordLookupGenerator.py 2021-08-05 15:02:38 UTC (rev 280686)
+++ trunk/Source/_javascript_Core/KeywordLookupGenerator.py 2021-08-05 15:14:42 UTC (rev 280687)
@@ -219,6 +219,8 @@
trie.fillOut()
print("// This file was generated by KeywordLookupGenerator.py. Do not edit.")
print("""
+#include <wtf/StdLibExtras.h>
+
#if CPU(NEEDS_ALIGNED_ACCESS)
#define COMPARE_2CHARS(address, char1, char2) \\
@@ -258,16 +260,16 @@
#define COMPARE_2CHARS(address, char1, char2) \\
- ((reinterpret_cast<const uint16_t*>(address))[0] == CHARPAIR_TOUINT16(char1, char2))
+ ((reinterpret_cast_ptr<const uint16_t*>(address))[0] == CHARPAIR_TOUINT16(char1, char2))
#define COMPARE_2UCHARS(address, char1, char2) \\
- ((reinterpret_cast<const uint32_t*>(address))[0] == UCHARPAIR_TOUINT32(char1, char2))
+ ((reinterpret_cast_ptr<const uint32_t*>(address))[0] == UCHARPAIR_TOUINT32(char1, char2))
#if CPU(X86_64)
#define COMPARE_4CHARS(address, char1, char2, char3, char4) \\
- ((reinterpret_cast<const uint32_t*>(address))[0] == CHARQUAD_TOUINT32(char1, char2, char3, char4))
+ ((reinterpret_cast_ptr<const uint32_t*>(address))[0] == CHARQUAD_TOUINT32(char1, char2, char3, char4))
#define COMPARE_4UCHARS(address, char1, char2, char3, char4) \\
- ((reinterpret_cast<const uint64_t*>(address))[0] == UCHARQUAD_TOUINT64(char1, char2, char3, char4))
+ ((reinterpret_cast_ptr<const uint64_t*>(address))[0] == UCHARQUAD_TOUINT64(char1, char2, char3, char4))
#else // CPU(X86_64)
Modified: trunk/Source/_javascript_Core/runtime/PropertyMapHashTable.h (280686 => 280687)
--- trunk/Source/_javascript_Core/runtime/PropertyMapHashTable.h 2021-08-05 15:02:38 UTC (rev 280686)
+++ trunk/Source/_javascript_Core/runtime/PropertyMapHashTable.h 2021-08-05 15:14:42 UTC (rev 280687)
@@ -26,6 +26,7 @@
#include "WriteBarrier.h"
#include <wtf/HashTable.h>
#include <wtf/MathExtras.h>
+#include <wtf/StdLibExtras.h>
#include <wtf/Vector.h>
#include <wtf/text/AtomStringImpl.h>
@@ -548,13 +549,13 @@
inline PropertyTable::ValueType* PropertyTable::table()
{
// The table of values lies after the hash index.
- return reinterpret_cast<ValueType*>(m_index + m_indexSize);
+ return reinterpret_cast_ptr<ValueType*>(m_index + m_indexSize);
}
inline const PropertyTable::ValueType* PropertyTable::table() const
{
// The table of values lies after the hash index.
- return reinterpret_cast<const ValueType*>(m_index + m_indexSize);
+ return reinterpret_cast_ptr<const ValueType*>(m_index + m_indexSize);
}
inline unsigned PropertyTable::usedCount() const