Changeset 265113 in webkit


Ignore:
Timestamp:
Jul 30, 2020 3:26:01 PM (4 years ago)
Author:
keith_miller@apple.com
Message:

Compute number of PAC bits from what the OS says its address space is
https://bugs.webkit.org/show_bug.cgi?id=214986

Reviewed by Saam Barati.

Source/JavaScriptCore:

  • assembler/MacroAssemblerARM64E.h:

Source/WTF:

  • wtf/CagedPtr.h:
  • wtf/PtrTag.h:
Location:
trunk/Source
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/ChangeLog

    r265112 r265113  
     12020-07-30  Keith Miller  <keith_miller@apple.com>
     2
     3        Compute number of PAC bits from what the OS says its address space is
     4        https://bugs.webkit.org/show_bug.cgi?id=214986
     5
     6        Reviewed by Saam Barati.
     7
     8        * assembler/MacroAssemblerARM64E.h:
     9
    1102020-07-30  Caio Lima  <ticaiolima@gmail.com>
    211
  • trunk/Source/JavaScriptCore/assembler/MacroAssemblerARM64E.h

    r250654 r265113  
    4040class MacroAssemblerARM64E : public MacroAssemblerARM64 {
    4141public:
    42     static constexpr unsigned numberOfPACBits = 25;
     42    static constexpr unsigned numberOfPACBits = WTF::maximumNumberOfPointerAuthenticationBits;
    4343    static constexpr uintptr_t nonPACBitsMask = (1ull << (64 - numberOfPACBits)) - 1;
    4444
  • trunk/Source/WTF/ChangeLog

    r265057 r265113  
     12020-07-30  Keith Miller  <keith_miller@apple.com>
     2
     3        Compute number of PAC bits from what the OS says its address space is
     4        https://bugs.webkit.org/show_bug.cgi?id=214986
     5
     6        Reviewed by Saam Barati.
     7
     8        * wtf/CagedPtr.h:
     9        * wtf/PtrTag.h:
     10
    1112020-07-29  Fujii Hironori  <Hironori.Fujii@sony.com>
    212
  • trunk/Source/WTF/wtf/CagedPtr.h

    r260289 r265113  
    4040public:
    4141    static constexpr Gigacage::Kind kind = passedKind;
    42     static constexpr unsigned numberOfPACBits = 25;
     42    static constexpr unsigned numberOfPACBits = maximumNumberOfPointerAuthenticationBits;
    4343    static constexpr uintptr_t nonPACBitsMask = (1ull << ((sizeof(T*) * CHAR_BIT) - numberOfPACBits)) - 1;
    4444
  • trunk/Source/WTF/wtf/PtrTag.h

    r261877 r265113  
    2828#include <wtf/Assertions.h>
    2929#include <wtf/DataLog.h>
     30#include <wtf/MathExtras.h>
    3031
    3132namespace WTF {
     33
     34#if CPU(ARM64E)
     35constexpr unsigned maximumNumberOfPointerAuthenticationBits = 64 - OS_CONSTANT(EFFECTIVE_ADDRESS_WIDTH);
     36#else // CPU(ARM64E)
     37constexpr unsigned maximumNumberOfPointerAuthenticationBits = 0;
     38#endif // CPU(ARM64E)
     39
    3240
    3341#define FOR_EACH_BASE_WTF_PTRTAG(v) \
Note: See TracChangeset for help on using the changeset viewer.