if (VM.VerifyAssertions) VM.assert(false);
if (VM.VerifyAssertions) VM._assert(false);
  public void attach(int size) throws VM_PragmaUninterruptible {    if (VM.VerifyAssertions) VM.assert(bootRecord != null);    if (size < 0)       VM.sysFail("VM_Heap.attach given negative size\n");    if (this.size != 0)      VM.sysFail("VM_Heap.attach called on already attached heap\n");    size = VM_Memory.roundUpPage(size);    // Let OS place region for now    start = VM_Memory.mmap(VM_Address.fromInt(0), 			   size, 			   VM_Memory.PROT_READ | VM_Memory.PROT_WRITE | VM_Memory.PROT_EXEC,			   VM_Memory.MAP_PRIVATE | VM_Memory.MAP_ANONYMOUS);    if (start.GE(VM_Address.fromInt(0)) && 	start.LT(VM_Address.fromInt(128))) {  // errno range      VM.sysWrite("VM_Heap failed to mmap ", size / 1024);      VM.sysWrite(" Kbytes with errno = "); VM.sysWrite(start); VM.sysWriteln();      if (VM.VerifyAssertions) VM.assert(false);    }    end = start.add(size);    if (verbose >= 1) {      VM.sysWrite("VM_Heap sucessfully mmap ", size / 1024);      VM.sysWrite(" Kbytes from ");      VM.sysWrite(start); VM.sysWrite(" to " ); VM.sysWrite(end); VM.sysWrite("\n");    }    setAuxiliary();  }  public void grow(int sz) throws VM_PragmaUninterruptible {    if (sz < size)      VM.sysFail("VM_Heap.grow given smaller size than current size\n");    sz = VM_Memory.roundUpPage(sz);    VM_Address result = VM_Memory.mmap(end, sz - size,				       VM_Memory.PROT_READ | VM_Memory.PROT_WRITE | VM_Memory.PROT_EXEC,				       VM_Memory.MAP_PRIVATE | VM_Memory.MAP_ANONYMOUS | VM_Memory.MAP_FIXED);    int status = result.toInt();    if (status >= 0 && status < 128) {      VM.sysWrite("VM_Heap.grow failed to mmap additional ", (sz - size) / 1024);      VM.sysWrite(" Kbytes at ");      VM.sysWrite(end);      VM.sysWriteln(" with errno = ", status);      if (VM.VerifyAssertions) VM.assert(false);    }    if (verbose >= 1) {      VM.sysWrite("VM_Heap.grow successfully mmap additional ", (sz - size) / 1024);      VM.sysWrite(" Kbytes at ");  VM.sysWrite(end); VM.sysWrite("\n");    }    // start not modified    end = start.add(sz);    setAuxiliary();  }  public void detach() throws VM_PragmaUninterruptible {    if (this.size == 0)      VM.sysFail("VM_Heap.detach called on unattached heap\n");    int status = VM_Memory.munmap(start, size);    if (status != 0) {      VM.sysWriteln("VM_Heap.detach failed with errno = ", status);      VM.sysFail("VM_Heap.detach failed\n");    }    if (verbose >= 1) {      VM.sysWrite("VM_Heap successfully detached ", size / 1024);       VM.sysWrite(" Kbytes starting at ");      VM.sysWrite(start); VM.sysWriteln();    }    start = end = VM_Address.fromInt(0);    setAuxiliary();  }