869ca150e7 
								
							 
						 
						
							
							
								
								target-mips: fix user-mode emulation startup  
							
							... 
							
							
							
							Running programs with the MIPS user-mode emulator fails during dynamic
loading, as floating-point instructions are not enabled in in
env->hflags.  Move the code for doing so from fpu_init to cpu_reset so
the MIPS_HFLAG_{FPU,F64} setting doesn't get clobbered by cpu_reset
setting env->hflags to MIPS_HFLAG_UM.
The same end can be achieved by swapping the ordering of fpu_init and
cpu_reset in cpu_mips_init, but it seemed better to consolidate the
CONFIG_USER_ONLY code into a single location.
Signed-off-by: Nathan Froyd <froydnj@codesourcery.com>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
(cherry picked from commit 91a7593526 
							
						 
						
							2009-12-13 21:05:16 +01:00  
				
					
						
							
							
								 
						
							
								2a6e32dd46 
								
							 
						 
						
							
							
								
								target-mips: make CP0_LLAddr register CPU dependent  
							
							... 
							
							
							
							Depending on the CPU, CP0_LLAddr is either read-only or read-write,
and the returned value can be shifted by a variable amount of bits.
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Signed-off-by: Hervé Poussineau <hpoussin@reactos.org> 
							
						 
						
							2009-11-22 14:12:19 +01:00  
				
					
						
							
							
								 
						
							
								51cc2e783a 
								
							 
						 
						
							
							
								
								mips: fix cpu_reset memory leak  
							
							... 
							
							
							
							Remove cpu_mips_register()
- move mmu_init(), fpu_init() and mvp_init() into cpu_mips_init()
- move the other parts in cpu_mips_init()
Reported-by: Blue Swirl <blauwirbel@gmail.com>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net> 
							
						 
						
							2009-11-14 02:25:52 +01:00  
				
					
						
							
							
								 
						
							
								c227f0995e 
								
							 
						 
						
							
							
								
								Revert "Get rid of _t suffix"  
							
							... 
							
							
							
							In the very least, a change like this requires discussion on the list.
The naming convention is goofy and it causes a massive merge problem.  Something
like this _must_ be presented on the list first so people can provide input
and cope with it.
This reverts commit 99a0949b72 
							
						 
						
							2009-10-01 16:12:16 -05:00  
				
					
						
							
							
								 
						
							
								99a0949b72 
								
							 
						 
						
							
							
								
								Get rid of _t suffix  
							
							... 
							
							
							
							Some not so obvious bits, slirp and Xen were left alone for the time
being.
Signed-off-by: malc <av1474@comtv.ru> 
							
						 
						
							2009-10-01 22:45:02 +04:00  
				
					
						
							
							
								 
						
							
								8167ee8839 
								
							 
						 
						
							
							
								
								Update to a hopefully more future proof FSF address  
							
							... 
							
							
							
							Signed-off-by: Blue Swirl <blauwirbel@gmail.com> 
							
						 
						
							2009-07-16 20:47:01 +00:00  
				
					
						
							
							
								 
						
							
								c01fccd2de 
								
							 
						 
						
							
							
								
								target-mips: rename helpers from do_ to helper_  
							
							... 
							
							
							
							Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6773 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2009-03-08 00:06:01 +00:00  
				
					
						
							
							
								 
						
							
								6958549d4f 
								
							 
						 
						
							
							
								
								target-mips: fix indentation  
							
							... 
							
							
							
							Remove all tabs from target-mips/*
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6306 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2009-01-14 19:40:36 +00:00  
				
					
						
							
							
								 
						
							
								932e71cd57 
								
							 
						 
						
							
							
								
								target-mips: get rid of tests on env->user_mode_only  
							
							... 
							
							
							
							Replace runtime checks on env->user_mode_only by compile time
checks on CONFIG_USER_ONLY.
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6276 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2009-01-12 21:33:13 +00:00  
				
					
						
							
							
								 
						
							
								fad6cb1a56 
								
							 
						 
						
							
							
								
								Update FSF address in GPL/LGPL boilerplate  
							
							... 
							
							
							
							The attached patch updates the FSF address in the GPL/LGPL boilerplate
in most GPL/LGPLed files, and also in COPYING.LIB.
Signed-off-by: Stuart Brady <stuart.brady@gmail.com>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6162 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2009-01-04 22:05:52 +00:00  
				
					
						
							
							
								 
						
							
								b1503cda1e 
								
							 
						 
						
							
							
								
								Use the ARRAY_SIZE() macro where appropriate.  
							
							... 
							
							
							
							Change from v1:
  Avoid changing the existing coding style in certain files.
Signed-off-by: Stuart Brady <stuart.brady@gmail.com>
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6120 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2008-12-22 20:33:55 +00:00  
				
					
						
							
							
								 
						
							
								f01be15458 
								
							 
						 
						
							
							
								
								Move the active FPU registers into env again, and use more TCG registers  
							
							... 
							
							
							
							to access them.
Signed-off-by: Thiemo Seufer <ths@networkno.de>
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5252 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2008-09-18 11:57:27 +00:00  
				
					
						
							
							
								 
						
							
								929a62a0d7 
								
							 
						 
						
							
							
								
								target-mips: fix warning  
							
							... 
							
							
							
							Attached patch fixes a warning in cpu_mips_find_by_name().
'name' is a string, so it should be declared as char*, not unsigned char*.
(Hervé Poussineau)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5213 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2008-09-14 16:28:26 +00:00  
				
					
						
							
							
								 
						
							
								f8a6ec5817 
								
							 
						 
						
							
							
								
								Build fix for gcc-3.3.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5139 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2008-09-02 17:39:45 +00:00  
				
					
						
							
							
								 
						
							
								0eaef5aa01 
								
							 
						 
						
							
							
								
								Less hardcoding of TARGET_USER_ONLY.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4928 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2008-07-23 16:14:22 +00:00  
				
					
						
							
							
								 
						
							
								8706c3824f 
								
							 
						 
						
							
							
								
								A bunch of minor code improvements in the MIPS target.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4921 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2008-07-21 21:38:04 +00:00  
				
					
						
							
							
								 
						
							
								50366fe93a 
								
							 
						 
						
							
							
								
								Fix compiler warning, by Stefan Weil.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4915 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2008-07-20 19:13:19 +00:00  
				
					
						
							
							
								 
						
							
								b5dc7732e1 
								
							 
						 
						
							
							
								
								More efficient target register / TC accesses.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4794 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2008-06-27 10:02:35 +00:00  
				
					
						
							
							
								 
						
							
								893f986502 
								
							 
						 
						
							
							
								
								Honour current_tc for MIPS M{T,F}{HI,LO}, by Richard Sandiford.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4604 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2008-05-28 13:37:19 +00:00  
				
					
						
							
							
								 
						
							
								36271893ab 
								
							 
						 
						
							
							
								
								Enable 64-bit FPU only for NewABI. Spotted by Vince Weaver.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4368 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2008-05-06 20:48:02 +00:00  
				
					
						
							
							
								 
						
							
								958fb4a92c 
								
							 
						 
						
							
							
								
								Use TCG for MIPS GPR moves.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4356 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2008-05-06 10:57:59 +00:00  
				
					
						
							
							
								 
						
							
								ea4b07f762 
								
							 
						 
						
							
							
								
								Set FCR0.F64 for MIPS64R2-generic, by Richard Sandiford.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3865 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-12-28 12:35:05 +00:00  
				
					
						
							
							
								 
						
							
								e9c71dd1c1 
								
							 
						 
						
							
							
								
								Support for VR5432, and some of its special instructions. Original patch  
							
							... 
							
							
							
							by Dirk Behme.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3859 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-12-25 20:46:56 +00:00  
				
					
						
							
							
								 
						
							
								29fe0e3490 
								
							 
						 
						
							
							
								
								5K and 20K are Release 1 CPUs.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3858 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-12-25 17:32:46 +00:00  
				
					
						
							
							
								 
						
							
								6d35524c40 
								
							 
						 
						
							
							
								
								Improved PABITS handling, and config register fixes.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3855 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-12-25 03:13:56 +00:00  
				
					
						
							
							
								 
						
							
								a1daafd8df 
								
							 
						 
						
							
							
								
								Fix CCRes value for 20Kc.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3849 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-12-24 14:33:57 +00:00  
				
					
						
							
							
								 
						
							
								8d162c2b68 
								
							 
						 
						
							
							
								
								Add older 4Km variants.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3708 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-11-19 16:10:33 +00:00  
				
					
						
							
							
								 
						
							
								8c89395eeb 
								
							 
						 
						
							
							
								
								Use a valid PRid.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3685 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-11-18 03:19:58 +00:00  
				
					
						
							
							
								 
						
							
								3e4587d5d1 
								
							 
						 
						
							
							
								
								Introduce 4KEm configuration with fixed MMU mapping. Delete bogus INSN_DSP  
							
							... 
							
							
							
							flags.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3637 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-11-14 03:11:17 +00:00  
				
					
						
							
							
								 
						
							
								aaed909a49 
								
							 
						 
						
							
							
								
								added cpu_model parameter to cpu_init()  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3562 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-11-10 15:15:54 +00:00  
				
					
						
							
							
								 
						
							
								d26bc2118e 
								
							 
						 
						
							
							
								
								Clean out the N32 macros from target-mips, and introduce MIPS ABI specific  
							
							... 
							
							
							
							defines for linux-user.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3556 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-11-08 18:05:37 +00:00  
				
					
						
							
							
								 
						
							
								d2123ead89 
								
							 
						 
						
							
							
								
								Preliminary MIPS64R2 mode.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3479 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-10-29 09:38:43 +00:00  
				
					
						
							
							
								 
						
							
								7385ac0ba2 
								
							 
						 
						
							
							
								
								Use the standard ASE check for MIPS-3D and MT.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3427 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-10-23 17:04:27 +00:00  
				
					
						
							
							
								 
						
							
								540635ba65 
								
							 
						 
						
							
							
								
								Code provision for n32/n64 mips userland emulation. Not functional yet.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3284 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-09-30 01:58:33 +00:00  
				
					
						
							
							
								 
						
							
								671880e651 
								
							 
						 
						
							
							
								
								Supervisor mode implementation, by Aurelien Jarno.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3267 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-09-29 19:21:36 +00:00  
				
					
						
							
							
								 
						
							
								e189e74868 
								
							 
						 
						
							
							
								
								Per-CPU instruction decoding implementation, by Aurelien Jarno.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3228 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-09-24 12:48:00 +00:00  
				
					
						
							
							
								 
						
							
								2337fdc208 
								
							 
						 
						
							
							
								
								Fix mips usermode emulation.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3212 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-09-23 17:54:29 +00:00  
				
					
						
							
							
								 
						
							
								ead9360e2f 
								
							 
						 
						
							
							
								
								Partial support for 34K multithreading, not functional yet.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3156 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-09-06 00:18:15 +00:00  
				
					
						
							
							
								 
						
							
								3ddf0b5cde 
								
							 
						 
						
							
							
								
								Disable 64-bit instructions on 32-bit CPU, by Aurelien Jarno.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3146 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-08-26 17:37:23 +00:00  
				
					
						
							
							
								 
						
							
								ae5d8053a1 
								
							 
						 
						
							
							
								
								Fix MIPS cache configuration, by Aurelien Jarno.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3092 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-07-29 22:11:46 +00:00  
				
					
						
							
							
								 
						
							
								e034e2c39a 
								
							 
						 
						
							
							
								
								Handle MIPS64 SEGBITS value correctly.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3011 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-06-23 18:04:12 +00:00  
				
					
						
							
							
								 
						
							
								17044c06b8 
								
							 
						 
						
							
							
								
								Allow emulation of 32bit targets in the MIPS64 capable qemu version.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3007 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-06-22 23:50:19 +00:00  
				
					
						
							
							
								 
						
							
								bd04c6feb9 
								
							 
						 
						
							
							
								
								Change 20Kc PRID to a later version.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2980 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-06-12 12:43:47 +00:00  
				
					
						
							
							
								 
						
							
								70cf0b63f1 
								
							 
						 
						
							
							
								
								R5k has PX implemented.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2963 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-06-09 12:29:32 +00:00  
				
					
						
							
							
								 
						
							
								1e3d0552f5 
								
							 
						 
						
							
							
								
								Update some comments, 64bit FPU support is functional regardless of  
							
							... 
							
							
							
							funny non-standard fcr0 bits on earlier CPUs.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2919 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-06-01 21:57:32 +00:00  
				
					
						
							
							
								 
						
							
								c9c1a06457 
								
							 
						 
						
							
							
								
								Add support for 5Kc/5Kf/20Kc, based on a patch by Aurelien Jarno.  
							
							... 
							
							
							
							Note that the F64 flag isn't usable on any of those (and the R4000),
so all our 64bit FPU goodness goes out of the window until a shadow
capability flag is implemented. :-(
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2910 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-06-01 14:58:56 +00:00  
				
					
						
							
							
								 
						
							
								a7037b2950 
								
							 
						 
						
							
							
								
								Allow again FPU for usermode emulation.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2905 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-06-01 11:47:24 +00:00  
				
					
						
							
							
								 
						
							
								51b2772f28 
								
							 
						 
						
							
							
								
								Fix CPU (re-)selection on reset.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2900 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-05-30 20:46:02 +00:00  
				
					
						
							
							
								 
						
							
								29929e3490 
								
							 
						 
						
							
							
								
								MIPS TLB style selection at runtime, by Herve Poussineau.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2809 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-05-13 13:49:44 +00:00  
				
					
						
							
							
								 
						
							
								4759513bd9 
								
							 
						 
						
							
							
								
								Fix missing status ro mask initialization, thanks Stefan Weil.  
							
							... 
							
							
							
							git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2800 c046a42c-6fe2-441c-8c8c-71466251a162 
							
						 
						
							2007-05-11 00:02:14 +00:00