2014-12-19 Steve Ellcey <sellcey@imgtec.com>

* sysdeps/mips/sys/asm.h (PTR_ADDU): Use addu on mips32r6/mips64r6.
	(PTR_ADDIU): Use addiu for mips32r6/mips64r6.
	(PTR_SUBU): Use subu for mips32r6/mips64r6.
	(PTR_SUBIU): Use subu for mips32r6/mips64r6 (subiu does not exist).
	* sysdeps/mips/machine-gmon.h (PTR_ADDU_STRING) Use addu for
	mips32r6/mips64r6.
	(PTR_SUBU_STRING) Use subu for mips32r6/mips64r6.
This commit is contained in:
Steve Ellcey 2014-12-19 14:37:44 -08:00
parent 3eb38795db
commit 04d5556197
2 changed files with 16 additions and 4 deletions

View File

@ -83,8 +83,13 @@ static void __attribute_used__ __mcount (u_long frompc, u_long selfpc)
#endif #endif
#if _MIPS_SIM == _ABIN32 #if _MIPS_SIM == _ABIN32
# define PTR_ADDU_STRING "add" /* no u */ # if __mips_isa_rev < 6
# define PTR_SUBU_STRING "sub" /* no u */ # define PTR_ADDU_STRING "add" /* no u */
# define PTR_SUBU_STRING "sub" /* no u */
# else
# define PTR_ADDU_STRING "addu"
# define PTR_SUBU_STRING "subu"
# endif
#elif _MIPS_SIM == _ABI64 #elif _MIPS_SIM == _ABI64
# define PTR_ADDU_STRING "daddu" # define PTR_ADDU_STRING "daddu"
# define PTR_SUBU_STRING "dsubu" # define PTR_SUBU_STRING "dsubu"

View File

@ -416,12 +416,19 @@ symbol = value
#if _MIPS_SIM == _ABIN32 #if _MIPS_SIM == _ABIN32
# define PTR_ADD add # define PTR_ADD add
# define PTR_ADDI addi # define PTR_ADDI addi
# define PTR_ADDU add /* no u */
# define PTR_ADDIU addi /* no u */
# define PTR_SUB sub # define PTR_SUB sub
# define PTR_SUBI subi # define PTR_SUBI subi
#if __mips_isa_rev < 6
# define PTR_ADDU add /* no u */
# define PTR_ADDIU addi /* no u */
# define PTR_SUBU sub /* no u */ # define PTR_SUBU sub /* no u */
# define PTR_SUBIU sub /* no u */ # define PTR_SUBIU sub /* no u */
#else
# define PTR_ADDU addu
# define PTR_ADDIU addiu
# define PTR_SUBU subu
# define PTR_SUBIU subu
#endif
# define PTR_L lw # define PTR_L lw
# define PTR_LA la # define PTR_LA la
# define PTR_S sw # define PTR_S sw