Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
R
riscv-gcc-1
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
riscv-gcc-1
Commits
b335c2cc
Commit
b335c2cc
authored
Mar 19, 1992
by
Tom Wood
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
*** empty log message ***
From-SVN: r526
parent
d742f26c
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
164 additions
and
68 deletions
+164
-68
gcc/config/i386/sysv3.h
+11
-14
gcc/config/m88k/sysv3.h
+69
-31
gcc/config/svr3.h
+10
-10
gcc/crtstuff.c
+25
-4
gcc/function.c
+12
-6
gcc/libgcc2.c
+37
-3
No files found.
gcc/config/i386/sysv3.h
View file @
b335c2cc
...
@@ -99,26 +99,23 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
...
@@ -99,26 +99,23 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
#define FRAME_POINTER_REQUIRED \
#define FRAME_POINTER_REQUIRED \
(current_function_calls_setjmp || current_function_calls_longjmp)
(current_function_calls_setjmp || current_function_calls_longjmp)
/* Define a few machine-specific details
/* Define a few machine-specific details
of the implementation of
of the implementation of
constructors.
constructors.
CTORS_SECTION_ASM_OP should be defined to concatenate
The __CTORS_LIST__ goes in the .init section. Define CTOR_LIST_BEGIN
the macro INIT_SECTION_ASM_OP, a newline, and a push instruction
and CTOR_LIST_END to contribute to the .init section an instruction to
to
push a word containing 0 (or some equivalent of that).
push a word containing 0 (or some equivalent of that).
ASM_OUTPUT_CONSTRUCTOR should be defined
ASM_OUTPUT_CONSTRUCTOR should be defined
to push the address of the
to push the address of the
constructor. */
constructor. */
#undef INIT_SECTION_ASM_OP
#undef INIT_SECTION_ASM_OP
#define INIT_SECTION_ASM_OP ".section .init,\"x\""
#define INIT_SECTION_ASM_OP ".section .init,\"x\""
#define CTORS_SECTION_ASM_OP \
#define CTOR_LIST_BEGIN \
INIT_SECTION_ASM_OP "\n" \
asm (INIT_SECTION_ASM_OP); \
"\tpushl $0\n\t" \
asm ("pushl $0")
DATA_SECTION_ASM_OP
#define CTOR_LIST_END CTOR_LIST_BEGIN
/* The reason we end with DATA_SECTION_ASM_OP is to prevent the
initial and final table elements (see crtstuff.c) from getting into
the .init section and causing a crash. */
#define ASM_OUTPUT_CONSTRUCTOR(FILE,NAME) \
#define ASM_OUTPUT_CONSTRUCTOR(FILE,NAME) \
do { \
do { \
...
...
gcc/config/m88k/sysv3.h
View file @
b335c2cc
...
@@ -59,15 +59,38 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
...
@@ -59,15 +59,38 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
#undef USE_LIBG
#undef USE_LIBG
#define USE_LIBG
#define USE_LIBG
/* Define a few machine-specific details
/* Define a few machine-specific details of the implementation of
of the implementation of constructors.
constructors. */
CTORS_SECTION_ASM_OP should be defined to concatenate
/* Although the .init section is used, it is not automatically invoked. */
the macro INIT_SECTION_ASM_OP, a newline, and a push instruction
#define INVOKE__main
to push a word containing 0 (or some equivalent of that).
/* State that atexit exists so __do_global_ctors will register
ASM_OUTPUT_CONSTRUCTOR should be defined
__do_global_dtors. */
to push the address of the constructor. */
#define HAVE_ATEXIT
#if (STACK_BOUNDARY / BITS_PER_UNIT) == 16 && REG_PARM_STACK_SPACE (0) == 32
#define CTOR_LIST_BEGIN \
asm (INIT_SECTION_ASM_OP); \
asm ("\tsubu\t r31,r31,16"); \
asm ("\tst\t r0,r31,32");
#define CTOR_LIST_END
#endif
/* ASM_OUTPUT_CONSTRUCTOR outputs code into the .init section to push the
address of the constructor. This becomes the body of __do_global_ctors
in crtstuff.c. r13 is a temporary register. */
#undef ASM_OUTPUT_CONSTRUCTOR
#define ASM_OUTPUT_CONSTRUCTOR(FILE,NAME) \
do { \
init_section (); \
fprintf (FILE, "\tor.u\t r13,r0,hi16("); \
assemble_name (FILE, NAME); \
fprintf (FILE, ")\n\tor\t r13,r13,lo16("); \
assemble_name (FILE, NAME); \
fprintf (FILE, ")\n\tsubu\t r31,r31,%d\n\tst\t r13,r31,%d\n", \
STACK_BOUNDARY / BITS_PER_UNIT, REG_PARM_STACK_SPACE (0)); \
} while (0)
#undef DO_GLOBAL_CTORS_BODY
#undef DO_GLOBAL_CTORS_BODY
#define DO_GLOBAL_CTORS_BODY \
#define DO_GLOBAL_CTORS_BODY \
...
@@ -77,26 +100,41 @@ do { \
...
@@ -77,26 +100,41 @@ do { \
(*p) (); \
(*p) (); \
} while (0)
} while (0)
#undef CTORS_SECTION_ASM_OP
#define DTOR_LIST_BEGIN \
#define CTORS_SECTION_ASM_OP \
asm (FINI_SECTION_ASM_OP); \
INIT_SECTION_ASM_OP "\n" \
func_ptr __DTOR_LIST__[4] = { (func_ptr) (-1), (func_ptr) (-1), \
"subu\t r31,r31,16\n\tst\t r0,r31,32\n\t" \
(func_ptr) (-1), (func_ptr) (-1) }
DATA_SECTION_ASM_OP
#define DTOR_LIST_END \
asm (FINI_SECTION_ASM_OP); \
/* The reason we end with DATA_SECTION_ASM_OP is to prevent the
func_ptr __DTOR_END__[4] = { (func_ptr) 0, (func_ptr) 0, \
initial and final table elements (see crtstuff.c) from getting into
(func_ptr) 0, (func_ptr) 0 }
the .init section and causing a crash. */
/* A C statement (sans semicolon) to output an element in the table of
#undef ASM_OUTPUT_CONSTRUCTOR
global destructors. The table is constructed in the .fini section
#define ASM_OUTPUT_CONSTRUCTOR(FILE,NAME) \
so that an explicit linker script is not required. The complication
is that this section is padded with NOP instructions and to either
8 or 16 byte alignment depending on the specific system. A clever
way to avoid trouble is to output a block of 16 bytes where the
extra words are known values (-1). */
#undef ASM_OUTPUT_DESTRUCTOR
#define ASM_OUTPUT_DESTRUCTOR(FILE,NAME) \
do { \
do { \
init_section (); \
register int i; \
fprintf (FILE, "\tor.u r13,r0,hi16("); \
fini_section (); \
assemble_name (FILE, NAME); \
fprintf (FILE, "\t%s\t ", ASM_LONG); \
fprintf (FILE, ")\nor\t r13,r13,lo16("); \
assemble_name (FILE,NAME); \
assemble_name (FILE, NAME); \
fprintf (FILE, "\n"); \
fprintf (FILE, ")\n\tsubu r31,r31,16\nst\t r13,r31,32\n"); \
for (i = 1; i < 4; i++) \
} while (0)
fprintf (FILE, "\t%s\t -1\n", ASM_LONG); \
} while (0)
#undef DTORS_SECTION_ASM_OP
#define DTORS_SECTION_ASM_OP FINI_SECTION_ASM_OP
/* Walk the list looking for the terminating zero and ignoring all values of
-1. */
#undef DO_GLOBAL_DTORS_BODY
#define DO_GLOBAL_DTORS_BODY \
do { \
int i; \
for (i = 0; __DTOR_LIST__[i] != 0; i++) \
if (((int *)__DTOR_LIST__)[i] != -1) \
__DTOR_LIST__[i] (); \
} while (0)
gcc/config/svr3.h
View file @
b335c2cc
...
@@ -172,25 +172,25 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
...
@@ -172,25 +172,25 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
unless the specific tm.h file turns it on by defining
unless the specific tm.h file turns it on by defining
USE_CONST_SECTION as 1. */
USE_CONST_SECTION as 1. */
/*
The support for constructors and destructors depends on two
/*
Define a few machine-specific details of the implementation of
machine-specific macros that the individual tm.h file has to define:
constructors.
CTORS_SECTION_ASM_OP should be defined to concatenate
The __CTORS_LIST__ goes in the .init section. Define CTOR_LIST_BEGIN
the macro INIT_SECTION_ASM_OP, a newline, and a push instruction
and CTOR_LIST_END to contribute to the .init section an instruction to
to
push a word containing 0 (or some equivalent of that).
push a word containing 0 (or some equivalent of that).
ASM_OUTPUT_CONSTRUCTOR should be defined
Define ASM_OUTPUT_CONSTRUCTOR to push the address of the constructor. */
to push the address of the constructor. */
#define USE_CONST_SECTION 0
#define USE_CONST_SECTION 0
#define INIT_SECTION_ASM_OP ".section\t.init"
#define INIT_SECTION_ASM_OP ".section\t.init"
#define FINI_SECTION_ASM_OP ".section .fini,\"x\""
#define FINI_SECTION_ASM_OP ".section .fini,\"x\""
#define CONST_SECTION_ASM_OP ".section\t.rodata, \"x\""
#define CONST_SECTION_ASM_OP ".section\t.rodata, \"x\""
#define CTORS_SECTION_ASM_OP INIT_SECTION_ASM_OP
#define DTORS_SECTION_ASM_OP FINI_SECTION_ASM_OP
#define DTORS_SECTION_ASM_OP FINI_SECTION_ASM_OP
/* CTORS_SECTION_ASM_OP is machine-dependent
because it pushes on the stack. */
/* CTOR_LIST_BEGIN and CTOR_LIST_END are machine-dependent
because they push on the stack. */
#define DO_GLOBAL_CTORS_BODY \
#define DO_GLOBAL_CTORS_BODY \
do { \
do { \
...
...
gcc/crtstuff.c
View file @
b335c2cc
...
@@ -69,8 +69,13 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
...
@@ -69,8 +69,13 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
#ifdef INIT_SECTION_ASM_OP
#ifdef INIT_SECTION_ASM_OP
/* Force cc1 to switch to .text section. */
/* The function __do_global_ctors_aux is compiled twice (once in crtbegin.o
static
void
force_to_text
()
{
}
and once in crtend.o). It must be declared static to aviod a link
error. Here, we define __do_global_ctors as an externally callable
function. It is externally callable so that __main can invoke it when
INVOKE__main is defined. This has the additional effect of forcing cc1
to switch to the .text section. */
void
__do_global_ctors
()
{
__do_global_ctors_aux
();
}
asm
(
INIT_SECTION_ASM_OP
);
/* cc1 doesn't know that we are switching! */
asm
(
INIT_SECTION_ASM_OP
);
/* cc1 doesn't know that we are switching! */
...
@@ -90,7 +95,7 @@ asm (INIT_SECTION_ASM_OP); /* cc1 doesn't know that we are switching! */
...
@@ -90,7 +95,7 @@ asm (INIT_SECTION_ASM_OP); /* cc1 doesn't know that we are switching! */
file-scope static-storage C++ objects within shared libraries. */
file-scope static-storage C++ objects within shared libraries. */
static
void
static
void
__do_global_ctors
()
/* prologue goes in .init section */
__do_global_ctors
_aux
()
/* prologue goes in .init section */
{
{
asm
(
TEXT_SECTION_ASM_OP
);
/* don't put epilogue and body in .init */
asm
(
TEXT_SECTION_ASM_OP
);
/* don't put epilogue and body in .init */
DO_GLOBAL_CTORS_BODY
;
DO_GLOBAL_CTORS_BODY
;
...
@@ -104,11 +109,19 @@ static func_ptr force_to_data[0] = { };
...
@@ -104,11 +109,19 @@ static func_ptr force_to_data[0] = { };
/* The -1 is a flag to __do_global_[cd]tors
/* The -1 is a flag to __do_global_[cd]tors
indicating that this table does not start with a count of elements. */
indicating that this table does not start with a count of elements. */
#ifdef CTOR_LIST_BEGIN
CTOR_LIST_BEGIN
;
#else
asm
(
CTORS_SECTION_ASM_OP
);
/* cc1 doesn't know that we are switching! */
asm
(
CTORS_SECTION_ASM_OP
);
/* cc1 doesn't know that we are switching! */
func_ptr
__CTOR_LIST__
[
1
]
=
{
(
func_ptr
)
(
-
1
)
};
func_ptr
__CTOR_LIST__
[
1
]
=
{
(
func_ptr
)
(
-
1
)
};
#endif
#ifdef DTOR_LIST_BEGIN
DTOR_LIST_BEGIN
;
#else
asm
(
DTORS_SECTION_ASM_OP
);
/* cc1 doesn't know that we are switching! */
asm
(
DTORS_SECTION_ASM_OP
);
/* cc1 doesn't know that we are switching! */
func_ptr
__DTOR_LIST__
[
1
]
=
{
(
func_ptr
)
(
-
1
)
};
func_ptr
__DTOR_LIST__
[
1
]
=
{
(
func_ptr
)
(
-
1
)
};
#endif
#endif
/* defined(CRT_BEGIN) */
#endif
/* defined(CRT_BEGIN) */
...
@@ -129,7 +142,7 @@ func_ptr __DTOR_LIST__[1] = { (func_ptr) (-1) };
...
@@ -129,7 +142,7 @@ func_ptr __DTOR_LIST__[1] = { (func_ptr) (-1) };
*/
*/
static
void
static
void
__do_global_ctors
()
/* prologue goes in .text section */
__do_global_ctors
_aux
()
/* prologue goes in .text section */
{
{
asm
(
INIT_SECTION_ASM_OP
);
asm
(
INIT_SECTION_ASM_OP
);
DO_GLOBAL_CTORS_BODY
;
DO_GLOBAL_CTORS_BODY
;
...
@@ -141,10 +154,18 @@ __do_global_ctors () /* prologue goes in .text section */
...
@@ -141,10 +154,18 @@ __do_global_ctors () /* prologue goes in .text section */
/* Force cc1 to switch to .data section. */
/* Force cc1 to switch to .data section. */
static
func_ptr
force_to_data
[
0
]
=
{
};
static
func_ptr
force_to_data
[
0
]
=
{
};
#ifdef CTOR_LIST_END
CTOR_LIST_END
;
#else
asm
(
CTORS_SECTION_ASM_OP
);
/* cc1 doesn't know that we are switching! */
asm
(
CTORS_SECTION_ASM_OP
);
/* cc1 doesn't know that we are switching! */
func_ptr
__CTOR_END__
[
1
]
=
{
(
func_ptr
)
0
};
func_ptr
__CTOR_END__
[
1
]
=
{
(
func_ptr
)
0
};
#endif
#ifdef DTOR_LIST_END
DTOR_LIST_END
;
#else
asm
(
DTORS_SECTION_ASM_OP
);
/* cc1 doesn't know that we are switching! */
asm
(
DTORS_SECTION_ASM_OP
);
/* cc1 doesn't know that we are switching! */
func_ptr
__DTOR_END__
[
1
]
=
{
(
func_ptr
)
0
};
func_ptr
__DTOR_END__
[
1
]
=
{
(
func_ptr
)
0
};
#endif
#endif
/* defined(CRT_END) */
#endif
/* defined(CRT_END) */
gcc/function.c
View file @
b335c2cc
...
@@ -1028,7 +1028,7 @@ fixup_var_refs_insns (var, insn, toplevel)
...
@@ -1028,7 +1028,7 @@ fixup_var_refs_insns (var, insn, toplevel)
/* We can not separate USE insns from the CALL_INSN
/* We can not separate USE insns from the CALL_INSN
that they belong to. If this is a CALL_INSN, insert
that they belong to. If this is a CALL_INSN, insert
the move insn before the USE insns prece
e
ding it
the move insn before the USE insns preceding it
instead of immediately before the insn. */
instead of immediately before the insn. */
if
(
GET_CODE
(
insn
)
==
CALL_INSN
)
if
(
GET_CODE
(
insn
)
==
CALL_INSN
)
{
{
...
@@ -1904,7 +1904,7 @@ instantiate_decls (fndecl, valid_only)
...
@@ -1904,7 +1904,7 @@ instantiate_decls (fndecl, valid_only)
if
(
DECL_RTL
(
decl
)
&&
GET_CODE
(
DECL_RTL
(
decl
))
==
MEM
)
if
(
DECL_RTL
(
decl
)
&&
GET_CODE
(
DECL_RTL
(
decl
))
==
MEM
)
instantiate_virtual_regs_1
(
&
XEXP
(
DECL_RTL
(
decl
),
0
),
instantiate_virtual_regs_1
(
&
XEXP
(
DECL_RTL
(
decl
),
0
),
valid_only
?
DECL_RTL
(
decl
)
:
0
,
0
);
valid_only
?
DECL_RTL
(
decl
)
:
0
,
0
);
#if
0
/* This is probably correct, but it seems to require fixes
#if
1
/* This is probably correct, but it seems to require fixes
elsewhere in order to work. Let's fix them in 2.1. */
elsewhere in order to work. Let's fix them in 2.1. */
if
(
DECL_INCOMING_RTL
(
decl
)
if
(
DECL_INCOMING_RTL
(
decl
)
&&
GET_CODE
(
DECL_INCOMING_RTL
(
decl
))
==
MEM
)
&&
GET_CODE
(
DECL_INCOMING_RTL
(
decl
))
==
MEM
)
...
@@ -2167,7 +2167,7 @@ instantiate_virtual_regs_1 (loc, object, extra_insns)
...
@@ -2167,7 +2167,7 @@ instantiate_virtual_regs_1 (loc, object, extra_insns)
/* Most cases of MEM that convert to valid addresses have already been
/* Most cases of MEM that convert to valid addresses have already been
handled by our scan of regno_reg_rtx. The only special handling we
handled by our scan of regno_reg_rtx. The only special handling we
need here is to make a copy of the rtx to ensure it isn't being
need here is to make a copy of the rtx to ensure it isn't being
shared if we have to change it to a ps
ue
do.
shared if we have to change it to a ps
eu
do.
If the rtx is a simple reference to an address via a virtual register,
If the rtx is a simple reference to an address via a virtual register,
it can potentially be shared. In such cases, first try to make it
it can potentially be shared. In such cases, first try to make it
...
@@ -2778,7 +2778,7 @@ assign_parms (fndecl, second_time)
...
@@ -2778,7 +2778,7 @@ assign_parms (fndecl, second_time)
#if 0 /* This change was turned off because it makes compilation bigger. */
#if 0 /* This change was turned off because it makes compilation bigger. */
!optimize
!optimize
#else
/* It's not clear why the following was replaced. */
#else
/* It's not clear why the following was replaced. */
/* Obsoleted by prece
e
ding line. */
/* Obsoleted by preceding line. */
(
obey_regdecls
&&
!
TREE_REGDECL
(
parm
)
(
obey_regdecls
&&
!
TREE_REGDECL
(
parm
)
&&
!
TREE_INLINE
(
fndecl
))
&&
!
TREE_INLINE
(
fndecl
))
#endif
#endif
...
@@ -3212,6 +3212,12 @@ setjmp_protect (block)
...
@@ -3212,6 +3212,12 @@ setjmp_protect (block)
||
TREE_CODE
(
decl
)
==
PARM_DECL
)
||
TREE_CODE
(
decl
)
==
PARM_DECL
)
&&
DECL_RTL
(
decl
)
!=
0
&&
DECL_RTL
(
decl
)
!=
0
&&
GET_CODE
(
DECL_RTL
(
decl
))
==
REG
&&
GET_CODE
(
DECL_RTL
(
decl
))
==
REG
/* If this variable came from an inline function, it must be
that it's life doesn't overlap the setjmp. If there was a
setjmp in the function, it would already be in memory. We
must exclude such variable because their DECL_RTL might be
set to strange things such as virtual_stack_vars_rtx. */
&&
!
DECL_FROM_INLINE
(
decl
)
&&
(
&&
(
#ifdef NON_SAVING_SETJMP
#ifdef NON_SAVING_SETJMP
/* If longjmp doesn't restore the registers,
/* If longjmp doesn't restore the registers,
...
@@ -3623,10 +3629,10 @@ mark_varargs ()
...
@@ -3623,10 +3629,10 @@ mark_varargs ()
void
void
expand_main_function
()
expand_main_function
()
{
{
#if
ndef INIT_SECTION_ASM_OP
#if
!defined (INIT_SECTION_ASM_OP) || defined (INVOKE__main)
emit_library_call
(
gen_rtx
(
SYMBOL_REF
,
Pmode
,
"__main"
),
0
,
emit_library_call
(
gen_rtx
(
SYMBOL_REF
,
Pmode
,
"__main"
),
0
,
VOIDmode
,
0
);
VOIDmode
,
0
);
#endif
/* not INIT_SECTION_ASM_OP */
#endif
/* not INIT_SECTION_ASM_OP
or INVOKE__main
*/
}
}
/* Start the RTL for a new function, and set variables used for
/* Start the RTL for a new function, and set variables used for
...
...
gcc/libgcc2.c
View file @
b335c2cc
...
@@ -29,7 +29,9 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
...
@@ -29,7 +29,9 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
do not apply. */
do not apply. */
#include "tm.h"
#include "tm.h"
#ifndef L_trampoline
#include "gstddef.h"
#include "gstddef.h"
#endif
/* Don't use `fancy_abort' here even if config.h says to use it. */
/* Don't use `fancy_abort' here even if config.h says to use it. */
#ifdef abort
#ifdef abort
...
@@ -864,8 +866,13 @@ asm ("__builtin_saveregs:");
...
@@ -864,8 +866,13 @@ asm ("__builtin_saveregs:");
#endif
/* not SVR4 */
#endif
/* not SVR4 */
#else
/* not __i860__ */
#else
/* not __i860__ */
#ifdef __sparc__
#ifdef __sparc__
#ifdef NO_UNDERSCORES
asm
(
".global __builtin_saveregs"
);
asm
(
"__builtin_saveregs:"
);
#else
asm
(
".global ___builtin_saveregs"
);
asm
(
".global ___builtin_saveregs"
);
asm
(
"___builtin_saveregs:"
);
asm
(
"___builtin_saveregs:"
);
#endif
asm
(
"st %i0,[%fp+68]"
);
asm
(
"st %i0,[%fp+68]"
);
asm
(
"st %i1,[%fp+72]"
);
asm
(
"st %i1,[%fp+72]"
);
asm
(
"st %i2,[%fp+76]"
);
asm
(
"st %i2,[%fp+76]"
);
...
@@ -1219,6 +1226,31 @@ __enable_execute_stack ()
...
@@ -1219,6 +1226,31 @@ __enable_execute_stack ()
asm
(
"pich"
);
asm
(
"pich"
);
}
}
#endif
/* __convex__ */
#endif
/* __convex__ */
#ifdef __pyr__
#include <stdio.h>
#include <sys/mman.h>
#include <sys/types.h>
#include <sys/param.h>
#include <sys/vmmac.h>
/* Modified from the convex -code above.
mremap promises to clear the i-cache. */
void
__enable_execute_stack
()
{
int
fp
;
if
(
mprotect
(((
unsigned
int
)
&
fp
/
PAGSIZ
)
*
PAGSIZ
,
PAGSIZ
,
PROT_READ
|
PROT_WRITE
|
PROT_EXEC
))
{
perror
(
"mprotect in __enable_execute_stack"
);
fflush
(
stderr
);
abort
();
}
}
#endif
/* __pyr__ */
#endif
/* L_trampoline */
#endif
/* L_trampoline */
#ifdef L__main
#ifdef L__main
...
@@ -1271,7 +1303,9 @@ __do_global_ctors ()
...
@@ -1271,7 +1303,9 @@ __do_global_ctors ()
DO_GLOBAL_CTORS_BODY
;
DO_GLOBAL_CTORS_BODY
;
ON_EXIT
(
__do_global_dtors
,
0
);
ON_EXIT
(
__do_global_dtors
,
0
);
}
}
#endif
/* no INIT_SECTION_ASM_OP */
#if !defined (INIT_SECTION_ASM_OP) || defined (INVOKE__main)
/* Subroutine called automatically by `main'.
/* Subroutine called automatically by `main'.
Compiling a global function named `main'
Compiling a global function named `main'
produces an automatic call to this function at the beginning.
produces an automatic call to this function at the beginning.
...
@@ -1291,7 +1325,7 @@ __main ()
...
@@ -1291,7 +1325,7 @@ __main ()
__do_global_ctors
();
__do_global_ctors
();
}
}
}
}
#endif
/* no INIT_SECTION_ASM_OP */
#endif
/* no INIT_SECTION_ASM_OP
or INVOKE__main
*/
#endif
/* L__main */
#endif
/* L__main */
...
@@ -1306,10 +1340,10 @@ __main ()
...
@@ -1306,10 +1340,10 @@ __main ()
/* We declare the lists here with two elements each,
/* We declare the lists here with two elements each,
so that they are valid empty lists if no other definition is loaded. */
so that they are valid empty lists if no other definition is loaded. */
#if
ndef INIT_SECTION_ASM_OP
#if
!defined(INIT_SECTION_ASM_OP) && !defined(CTOR_LISTS_DEFINED_EXTERNALLY)
func_ptr
__CTOR_LIST__
[
2
];
func_ptr
__CTOR_LIST__
[
2
];
func_ptr
__DTOR_LIST__
[
2
];
func_ptr
__DTOR_LIST__
[
2
];
#endif
/*
INIT_SECTION_ASM_OP
*/
#endif
/*
no INIT_SECTION_ASM_OP and not CTOR_LISTS_DEFINED_EXTERNALLY
*/
#ifndef ON_EXIT
#ifndef ON_EXIT
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment