Title: [287215] trunk/Source/bmalloc
Revision
287215
Author
[email protected]
Date
2021-12-17 18:09:45 -0800 (Fri, 17 Dec 2021)

Log Message

Unreviewed, CMakeLists is missing pas_probabilistic_guard_malloc_allocator.[ch]
https://bugs.webkit.org/show_bug.cgi?id=234415

* CMakeLists.txt:
* libpas/src/libpas/pas_probabilistic_guard_malloc_allocator.c:

Modified Paths

Diff

Modified: trunk/Source/bmalloc/CMakeLists.txt (287214 => 287215)


--- trunk/Source/bmalloc/CMakeLists.txt	2021-12-18 01:13:59 UTC (rev 287214)
+++ trunk/Source/bmalloc/CMakeLists.txt	2021-12-18 02:09:45 UTC (rev 287215)
@@ -142,6 +142,7 @@
     libpas/src/libpas/pas_payload_reservation_page_list.c
     libpas/src/libpas/pas_physical_memory_transaction.c
     libpas/src/libpas/pas_primitive_heap_ref.c
+    libpas/src/libpas/pas_probabilistic_guard_malloc_allocator.c
     libpas/src/libpas/pas_ptr_worklist.c
     libpas/src/libpas/pas_race_test_hooks.c
     libpas/src/libpas/pas_random.c
@@ -537,6 +538,7 @@
     libpas/src/libpas/pas_physical_memory_transaction.h
     libpas/src/libpas/pas_platform.h
     libpas/src/libpas/pas_primitive_heap_ref.h
+    libpas/src/libpas/pas_probabilistic_guard_malloc_allocator.h
     libpas/src/libpas/pas_promote_intrinsic_heap.h
     libpas/src/libpas/pas_ptr_hash_map.h
     libpas/src/libpas/pas_ptr_hash_set.h

Modified: trunk/Source/bmalloc/ChangeLog (287214 => 287215)


--- trunk/Source/bmalloc/ChangeLog	2021-12-18 01:13:59 UTC (rev 287214)
+++ trunk/Source/bmalloc/ChangeLog	2021-12-18 02:09:45 UTC (rev 287215)
@@ -1,5 +1,13 @@
 2021-12-17  Yusuke Suzuki  <[email protected]>
 
+        Unreviewed, CMakeLists is missing pas_probabilistic_guard_malloc_allocator.[ch]
+        https://bugs.webkit.org/show_bug.cgi?id=234415
+
+        * CMakeLists.txt:
+        * libpas/src/libpas/pas_probabilistic_guard_malloc_allocator.c:
+
+2021-12-17  Yusuke Suzuki  <[email protected]>
+
         [libpas] Use inline-assembly ARM64 code in GCC too
         https://bugs.webkit.org/show_bug.cgi?id=234450
 

Modified: trunk/Source/bmalloc/libpas/src/libpas/pas_probabilistic_guard_malloc_allocator.c (287214 => 287215)


--- trunk/Source/bmalloc/libpas/src/libpas/pas_probabilistic_guard_malloc_allocator.c	2021-12-18 01:13:59 UTC (rev 287214)
+++ trunk/Source/bmalloc/libpas/src/libpas/pas_probabilistic_guard_malloc_allocator.c	2021-12-18 02:09:45 UTC (rev 287215)
@@ -57,7 +57,7 @@
 #include "pas_large_utility_free_heap.h"
 
 // debug toggle
-bool pgm_verbose = false;
+static const bool pgm_verbose = false;
 
 // max amount of free memory that can be wasted (1MB)
 #define MAX_WASTED_MEMORY (1024 * 1024)
@@ -66,10 +66,10 @@
 // including guard pages and wasted memory
 #define MAX_VIRTUAL_MEMORY (1024 * 1024 * 1024)
 
-bool pgm_enabled = true;
+static bool pgm_enabled = true;
 
-size_t free_wasted_mem  = MAX_WASTED_MEMORY;
-size_t free_virtual_mem = MAX_VIRTUAL_MEMORY;
+static size_t free_wasted_mem  = MAX_WASTED_MEMORY;
+static size_t free_virtual_mem = MAX_VIRTUAL_MEMORY;
 
 // structure for holding metadata of pgm allocations
 typedef struct pgm_storage pgm_storage;
@@ -88,9 +88,10 @@
 // value : metadata for tracking that allocation (pgm_storage)
 pas_ptr_hash_map pgm_hash_map = PAS_HASHTABLE_INITIALIZER;
 
-
+#if PAS_COMPILER(CLANG)
 #pragma mark -
 #pragma mark ALLOC/DEALLOC
+#endif
 
 void* pas_probabilistic_guard_malloc_allocate(size_t size, pas_heap* heap, pas_heap_config* heap_config,
                                               pas_physical_memory_transaction* transaction) {
@@ -266,8 +267,10 @@
 }
 
 
+#if PAS_COMPILER(CLANG)
 #pragma mark -
 #pragma mark Determine whether to use PGM
+#endif
 
 void pas_probabilistic_guard_malloc_trigger(void) {
     // ???
@@ -294,8 +297,10 @@
     return true;
 }
 
+#if PAS_COMPILER(CLANG)
 #pragma mark -
 #pragma mark Helper Functions
+#endif
 
 size_t pas_probabilistic_guard_malloc_get_free_virtual_memory() {
     pas_heap_lock_assert_held();
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to