Skip to content

Conversation

@fslongjin
Copy link
Member

@fslongjin fslongjin commented May 12, 2025

  • 实现syscall table
  • 为syscall table适配write/writev系统调用

添加这个方案的主要目的是解决Syscall::handle函数的栈内存占用过高的问题,以及syscall多了之后,match不优雅的问题。

并且,现在打印syscall会方便一些,能格式化参数的Value了(由具体的syscall去决定自己怎么格式化入参)
img_v3_02m8_7b7cad17-cb22-43af-af04-7e44156e197g
img_v3_02m8_45ceeab1-c1fd-4cd8-a1d5-77baa5f04b2g

@fslongjin fslongjin requested review from Godones and Samuka007 May 12, 2025 17:41
@github-actions github-actions bot added the enhancement New feature or request label May 12, 2025
@fslongjin fslongjin force-pushed the feat-add-syscall-table branch from e716384 to 1dae3c0 Compare May 12, 2025 17:47
@fslongjin fslongjin requested a review from sparkzky May 12, 2025 17:47
@fslongjin fslongjin force-pushed the feat-add-syscall-table branch 4 times, most recently from 5a17ff2 to 2fffbec Compare May 12, 2025 18:19
- 实现syscall table
- 为syscall table适配write/writev系统调用

Signed-off-by: longjin <[email protected]>
@fslongjin fslongjin force-pushed the feat-add-syscall-table branch from 2fffbec to c25e567 Compare May 12, 2025 18:21
@Godones
Copy link
Member

Godones commented May 13, 2025

match为什么会让syscall::handle函数的栈内存占用过高?

@fslongjin
Copy link
Member Author

match为什么会让syscall::handle函数的栈内存占用过高?

  1. 有些分支那里写了局部变量
  2. 很多分支都是执行比如Self::write Self::read之类的。然后内层的函数没有inline(never) 就有概率被内联到外面来。

@fslongjin fslongjin merged commit b322121 into DragonOS-Community:master May 13, 2025
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants