Skip to content

Instantly share code, notes, and snippets.

View 1a1a11a's full-sized avatar

Juncheng Yang 1a1a11a

View GitHub Profile
@1a1a11a
1a1a11a / cloudlab
Last active April 22, 2025 02:59
cloudlab API
#!/bin/bash
# https://gitlab.flux.utah.edu/stoller/portal-tools
# git clone https://gitlab.flux.utah.edu/stoller/portal-tools
# cd portal-tools; python3 setup.py install
# sudo cp cl.sh /usr/local/bin/cl && sudo chmod +x /usr/local/bin/cl
# set -eux
PROJ=cache
USER=juncheng
@1a1a11a
1a1a11a / tmux.conf
Last active September 25, 2024 00:00
# change control key to ctrl + a
unbind C-b
set -g prefix C-a
# set screen history
set -g history-limit 40000
# use r to reload config
bind r source-file ~/.tmux.conf \; display-message "Config reloaded.."
diff --git a/src/storage/seg/segevict.c b/src/storage/seg/segevict.c
index da940e3..66c4988 100644
--- a/src/storage/seg/segevict.c
+++ b/src/storage/seg/segevict.c
@@ -278,7 +278,8 @@ segevict_setup(evict_policy_e ev_policy, uintmax_t seg_mature_time)
struct merge_opts *mopt = &evict_info.merge_opt;
mopt->target_ratio = 1.0 / mopt->seg_n_merge;
/* stop if the bytes on the merged seg is more than the threshold */
- mopt->stop_ratio = mopt->target_ratio * (mopt->seg_n_merge - 1) + 0.05;
+ // mopt->stop_ratio = mopt->target_ratio * (mopt->seg_n_merge - 1) + 0.05;
@1a1a11a
1a1a11a / goBenchmark
Last active March 10, 2019 00:27
some benchmark related to golang
package main
import (
"fmt"
"time"
"sync"
)
func main() {