Home
I am Rong “Mantle” Bao. Welcome to my blog, where I bake all my potatoes.
Read my recent posts or browse by tag, and meet some of my friends.
Some deployed web apps:
- Periotris.js (repository): Variant of Tetris based on the periodic table of elements.
- LA32R Instruction Statistics (repository): Count instructions in LoongArch32 Reduced binaries.
- Y Chip Area Visualizer (repository): Visualize Yosys
stat
reports.
Recent 15 posts
-
Finite state machine pitfalls with Chisel: Revisited
A while ago, I wrote about how Chisel’s early optimization breaks common heuristics used by other tools to detect finite state machine patterns. Here is its workaround. Instead of following Chisel’s “advised way”, you need to wrap every next stat...
-
You can’t eliminate useless stack allocations in Rust
The shiny “language of the year” lacks such an important and widely-used feature.
-
HGAME 2025 命题小记 - WEEK2
阅读赛题源码和研究writeup同样重要。(第二部分)
-
HGAME 2025 命题小记 - WEEK1
阅读赛题源码和研究writeup同样重要。(第一部分)
-
A parser for LoongArch instruction encoding table
Turn an AsciiDoc table of LoongArch instruction encodings into a machine-readable format.
-
Much ado about nothing
There’s quite a lot to say about doing nothing.
-
Achilles’s heel of Nushell
Gradual typing is not an excuse for inexpressibility.
-
翻译:《我的电动牙刷坏了,所以我试着重启它》
原标题:My electric toothbrush was acting up, so I tried to reboot it 作者:Raymond Chen 地址:https://devblogs.microsoft.com/oldnewthing/20250128-00/?p=110815 我的电动牙刷坏了。互联网告诉我,我需要重启的我的电动牙刷。 放在40年前,上面最后一句话绝对没有人听得懂。 我的一个参与了USB标准研发的朋友有次给我发邮件,说:“...
-
翻译:《我尝试给闹钟调时间。我失败了。》
原标题:I tried to adjust the time on my alarm clock. I failed. 作者:Raymond Chen 地址:https://devblogs.microsoft.com/oldnewthing/20191104-01/?p=103052 不知为何,我的闹钟非得让我在手机上安装一个应用,结果这个应用还要求我创建账号。 我再强调一遍:为了定闹钟,我居然要在闹钟厂商那里注册账号。 总之,当初我买来这个闹钟时就走过一遍...
-
翻译:《留意文档中的时间用语:参照时刻为何?》
原标题:Be mindful of temporal terms in documents: What is the reference point in time? 作者:Raymond Chen 地址:https://devblogs.microsoft.com/oldnewthing/20250122-00/?p=110797 在诸如功能提案或pull request的文档中,需要特别注意指代时刻的词语,因为语境中隐含的参照时刻并不总是清晰的。 例如,在p...
-
Finite state machine pitfalls with Chisel, SystemVerilog and Vivado
TL;DR: Vivado 2024.1 fails to infer FSMs from Chisel-generated SystemVerilog files due to Chisel’s optimizations; no solutions except manual patching are known by the author as of writing. 1. Background 2. Experiments and results ...
-
Flare-On 11 Writeup - csmantle
Flare-On capture-the-flag event organized by MANDIANT is an annual reverse engineering event featuring creative challenges, a dazzling show-off of various techniques and a broad range of real-world scenarios. The author, as finisher #179 of Flare-On 11, presents the challenges’s writeup in this post.
-
截断Base64编码的不动点: 借助Z3的分析与证明
An English version is available here. 1. 导语 Base64 (Wikipedia, RFC 4648) 是相当常见的编码格式, 可以将任意二进制数据至一个 ASCII 码子集, 其原理为将原始数据中的位视为 $2^6 = 64$ 元字母表中的元素下标. 显然, 由于输入为6位元素而输出为8位元素 (ASCII 字符), 数据在编码后会比原来更长. 若只考虑相同长度的部分 (前缀), 我们能够构造一个 $N$ 元串 $S$ 使得它的 Ba...
-
Fixed point in truncated Base64 encoding: analysis and proof with Z3
中文版本见此. 1. Introduction Base64 (Wikipedia, RFC 4648) is a well-known encoding for turing arbitrary binary data into an alphanumeric ASCII string. It’s basic idea is to reinterpret original data as characters in a $2^6 = 64$-membered alphabet...
-
在 BIRD2 中使用 BFD 协议
本文为 DN11 项目编写. 1. 前言 双向转发检测 (Bidirectional Forward Detection, BFD) 通过在一条链路的两端建立会话 (session) 以检测链路连通性. 链路的两端协商 Hello 包的发包间隔, 在一定数量的包丢失后, 链路即被判断发生故障. 由于 BFD 本身不支持对端发现, 因此在某一条链路上建立 BFD 需要链路的两端均正确配置协议. BFD 协议本身仅负责进行链路连通性检测, 其得到的结果如何处理由使用者决定. 多种...
- ... See all posts organized by tag.
Subscribe via RSS