Skip to content

Commit

Permalink
or1k: Implement CRT_CALL_STATIC_FUNCTION
Browse files Browse the repository at this point in the history
This is done to save a bit of noise generated from the generic
_init() / _fini() call generation in crtstuff.c.  Found this out
when working on the .eh_frame initialization bug.
  • Loading branch information
stffrdhrn committed Jul 21, 2018
1 parent 209851f commit 58c41c6
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions gcc/config/or1k/or1k.h
Original file line number Diff line number Diff line change
Expand Up @@ -265,6 +265,16 @@ do { \
} \
while (0)

/* This is used in crtstuff to create call stubs in the
_init() and _fini() functions. Defining this here saves
a few bytes created by the dummy call_xxx() functions. */
#define CRT_CALL_STATIC_FUNCTION(SECTION_OP, FUNC) \
asm (SECTION_OP "\n" \
" l.jal " #FUNC "\n" \
" l.nop\n" \
" .previous");


#define PRINT_OPERAND_PUNCT_VALID_P(CODE) (code == '#')

/* Calling convention definitions. */
Expand Down

0 comments on commit 58c41c6

Please sign in to comment.