LeetCode – Clone Graph

Given a reference of a node in a connected Connected_graph undirected graph, return a deep copy

2019-08-09 · 2 min · 916 words · Garlic Space

linux-sides-Timers and time management-Introduction

这篇文章 Timers and time management in the Linux kernel. Part 1. 是出自 linux-insides

2019-08-07 · 15 min · 7274 words · Garlic Space

sysctl-查询修改Linux内核参数

sysctl命令可以_实时_(runtime)查看和修改linux 内核参数。这个命令可以在大多数发行版本找到, 另外内核参数,也可以通过procfs 文件系统,在 /proc/sys/kernel下 进行查看和修改。

2019-08-06 · 2 min · 753 words · Garlic Space

asm-offset.h生成过程

asm-offset.h 文件 asm-offset.h 文件是在内核编译过程中生成的,生成过程 之前整理了一份笔记 TASK_threadsp的实现及asm-offsets.h, 其中涉及sed处理包含在内核代码 /scripts/Makefile.lib的sed-offsets中,工作是将生成的asm-offset.s转化为asm-offset.h。 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 /scripts/Makefile.lib ... # ASM offsets # --------------------------------------------------------------------------- # Default sed regexp - multiline due to syntax constraints # # Use [:space:] because LLVM's integrated assembler inserts <tab> around # the .ascii directive whereas GCC keeps the <space> as-is. define sed-offsets 's:^[[:space:]]*\.ascii[[:space:]]*"\(.*\)".*:\1:; \ /^->/{s:->#\(.*\):/* \1 */:; \ s:^->\([^ ]*\) [\$$#]*\([^ ]*\) \(.*\):#define \1 \2 /* \3 */:; \ s:->::; p;}' endef ...

2019-08-05 · 5 min · 2278 words · Garlic Space

LeetCode – Evaluate Reverse Polish Notation

题目: Evaluate the value of an arithmetic expression in Reverse Polish Notation. Valid operators are +, -, *, /. Each operand may be an integer or another expression. Note: Division between two integers should truncate toward zero. The given RPN expression is always valid. That means the expression would always evaluate to a result and there won’t be any divide by zero operation. Example 1: Input: 1 ["2", "1", "+", "3", "*"] Output: ...

2019-08-04 · 2 min · 652 words · Garlic Space

Linux如何管理和度量时间

Linux 内核的Timer必须要完成两种定时测量(timing measurement)

2019-08-03 · 5 min · 2234 words · Garlic Space

kill多个同名进程

问题: 本周在配合系统测试过程中,发现系统报文接收异常, 排查过程中发现应用进程启动异常。 当时状态模拟如下: 1 2 3 4 5 6 7 8 9 10 11 12 13 [root@centosgpt server]# ps -ef|grep daemon dbus 934 1 0 Jul22 ? 00:01:15 /usr/bin/dbus-daemon --system --address=systemd: --nofork --nopidfile --systemd-activation root 941 1 0 Jul22 ? 00:00:15 /usr/sbin/NetworkManager --no-daemon root 81345 1 0 09:27 ? 00:00:00 daemon root 81348 1 0 09:27 ? 00:00:00 daemon root 81351 1 0 09:27 ? 00:00:00 daemon root 81354 1 0 09:27 ? 00:00:00 daemon root 81357 1 0 09:28 ? 00:00:00 daemon root 81360 1 0 09:28 ? 00:00:00 daemon status root 81364 1 0 09:28 ? 00:00:00 daemon start root 81367 1 0 09:28 ? 00:00:00 daemon status root 81370 1 0 09:28 ? 00:00:00 daemon root 81372 80347 0 09:28 pts/2 00:00:00 grep --color=auto daemon daemon status, daemon start 都属于异常进程。 ...

2019-07-26 · 2 min · 901 words · Garlic Space

Airbnb Blog- 分布式支付系统中交易完整性的测量

这篇文章 Measuring Transactional Integrity in Airbnb’s Distributed Payment Ecosystem

2019-07-25 · 3 min · 1132 words · Garlic Space

LeetCode – Daily Temperatures

Daily Temperatures

2019-07-23 · 1 min · 284 words · Garlic Space

Netflix Blog- 重构视频GateKeeper

 这篇文章Re-Architecting the Video Gatekeeper 是出自 Netflix Technology Blog。 Netflix上的视频需要通过Title Operations 团队的策划,使其遵守的合同;字幕、配音、翻译能够提供给合适的人群;标题名称和概要可供使用和翻译;满足各个国家的成熟度等级(分级)。 ...

2019-07-22 · 3 min · 1054 words · Garlic Space