泰晓科技 -- 聚焦 Linux - 追本溯源,见微知著!


泰晓资讯·8月 / 第三期 / 2020

Wang Chen 创作于 2020/08/21

“泰晓资讯”,广泛报道 “Linux/开源” 业界资讯。欢迎广大读者投递相关资讯来源和素材,本站将进一步收集整理后发布给大家。

Linux 5.9-rc1 发布

Linus Torvalds announced today the general availability of Linux kernel 5.9 RC1 as the first milestone in the two-month long development cycle, which is available for download right now from the kernel.org website for testers and early adopters. And it finally looks like things are back to normal and Linux kernel 5.9 will be a normal release, definitely not as big as Linux kernel 5.8 was. Things have calmed down during the two-week merge window, but that’s probably because of the summer vacations.

Linus Torvalds 于 8 月 16 日发布了 Linux 5.9 版本的第一个 RC,这是下一个长达两个月的开发周期中的第一个里程碑版本,现在可以从 kernel.org 网站下载,供测试人员和早期采用者使用。目前看起来一切正常,5.9 绝对不会像 5.8 那样大,最大的修改是有关 AMD GPU 部分的改动。其他更多细节,也可以查看 LWN 的报道 “5.9 Merge window, part 1” (https://lwn.net/Articles/828120/)。

关键词: Linux, 5.9-rc1

Linux 5.8 中的新特性:Local locks

The Linux kernel has never lacked for synchronization primitives and locking mechanisms, so one might justifiably wonder why there might be a need to add another one. The addition of local locks to 5.8 provides an answer to that question. These locks, which have their origin in the realtime (PREEMPT_RT) tree, were created to solve some realtime-specific problems, but they also bring some much-needed structure to a common locking pattern used in non-realtime kernels as well.

Local locks have been merged for the 5.8 kernel, which means they are available now. This is a welcome addition, as it makes per-CPU locking have the same semantics as the other locks. This should avoid some errors, and allow lockdep in contexts where it was not possible to use before. In addition, it will make the merging of the remaining PREEMPT_RT patches that much easier.

针对同步任务的目标,过去内核中除了明确使用 spinlock 等锁机制外,也可以使用禁止中断或者抢占的方式。但和明确使用 spinlock 锁的 API 方式相比,采用禁止中断和抢占在代码中对理解所保护的临界区并不是很明显,而且不方便 lockdep 等工具辅助调试和检查。为此从 5.8 版本开始,内核引入了一个叫做 local lock 的新特性。该机制起源于著名的实时补丁(PREEMPT_RT),当时旨在解决一些特定于实时性能的问题,但该补丁也为非实时内核提供了一种通用的上锁机制。

该补丁解决问题的方法是创建一种新型的显式锁,称为 “local lock”。 在非实时系统上,获取 local lock 的动作在内部映射为禁用抢占(可能还有中断)。相反,在实时系统上,local lock 本质上则是 sleeping spinlocks,不会禁用抢占或中断。在未启用 `PREEMPT_RT`  配置选项情况下,使用 local lock 的 API  的优点在于可以阐明实际受保护的代码段,并允许对锁进行调试,包括静态分析和使用 lockdep 进行运行时调试。而直接调用禁用抢占和中断的接口是做不到这些的。

随着 local lock 功能合入 5.8 内核,不仅意味着它们现已可用,而且这将使合并剩余的 PREEMPT_RT 补丁变得更加容易。有关更多有关 local locks 的介绍请参考原文 “Local locks in the kernel” (https://lwn.net/Articles/828477/),具体的补丁参考 https://lwn.net/ml/linux-kernel/20200527201119.1692513-1-bigeasy@linutronix.de/。

**关键词**: Linux, lock

龙芯中科将推出 LoongArch 自主指令集,深度兼容 Windows、Linux、Android程序

8 月 13 日,在每两年一度的全国计算机体系结构学术年会(ACA2020)上,龙芯中科董事长、中科院计算技术研究所研究员胡伟武作了名为《指令系统的自主与兼容》的特邀报告。在报告中,他透露了龙芯的新动向——研发既 “自主” 又“兼容”的 LoongArch 指令集。如果最终达成目标,这将是一个自带 “完整” 生态,且中国人能牢牢掌握的体系。更多报道请移步 “丢掉幻想!龙芯中科将推出LoongArch自主指令集,深度兼容Windows、Linux、Android程序” (http://www.mittrchina.com/news/5506)。

**关键词**: 龙芯中科, LoongArch

Geoffrey Knauth 当选自由软件基金会 FSF 新任主席

The Free Software Foundation (FSF) has announced that Geoffrey Knauth has been elected president, and free software activist and developer Odile Bénassy has been appointed to the board of directors. Knauth is replacing Richard Stallman who resigned last year. In Knauth’s statement, he said: “The FSF board chose me at this moment as a servant leader to help the community focus on our shared dedication to protect and grow software that respects our freedoms. It is also important to protect and grow the diverse membership of the community.”

当地时间 8 月 5 日,FSF 公告已选举了 Geoffrey Knauth 为新任主席。Geoffrey Knauth 自 1997 年以来一直是 FSF 的董事会成员,他是一名计算机科学教授,为 GNU Objective-C 以及 GNU 和 FSF 的其它长期参与事项做出了贡献。去年 9 月,FSF 创始人同时也是自由软件运动发起人的 RMS 被指为性侵者辩护,并且其关于 “性侵” 的言论已经突破了大众的道德底线,深陷舆论中的他辞去了自由软件基金会主席的职务。祝愿 FSF 在新的领导集体下团结起来,不忘初心,帮助社区专注于保护和发展尊重自由的软件;同时保护和发展社区的多元化。更多报道请移步 FSF 官网文章: https://www.fsf.org/news/geoffrey-knauth-elected-free-software-foundation-president-odile-benassy-joins-the-board。

关键词: Knauth, FSF

Rust 进一步回应 Mozilla 裁员:Rust 团队成员不受影响,计划创建 Rust 基金会

The open-source project behind the Mozilla-founded systems programming language, Rust, has announced a new Rust foundation to boost its independence following Mozilla’s recent round of pandemic layoffs.

上周,Mozilla 公司宣布裁员约 250 人。这是 Mozilla 在本年度内的第二次大裁员。今年年初时,由于产品收入未达预期,Mozilla 就已裁掉了 70 名雇员,总员工人数减少至 1000 名左右。此次再裁 250 人,占比高达 25%。

Rust 是 Mozilla 推出的编程语言,因为怕被裁员事件影响舆论,Rust Core 团队近日公开表示 “Rust 项目没有危险”。按理说,Rust 本身是开源社区运作的项目,并且其社区目前有不错的发展,微软、苹果与 AWS 等大公司也在积极拥抱 Rust,社区参与的开发者更是不少,Mozilla 裁员估计对社区的影响不大。

更多相关报道,请阅读 “Programming language Rust: Mozilla job cuts have hit us badly but here’s how we’ll survive” (https://www.zdnet.com/article/programming-language-rust-mozilla-job-cuts-have-hit-us-badly-but-heres-how-well-survive/)

关键词: Rust, Mozilla


资讯内容部分来自 “LWN.net“。如果您对某些 LWN 文章感兴趣(譬如希望获得全文翻译的)请扫描二维码加微信联系我们:

tinylab wechat

Read Album:

Read Related:

Read Latest: