View previous topic :: View next topic |
Author |
Message |
CaptainBlood Advocate
Joined: 24 Jan 2010 Posts: 3655
|
Posted: Sat Jan 24, 2015 6:23 am Post subject: Emulating & Virtualising ARM on amd64 |
|
|
Hi,
I have a project for a Asterisk on ARM.
Despite I don't have ARM motherboard yet, I'd like to start prototyping however.
I plan to emulate and virtualise on VT-x able amd64.
Since I've been doing XEN for a while, I plan to investigate to integrate qemu upstream.
Feasibily wise, I beg for radvice to know whether I"m barking up the wrong tree or not, before starting to pull my hair out.
Moreover adequate links would be somehow appreciated, even if partial.
Thks 4 ur attention. |
|
Back to top |
|
|
eccerr0r Watchman
Joined: 01 Jul 2004 Posts: 9696 Location: almost Mile High in the USA
|
Posted: Sat Jan 24, 2015 9:23 am Post subject: |
|
|
I'm not sure if VT-x will help amd64 processors emulate another architecture, it was designed to emulate x86/amd64 in amd64 at high speeds. Crossing architectures will resort to software emulation and there's nothing that really can help that. _________________ Intel Core i7 2700K/Radeon R7 250/24GB DDR3/256GB SSD
What am I supposed watching? |
|
Back to top |
|
|
CaptainBlood Advocate
Joined: 24 Jan 2010 Posts: 3655
|
Posted: Sat Jan 24, 2015 11:30 am Post subject: |
|
|
HI,
I've just mentioned availability just in case of requirement...
Anyhow link http://wiki.xenproject.org/wiki/Xen_ARM_with_Virtualization_Extensions at section Quote: | Use of qemu-system-i386 on ARM | suggests x86 emulation on ARM architecture. I'm consequently wondering whether the contrary is possible or not...
Thks 4 ur attention, interest & support. |
|
Back to top |
|
|
eccerr0r Watchman
Joined: 01 Jul 2004 Posts: 9696 Location: almost Mile High in the USA
|
Posted: Sun Jan 25, 2015 4:09 am Post subject: |
|
|
As said of course you can emulate x86 on arm and arm on x86, but neither of these situations can use hardware helpers for emulation - so these extensions are simply useless.
The hardware helpers for emulation are only for virtualizing "expensive" calls such that they can return to the hypervisor context fast to be emulated. These expensive calls to emulate tend to be software interrupts, emulating hardware registers, and entering protected mode from usermode. On machines without VT extensions these are emulated by instruction traps which is why they are so slow - you can get one instruction taking thousands of instructions to implement. With hardware assistance the emulation traps drops to just hundreds of instructions, at least 10x faster. Of course overall speed is not 10x faster except if your code was triggering these instructions all of the time.
In software emulation the instruction emulation is so bad that these expensive calls aren't really even a concern, it will still be awful, even with dynamic translation. I've noticed that KVM that takes advantage of processor virtualization extensions and is still not quite up to native speeds but is very reasonable. Without virtualization, speed penalty can go down another half or so. With full instruction emulation, you're looking at 1/20th the speed of the host CPU or so, but a bit faster with DT.
I don't know if there are any multithreadded DT emulation engines out there, it may speed things up a bit on multiprocessor hosts, but for the mean time, you only can singlethread these emulations (unless you're emulating a SMP system of course.) _________________ Intel Core i7 2700K/Radeon R7 250/24GB DDR3/256GB SSD
What am I supposed watching? |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|