2014-03-21 Sabrini Ni <sabrinanitw@gmail.com>
* nds32/crt0.S: Use pseudo-instruction "bal frame" to replace
        "la + jral".
        * nds32/crt1.S: Ditto.
			
			
This commit is contained in:
		| @@ -1,3 +1,9 @@ | |||||||
|  | 2014-03-21  Sabrini Ni  <sabrinanitw@gmail.com> | ||||||
|  |  | ||||||
|  | 	* nds32/crt0.S: Use pseudo-instruction "bal frame" to replace  | ||||||
|  | 	"la + jral". | ||||||
|  | 	* nds32/crt1.S: Ditto. | ||||||
|  |  | ||||||
| 2014-03-21  Sabrini Ni  <sabrinanitw@gmail.com> | 2014-03-21  Sabrini Ni  <sabrinanitw@gmail.com> | ||||||
|  |  | ||||||
| 	* nds32/crt0.S: Eliminate initialization for $fp. | 	* nds32/crt0.S: Eliminate initialization for $fp. | ||||||
|   | |||||||
| @@ -94,8 +94,7 @@ _start: | |||||||
| 	movi	$r0, 0 | 	movi	$r0, 0 | ||||||
| 	movi	$r1, 0 | 	movi	$r1, 0 | ||||||
| 	/* Call 'main'.  */ | 	/* Call 'main'.  */ | ||||||
| 	la	$r15, main | 	bal	main | ||||||
| 	jral	$r15 |  | ||||||
|  |  | ||||||
| .L_terminate_program: | .L_terminate_program: | ||||||
| 	/* There are two ways to terminate program: | 	/* There are two ways to terminate program: | ||||||
| @@ -106,8 +105,7 @@ _start: | |||||||
| 	    Currently, we use option 2 as a solution to follow C99 5.1.2.2.3, | 	    Currently, we use option 2 as a solution to follow C99 5.1.2.2.3, | ||||||
| 	    but aware that general exit() will do some cleanup procedures | 	    but aware that general exit() will do some cleanup procedures | ||||||
| 	    which may result in large-memory-footprints.  */ | 	    which may result in large-memory-footprints.  */ | ||||||
| 	la	$r15, exit | 	bal	exit | ||||||
| 	jral	$r15 |  | ||||||
|  |  | ||||||
| .L_forever_loop: | .L_forever_loop: | ||||||
| 	/* Should never return here.  */ | 	/* Should never return here.  */ | ||||||
|   | |||||||
| @@ -100,8 +100,7 @@ _start: | |||||||
| 	movi	$r1, 0 | 	movi	$r1, 0 | ||||||
| 	movi	$r2, 0 | 	movi	$r2, 0 | ||||||
| 	/* Call 'main'.  */ | 	/* Call 'main'.  */ | ||||||
| 	la	$r15, main | 	bal	main | ||||||
| 	jral	$r15 |  | ||||||
|  |  | ||||||
| .L_terminate_program: | .L_terminate_program: | ||||||
| 	/* There are two ways to terminate program: | 	/* There are two ways to terminate program: | ||||||
| @@ -112,8 +111,8 @@ _start: | |||||||
| 	    Currently, we use option 2 as a solution to follow C99 5.1.2.2.3, | 	    Currently, we use option 2 as a solution to follow C99 5.1.2.2.3, | ||||||
| 	    but aware that general exit() will do some cleanup procedures | 	    but aware that general exit() will do some cleanup procedures | ||||||
| 	    which may result in large-memory-footprints.  */ | 	    which may result in large-memory-footprints.  */ | ||||||
| 	la	$r15, exit | 	 | ||||||
| 	jral	$r15 | 	bal	exit | ||||||
|  |  | ||||||
| .L_forever_loop: | .L_forever_loop: | ||||||
| 	/* Should never return here.  */ | 	/* Should never return here.  */ | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user