I tried to compile qemu with gcc4 but I get a lot of weird compiler errors. Same happens if I try to use gcc2. How can I fix this?
• A: Good luck. gcc2 should work fine but some older versions have problems with register allocation. It is recommended to use gcc3 (specificly gcc 3.3) to compile qemu. gcc4 has significant changes to the way it structures the code it generates. This makes it incompatible with the way qemu handles dynamic translation of guest machine codes, and this is really difficult to work around. A long term solution known as qop is in the works, but for now just use gcc3 to compile qemu. If you really want to try making gcc4 work with qemu, see this thread, which includes several patches that you can use to try make this work. Note that gcc4 may still have register allocation problems (amd64 should have no issues but 32bit x86 will). See this bug for more information. This can be worked around by disabling the use of global register variables in qemu, but this has a significant performance hit. Using gcc3 is strongly recommended.
Good luck. gcc2 should work fine but some older versions have problems with register allocation. It is recommended to use gcc3 (specificly gcc 3.3) to compile qemu. gcc4 has significant changes to the way it structures the code it generates. This makes it incompatible with the way qemu handles dynamic translation of guest machine codes, and this is really difficult to work around. A long term solution known as qop is in the works, but for now just use gcc3 to compile qemu. If you really want to try making gcc4 work with qemu, see this thread, which includes several patches that you can use to try make this work. Note that gcc4 may still have register allocation problems (amd64 should have no issues but 32bit x86 will). See this bug for more information. This can be worked around by disabling the use of global register variables in qemu, but this has a significant performance hit. Using gcc3 is strongly recommended. Thanks to Paul Brook for providing the above information.
Related Questions
- I just upgraded from CA-Telon 2.3 and now when I try to import or generate, I get lots of errors, including numerous severity-16 TLMSCR17 - INVALID OUTATTR VALUE "" SPECIFIED MNOTEs. Whats wrong?
- When I generate my business objects, I get a lot of compiler errors about "cannot convert from System.Data.SqlDbType to System.Data.DbType." What is wrong?
- I tried to compile qemu with gcc4 but I get a lot of weird compiler errors. Same happens if I try to use gcc2. How can I fix this?