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

mips guest needs CP0 register support #407

Closed
lunixbochs opened this issue Jan 30, 2016 · 2 comments
Closed

mips guest needs CP0 register support #407

lunixbochs opened this issue Jan 30, 2016 · 2 comments

Comments

@lunixbochs
Copy link
Contributor

http://en.wikichip.org/wiki/mips/coprocessor_0

For example we need access to CP0_UserLocal to set thread-local storage.

Edit: I thought I was going to work around this by running shellcode, but it's in the middle of a syscall so I need to trampoline and I haven't implemented that yet, so this is actually blocking Usercorn mips Linux support.

@aquynh
Copy link
Member

aquynh commented Jan 31, 2016

yes pull request, please.

@lunixbochs
Copy link
Contributor Author

actually according to this, the instruction rdhwr $v1, $29 to read the current TLS address seems to trap: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=28126#c3

so instead we might just need an instruction hook for it

I tried running mtc0 manually but we don't have the feature flag CP0C3_ULRI, which means we just need a hook for rdhwr that works like the x86 IN helpers.

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

4 participants