Commit 51f730c2 authored by Raymond Toy's avatar Raymond Toy

Remove PAGE_WRITE_PROTECT_CLEARED and MASK.

This macro and mask is only used once to set the bit (near line 498).
It's not read anywhere, so remove it.

Addresses #89.
parent d1b59ff3
......@@ -495,7 +495,6 @@ gc_write_barrier(void *addr)
/* Un-protect the page */
os_protect((os_vm_address_t) page_address(page_index), GC_PAGE_SIZE, OS_VM_PROT_ALL);
page_table[page_index].flags &= ~PAGE_WRITE_PROTECTED_MASK;
page_table[page_index].flags |= PAGE_WRITE_PROTECT_CLEARED_MASK;
return 1;
}
......
......@@ -45,16 +45,6 @@ int gc_write_barrier(void *);
#define PAGE_WRITE_PROTECTED(page) \
(page_table[page].flags & PAGE_WRITE_PROTECTED_MASK)
/*
* This flag is set when the above write protect flag is clear by the
* sigbus handler. This is useful for re-scavenging pages that are
* written during a GC.
*/
#define PAGE_WRITE_PROTECT_CLEARED_MASK 0x00000020
#define PAGE_WRITE_PROTECT_CLEARED(page) \
(page_table[page].flags & PAGE_WRITE_PROTECT_CLEARED_MASK)
/*
* Page allocated flag: 0 for a free page; 1 when allocated. If
* the page is free then the following slots are invalid - well
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment