Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The bionic libc test test_setjmp fails #17

Open
chenzhu33 opened this issue Oct 1, 2012 · 3 comments
Open

The bionic libc test test_setjmp fails #17

chenzhu33 opened this issue Oct 1, 2012 · 3 comments

Comments

@chenzhu33
Copy link

Description
The test_setjmp tries to test that integer and float registers are restored properly. However it fails when test float registers.

setjmp returns not zero
register xx's value is changed :
if (xx != FLOAT_VALUE1) {
fprintf(stderr, "setjmp() is broken for floating point registers !\n");
exit(1);
}

Reproduce steps
cd ~/ucore_plus/ucore
make ARCH=arm BOARD=goldfishv7 defconfig
make sfsimg
make kernel
./uCore_test -s bionic -w 15 -t 45 -f src/user-ucore/testspecs/test_setjmp.testspec

Current result
kernel_execve: pid = 4, name = "/bionic-test/test_setjmp".
setjmp() is broken for floating point registers !

Expected Result
the sentence: "setjmp() is broken for floating point registers !" wouldn't appear

@chyh1990
Copy link
Collaborator

chyh1990 commented Oct 1, 2012

you should aware that the task switching code in the kernel does NOT store/restore floating point regs, so you may need to add this support in order to pass the test.

@chenzhu33
Copy link
Author

所以我应该为ucore添加浮点运算才能通过这个测试吗?
这个该怎么添加呢,大概的思路是怎么样的?

中秋国庆快乐~


FR 陈朱伟
Chen Zhu Wei
THU -- CST
Tsinghua University Beijing 100084
P.R.CHINA

------------------ 原始邮件 ------------------
发件人: "Chen Yuheng"notifications@github.com;
发送时间: 2012年10月1日(星期一) 中午1:05
收件人: "chyyuu/ucore_plus"ucore_plus@noreply.github.com;
抄送: "Czw"346402360@qq.com;
主题: Re: [ucore_plus] The bionic libc test test_setjmp fails (#17)

you should aware that the task switching code in the kernel does NOT store/restore floating point regs, so you may need to add this support in order to pass the test.

           —
           Reply to this email directly or view it on GitHub.

@chyh1990
Copy link
Collaborator

chyh1990 commented Oct 1, 2012

任务切换时恢复和保存相关寄存器,可参考手册和linux内核代码

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants