4 ms·
I want to do hardware development in an x86_64 Linux VM on a Mac. I work with closed source vendor tools that are only available as precompiled x86 binaries (it
by fulladder 3y ago
I want to do hardware development in an x86_64 Linux VM on a Mac. I work with closed source vendor tools that are only available as precompiled x86 binaries (it's FPGA development, everything is closed source).
Am I going to run into problems, either with performance of x86 code in a translator like Parallels, or with USB connections to the target hardware from within a virtual machine on M2/M3?
- coconut08 3y agoParallels offers rosetta inside of linux on apple silicon, but rosetta only supports 64bit x86. If you want 32bit you are going need to use another solution. Fex Emu supports x86 32 bit but the performance probably won't be great and it isn't going to be plug and play. Windows for arm has their own version of rosetta which supports both 32 and 64 bit x86 and it works well enough, but i don't know that it will be performant enough for heavy work. if your closed source tools also require closed source drivers then it probably won't work on either.
- jeroenhd 3y agoLast time I read up on the performance characteristics of Windows' ARM translator, it seemed to be pretty close to what Apple manages to do with Rosetta. Some performance is left on the table (all the hardware trickery Apple built in) but amd64-to-aarch64 should work well enough. The big problem with Windows on ARM seems to be that nobody is making fast enough ARM chips for a price that marches the performance expectations. The new Qualcom chips look very promising, though!
- coder-256 3y agoYou may want to consider trying Docker if you only need a shell and not a full window manager. For 32-bit x86 you will need to disable Rosetta and use emulation, which is a performance hit but probably the best and easiest option.
- justinclift 3y agoHopefully you won't need to run KVM or other virtualised things inside that Linux VM, as that won't work.
- NoZebra120vClip 3y ago> I want to do hardware development in an x86_64 Linux VM on a Mac. Why, though? Why do you want to use a Mac? What rationale is there for diverging from the native architecture you're targeting?
- fulladder 3y agoI just don't want to have two computers, one for FPGA development and one for everything else. It would make my life easier to put everyone on one machine. I appreciate all the comments here and think the performance hit could be too much.
- ayewo 3y agoBefore you give up, give OrbStack a try: https://orbstack.dev/ https://orbstack.dev/ It’s significantly faster than Docker and some users in the Discord community have been able to use it to run hand-built Linux x86 VMs on Apple Silicon. It’s a paid product though, but you can download it for free and try it out before paying.
- ta988 3y agoQEMU (with UTM if you need an UI to create the VM) can do that. A word of warning, FPGA tools are extremely cpu intensive (and often poorly optimized) so you are not going to be happy compared to your colleagues running on native x86.
- fulladder 3y agoThank you.
- rewgs 3y agoGive Orbstack a shot. VM installation is a total breeze, and its x86_64 Linux performance has been awesome for me.
- vbezhenar 3y agoIf you need to pass-through USB devices from the macOS host to the Linux guest, you'll be in trouble. For pure compute, it would work, although with some performance hit. Look for Virtualization.Framework-based VMs and Apple Rosetta for Linux.
- loxdalen 3y agoHad a lot of problems with trying to get an x86 VM up on my M2 Mac. But docker has been working pretty well.
- bogantech 3y agoVivado works quite well from what I've read https://mremallin.ca/2022/10/24/xilinx-vivado-on-an-apple-m1-pro-rosetta-2-edition/ https://mremallin.ca/2022/10/24/xilinx-vivado-on-an-apple-m1...
- nvarsj 3y agoRosetta/parallels can’t emulate the full x86 instruction set. You will run into problems. Like avx2, which is over 10 years old, won’t work. Best to stick with an x86 machine for x86 dev. One approach is to use a remote server. Source: learned this the hard way.
- lwkl 3y agoIf you are using Vivado there are some scripts on GitHub to make this work. I don’t know how reliable they are though. I think they run it in a Docker container an use X to display the application in macOS. https://github.com/ichi4096/vivado-on-silicon-mac https://github.com/ichi4096/vivado-on-silicon-mac