Changeset 64101 in webkit for trunk/JavaScriptCore/jit/ExecutableAllocator.cpp
- Timestamp:
- Jul 26, 2010, 7:53:06 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/jit/ExecutableAllocator.cpp
r64098 r64101 34 34 size_t ExecutableAllocator::pageSize = 0; 35 35 36 #if ENABLE(EXECUTABLE_ALLOCATOR_DEMAND)37 38 void ExecutableAllocator::intializePageSize()39 {40 #if CPU(ARMV5_OR_LOWER)41 // The moving memory model (as used in ARMv5 and earlier platforms)42 // on Symbian OS limits the number of chunks for each process to 16.43 // To mitigate this limitation increase the pagesize to allocate44 // fewer, larger chunks. Set the page size to 256 Kb to compensate45 // for moving memory model limitation46 ExecutableAllocator::pageSize = 256 * 1024;47 #else48 ExecutableAllocator::pageSize = PageAllocation::pagesize();49 #endif50 }51 52 ExecutablePool::Allocation ExecutablePool::systemAlloc(size_t size)53 {54 PageAllocation allocation = PageAllocation::allocate(size, PageAllocation::JSJITCodePages, EXECUTABLE_POOL_WRITABLE, true);55 if (!allocation)56 CRASH();57 return allocation;58 }59 60 void ExecutablePool::systemRelease(const ExecutablePool::Allocation& allocation)61 {62 allocation.deallocate();63 }64 65 bool ExecutableAllocator::isValid() const66 {67 return true;68 }69 70 #endif71 72 36 #if ENABLE(ASSEMBLER_WX_EXCLUSIVE) 73 74 #if OS(WINDOWS) || OS(SYMBIAN)75 #error "ASSEMBLER_WX_EXCLUSIVE not yet suported on this platform."76 #endif77 78 37 void ExecutableAllocator::reprotectRegion(void* start, size_t size, ProtectionSeting setting) 79 38 { … … 94 53 mprotect(pageStart, size, (setting == Writable) ? PROTECTION_FLAGS_RW : PROTECTION_FLAGS_RX); 95 54 } 96 97 55 #endif 98 56 99 57 #if CPU(ARM_TRADITIONAL) && OS(LINUX) && COMPILER(RVCT) 100 101 58 __asm void ExecutableAllocator::cacheFlush(void* code, size_t size) 102 59 { … … 111 68 bx lr 112 69 } 113 114 70 #endif 115 71
Note:
See TracChangeset
for help on using the changeset viewer.