Skip to content

feat(toolchain): 支持 x86_64 模拟器原生构建 - #100

Merged
DefectingCat merged 1 commit into
mainfrom
feat/toolchain-x86-emulator
Nov 16, 2026
Merged

DefectingCat merged 1 commit into
mainfrom
feat/toolchain-x86-emulator

Conversation

@DefectingCat

Copy link
Copy Markdown
Contributor

摘要

  • 为 x86_64 模拟器构建 mihomo 共享库,按 ABI 隔离工具链和产物;默认 ARM64 构建保持不变。
  • HAP 仅打包所选 ABI,并新增设备动态加载、多线程 C API 冒烟测试及 ADR。

验证

  • make core ABI=x86_64 与 ARM64 make core:通过;产物无 initial-exec TLS 重定位。
  • 两种 ABI 的 make hap:通过;已检查 HAP 内 ELF 架构与所选 ABI 一致。
  • make core-smoke ABI=x86_64:API 26 x86_64 模拟器动态加载成功;加载前已有线程及加载后新线程共完成 42,002 次 API 调用。

设备与产品指标

模拟器原生库冒烟通过;签名安装、应用内 VPN 与代理转发尚未验证。冷启动、8 小时待机耗电、新连接延迟、24 小时内核稳定性未测量;本 PR 仅增加显式选择 x86_64 的构建路径,默认 ARM64 配置保持不变。

Refs #99

- 为 linux/amd64 共享库提供保留寄存器和标志位的 TLSDESC 辅助调用,并修正 musl 初始化参数
- 按 ABI 隔离固定版本 Go 工具链与依赖,默认 ARM64 补丁保持不变
- HAP 仅打包所选 ABI,保留原 ARM64 文件名和两架构产物
- 新增设备原生动态加载及已有线程、新建线程的 C API 冒烟
- 验证:双 ABI make core 与 make hap 通过,包内 ELF 架构一致;API26 x86 模拟器完成 42002 次 API 调用
- make lint 仍被 main 已有 ProfileBatch await-thenable 阻塞,修复在独立 PR #97;签名及应用/VPN 验收待协作
- Refs #99
@DefectingCat
DefectingCat requested a review from xunrua as a code owner November 16, 2026 07:24
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 16, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-16T07:25:42.698960Z 0a5af89 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 0a5af89708

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread docs/adr/0014-x86-emulator-toolchain.md Resolved
@DefectingCat
DefectingCat merged commit 7d51d5a into main Nov 16, 2026
9 checks passed
@DefectingCat
DefectingCat deleted the feat/toolchain-x86-emulator branch November 16, 2026 07:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant