Home
I am Rong “Mantle” Bao, a third-year Computer Science undergraduate at Hangzhou Dianzi University. Welcome to my blog, where I bake all my potatoes.
About me
- He/him
- GitHub: https://github.com/CSharperMantle
- Personal email: rong.bao@csmantle.top
- Natural languages:
zh-cmn-Hans-CN(native)zh-wuu-Hans-CN(native)en(near native)
- Developing personal projects
Skills
- Polyglot, enjoy C/Rust/TypeScript most
- Reverse engineering, messing around with OS and ISA. Member of Vidar-Team
- Bare-metal, desktop native, single-page WebApps development
- Interested in x86-64 assembly, RISC-V/LoongArch ISAs and microarch implementation
- Mozilla Level 1 Commit Access, active maintainer of SpiderMonkey’s RV64 JIT backend
My attitudes towards AI
- Machine learning problems are analytical and statistical problems.
- Neural networks are good at discovering patterns not obvious to traditional approaches.
- LLMs are probabilistic token predictors. They often intrinsically hallucinate.
- Garbage in, garbage out. Observation in, imitation out.
- I do use LLMs to brainstorm ideas.
- I do use LLMs to perform repetitive clerical work and typographical proofreading.
- I do chat with LLMs to have fun in my spare time.
- I do use generative models to craft images for hobby use.
- I do not use LLMs to write code for production use.
- I do not use LLMs to write casual articles, like blogs.
- I do not use LLMs to write academic articles or carry out research in place of myself.
- I do not use LLMs as a search engine.
- I do not trust LLMs as a sole source of information.
- I do not accept responses from LLMs without verification.
- I believe the loopholes and waivers in LLM hosting companies' EULA put much personal information at risk.
- I believe LLMs are energy hogs that should be used with conservation in mind.
- I believe LLMs are becoming more performant as theories and technologies evolve.
R10 Posts
-
A POSIX-compliant rewrite of reresolve-dns.sh
The script Please be careful with line endings if you’re copy-pasting the script from below. If you’re interested in the story behind it, please scroll down to #background-story. #!/bin/sh # <link> GPL-2.0 # # POSIX sh-compliant rewrite of reresolve-dns.sh. # # Notes for BusyBox-based coreutils: # * A POSIX-compliant tr(1) is expected for [:upper:] and [:lower:]. # # Copyright (C) 2015-2020 Jason A. Donenfeld <Jason@zx2c4.com>. All Rights Reserved. # Copyright (C) 2025 Rong Bao <webmaster@csmantle.top>. # # Link: <link> # Link: <link> set -e export LC_ALL=C trim() { echo “$1” | sed ‘s/^[[:space:]]*//;s/[[:space:]]*$//’ } lower() { echo “$1” | tr...
-
求解 DES 弱密钥
DES加密算法存在四个弱密钥,分别为 : 0x0101010101010101; 0xFEFEFEFEFEFEFEFE; 0xE0E0E0E0F1F1F1F1; 0x1F1F1F1F0E0E0E0E。 它们均满足 $\forall x.\ \mathrm{DESEncrypt}(x, K_w) = \mathrm{DESDecrypt}(x, K_w)$。 在记住结论之外,我们也可以使用 Z3证明弱密钥的存在性,并借此求出所有 $K_w$。 针对完整的 DES网络直接使用符号求解是不现实的,因此证明的第一步是将弱...
-
“To delete your account, chat with our bot.”
TL;DR: I didn’t succeed in deleting my account as of this writing. Recently, I received an email from Groq titled “Updates to Groq’s Terms & Policies”. I registered on Groq quite a while ago with my Google account, and I didn’t use it ever since. So, I decided to delete my account. I logged in on their “Console” at console[.]groq[.]com and went to the “Settings” page. I scoured for a button like “Delete Account”, but in vain. Basically, the available tabs on the left were: Organization General Billing Team Profile Limits Usage Model Terms Projects Data Controls Project General Limits...
-
WSL2 上使用 Canokeys 踩坑
本文可供大多数需要将USB设备直通至WSL2虚拟机内的场景参考,并不局限于Canokeys或USB智能卡等话题 。 WSL2支持使用usbipd-win实现USB设备直通,可以较为方便地将OpenPGP智能卡直通至虚拟机内供GPG使用,配置方法推荐阅读微软的文章。一般而言,出...
-
JavaScript usage on csmantle.top
The main blog site does not use JavaScript for any critical functions. Features that requires JavaScript: Comments by https://utteranc.es/ Broken link converter on 404.html Web apps deployed under their own path prefixes If you don’t need them, feel free to disable JavaScript entirely when browsing through my site.
-
When spaces break your CreateProcess (and how to fix it)
The username on my Windows laptop contains a space (“ ”). This little character is known to cause dozens of software problems, and most of them are attributed to the existing codebase which does not properly quote file paths. Recently this space started troubling me more than before. Two pieces of software suddenly refused to work. I spent a while diagnosing the bugs, then filed bug reports and patches to the developers: Nushell. It’s my daily shell environment. Nushell is functional, elegant, and expressive. However, it now refused to start up in my Windows Terminal, producing an ERROR_BAD_EXE_FORMAT. PR nushell/nushell#15881...
-
Numbers as expressions
A while ago, I saw an interesting post from a Telegram channel I subscribed to. Briefly, it said: With these constants defined… const a = -3 / 80; const e = 1; const f = 5; const g = 8 / 3; const h = 9 / 10; const i = 1; const l = 11 / 3; const n = 3; const o = 1 / 3; const r = 1; const s = 7 / 3; const t = 10 / 3; const u = 12 / 5; const v = 1; const w = 9 / 5;...
-
Building chart database for AstroDX: Revisited
See the previous article for a list of needed tools and supplementary tutorials. The first step is, as always, obtaining a copy of original game image. If you have an “.app” file, refer to this awesome post to decrypt it into a mountable VHD. An extra note: When you are asked to use ImDisk (Chocolatey), just use it. Don’t use any “remastered” versions. They lack critical features. These revised scripts utilize MaichartConverter’s built-in database creation feature. That tool has some peculiarities of its own: For a chart with ID 123456, its corresponding BGA file should be “003456.mp4”, and its sound...
-
When to use Seq or Vec in Chisel?
Use Seq if you just need a Scala array or container. Use Vec if you want a multiplexer. scala.collection.immutable.Seq is purely a Scala-land concept. You can index into it via a Int thanks to its apply function. chisel3.Vec is a hardware container that can be indexed by Scala-land Ints and hardware UInts. It has two apply overloads: apply(idx: Int): T and apply(p: UInt): T. It also have connection operators like :=, allowing for element-wise connection. Always refer to the (scarce) Chisel documentation when in doubt. If the API in question is not documented (which is very likely), read the source...
-
Have fun decoding in Chisel
0. Introduction Decoders are everyday components in digital logic designs. Maintaining large, complex decoding circuits can be challenging in vanilla SystemVerilog. Today, we are exploring the utilities provided by chisel3.util.experimental.decode._ to decode whatever we want elegantly. We’ll see how Chisel’s circuit generator nature contributes to its simplicity and extensibility. Chisel’s experimental public APIs often lack usage information. This post is also intended to be an incomprehensive example of (in my view) important yet undocumented utilities. 0. Introduction 1. The problem 2. TruthTable: Programmatic logic generation 3. DecodeTable: Combined truth tables Extensibility 4. Conclusion 1. The problem Suppose we are making...