arc: Have nops in _exit_halt only for ARCompact

ARCompact processors (ARC 600 and ARC 700) require three "nop"s after the
"flag 1" instruction. Later ARC processors do not have this requirement, so
it is possible to reduce size of "_exit_halt" for them.

libgloss/
2016-05-24  Anton Kolesov  <Anton.Kolesov@synopsys.com>

	* arc/crt0.S (_exit_halt): Insert nops only for ARCompact.
This commit is contained in:
Anton Kolesov 2016-05-13 18:21:08 +03:00 committed by Corinna Vinschen
parent dd00a8e719
commit d1dcdb8886
1 changed files with 9 additions and 6 deletions

View File

@ -207,15 +207,18 @@ __start:
; r0 contains exit code
j @exit
.section .text._exit_halt,"ax",@progbits
.global _exit_halt
.type _exit_halt, @function
.section .text._exit_halt,"ax",@progbits
.global _exit_halt
.type _exit_halt, @function
_exit_halt:
; r0 contains exit code
flag 0x01
flag 1
#if defined (__ARC600__) || defined (__ARC700__)
; ARCompact requires 3 nops after flag 1
nop
nop ; ARCompact requires 3 nops after flag 1
nop
nop
#endif
b @_exit_halt
nop
.balign 4