-
In
~/.ssh/config, include the lines:Host * ControlPath ~/.ssh/sockets/%r@%h-%p
| /* $begin mmheader */ | |
| /* $begin mallocinterface */ | |
| extern int mm_init(void); | |
| extern void *mm_malloc (size_t size); | |
| extern void mm_free (void *ptr); | |
| /* $end mallocinterface */ | |
| extern void *mm_realloc(void *ptr, size_t size); | |
| extern void *mm_calloc (size_t nmemb, size_t size); | |
| extern void mm_checkheap(int verbose); |
| /* | |
| * Simple, 32-bit and 64-bit clean allocator based on implicit free | |
| * lists, first-fit placement, and boundary tag coalescing, as described | |
| * in the CS:APP3e text. Blocks must be aligned to doubleword (8 byte) | |
| * boundaries. Minimum block size is 16 bytes. | |
| */ | |
| #include <stdio.h> | |
| #include <string.h> | |
| #include <stdlib.h> |
| /* $begin memlibheader */ | |
| #include <unistd.h> | |
| void mem_init(void); | |
| void *mem_sbrk(int incr); | |
| void mem_deinit(void); | |
| void mem_reset_brk(void); | |
| void *mem_heap_lo(void); | |
| void *mem_heap_hi(void); |
| /* | |
| * memlib.c - a module that simulates the memory system. Needed | |
| * because it allows us to interleave calls from the student's malloc | |
| * package with the system's malloc package in libc. | |
| * | |
| */ | |
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #include <assert.h> | |
| #include <unistd.h> |
| package main | |
| type items []int | |
| var nilItems = make(items, 16) | |
| func (s *items) truncate1(i int) { | |
| *s = (*s)[:i] | |
| } |
| " Specify a directory for plugins | |
| " - For Neovim: stdpath('data') . '/plugged' | |
| " - Avoid using standard Vim directory names like 'plugin' | |
| call plug#begin('~/.vim/plugged') | |
| Plug 'rhysd/vim-clang-format' | |
| " On-demand loading | |
| Plug 'scrooloose/nerdtree', { 'on': 'NERDTreeToggle' } |
| //===----------------------------------------------------------------------===// | |
| // | |
| // BusTub | |
| // | |
| // buffer_pool_manager.cpp | |
| // | |
| // Identification: src/buffer/buffer_pool_manager.cpp | |
| // | |
| // Copyright (c) 2015-2019, Carnegie Mellon University Database Group | |
| // |
| struct LRUKV { | |
| int key_; | |
| int value_; | |
| LRUKV(int key, int value) :key_(key), value_(value) {} | |
| }; | |
| class LRUCache { | |
| public: | |
| LRUCache(int capacity) | |
| :cache_size_(capacity), |
| #include <vector> | |
| struct LRUKV { | |
| int key_; | |
| int value_; | |
| LRUKV(int key, int value) :key_(key), value_(value) {} | |
| }; | |
| class LRUCache { | |
| public: |