Skip to content

Instantly share code, notes, and snippets.

View GitBubble's full-sized avatar

Arthur GitBubble

View GitHub Profile
/**************************************************
* Fair scheduling class load-balancing methods.
*
* BASICS
*
* The purpose of load-balancing is to achieve the same basic fairness the
* per-CPU scheduler provides, namely provide a proportional amount of compute
* time to each task. This is expressed in the following equation:
*
* W_i,n/P_i == W_j,n/P_j for all i,j (1)
@GitBubble
GitBubble / readme.md
Created January 8, 2019 13:07 — forked from benstr/readme.md
Gist Markdown Cheatsheet

#Heading 1 ##Heading 2 ###Heading 3 ####Heading 4 #####Heading 5 ######Heading 6


Paragraph

@GitBubble
GitBubble / gist:d03cc67821281a5397a985d47926eca7
Last active January 8, 2019 13:06
Markdown cheat sheet

Header 1

Header 2

Header 3 ### (Hashes on right are optional)

Header 4

Header 5

Markdown plus h2 with a custom ID ## {#id-goes-here}

Link back to H2

This is a paragraph, which is text surrounded by whitespace. Paragraphs can be on one

@GitBubble
GitBubble / Using FMEA to Improve Software Reliability.md
Last active August 10, 2023 13:08
使用FMEA提高软件可靠性.md

失效模式和影响分析(FMEA)是硬件设计普遍采用的一种分析方法,用来避免设计遗漏(field failure)。使用FMEA为软件系统建模来提高可靠性的工程人员逐年增加。

在诸多的方法、工具和实践中,FMEA毫无争议是开销最小,容易上手并最为有效的。(我们需要学习的原因)

FMEA的核心元素有两块:FBD(Function Block Diagram,功能块图 ) 以及 FMEA工作表

FMEA工作表是整个分析流程的最后交付件,所有分析按照推荐动作优先级在此汇总。

FMEA分析的目的是为了找到潜在的失效点。当FMEA识别到单点失效模式,我们必须有一个可靠的解决方案来应对潜在失效点。

@GitBubble
GitBubble / question_to_work.md
Last active May 2, 2019 16:30
问自己的问题。

我想做什么?要解决什么问题?

为什么需要Real Time?

探月火星车,火箭和工业制造以及自动驾驶技术。他们都是和安全(safty)相关,要求在设计的时间内完成某项计算/传输任务。 这三类系统,是要求硬实时的。

硬实时: 在严格设定的时间内完成任务。超过该时间认为是系统错误。 (人命关天)
软实时: 在设定的时间内完成任务。超过该时间认为,系统服务质量出现问题。 (音视频的传输)
确定实时: 在设定的时间完成任务。超过时间认为结果是非法和不可信的。 (工业制造)

@GitBubble
GitBubble / boost-backporting-guide.md
Created November 17, 2018 12:01 — forked from springmeyer/boost-backporting-guide.md
How to backport recent Boost packages to older ubuntu distro's and build using personal PPA

Boost backporting

Goal here is to document the steps I took in May 2012 to get Boost 1.49 packages backported and working on Lucid, Maverick, Natty, Oneiric, and Precise.

TODO: look into using ubuntu-dev-tools and backportpackage -s [new_release] -d [old_release] -u [ppa] [package_name]

Install dev tools

sudo apt-get install debhelper devscripts dput git-core python pgpgpg
@GitBubble
GitBubble / python.md
Last active July 11, 2018 13:40
python
import logging

logging.basicConfig(level=logging.INFO,format='%(asctime)s - %(name)s- %(levelname)s - %(message)s')
logger = logging.getLogger(__name__)
print(__name__)
__main__
print logger
logger.info('this is log info')
2018-07-11 21:34:07,966 - __main__- INFO - this is log info

有了这个列表,程序员不愁没练手的小项目了

初衷

这个列表原本首发在伯乐在线的一篇译文:http://blog.jobbole.com/49762/。2016年9月21日,该文章推送到微信公众号 程序员的那些事 (ID: iProgrammer ) 后,@BleethNie 留言建议把这 120+ 练手小项目统一放在一个地方,同时其他人可以把自己完成项目提交合并到一起,相互参考学习。于是我们在 GitHub 创建了这个项目。后续会以超链的形式合并大家提交的成果到这个列表。欢迎 fork & star,并扩散给更多人。

下面列出 120 多个项目构思,根据主题分成了 10 个分类。

文本操作

@GitBubble
GitBubble / gdb_learn.md
Last active November 20, 2018 09:20
gdb_learn.md

set coredump file

echo '/tmp/core.%e.%p.%t' | sudo tee /proc/sys/kernel/core_pattern

special

(gdb) info sharedlibrary

gdb -ex "layout asm" ./foo gdb -q ./foo -ex "b main" -ex "r"

set history save

tmux cheatsheet

As configured in my dotfiles.

start new:

tmux

start new with session name: