Commit ccb64b11 authored by Alexandre Julliard's avatar Alexandre Julliard

Store vtables in the data segment to avoid text relocations.

parent 71208770
...@@ -631,12 +631,13 @@ void * __stdcall MSVCRT_type_info_vector_dtor(type_info * _this, unsigned int fl ...@@ -631,12 +631,13 @@ void * __stdcall MSVCRT_type_info_vector_dtor(type_info * _this, unsigned int fl
/* vtables */ /* vtables */
#define __ASM_VTABLE(name,funcs) \ #define __ASM_VTABLE(name,funcs) \
__asm__(".align 4\n" \ __asm__(".data\n" \
"\t.align 4\n" \
"\t.long " __ASM_NAME(#name "_rtti") "\n" \ "\t.long " __ASM_NAME(#name "_rtti") "\n" \
"\t.globl " __ASM_NAME("MSVCRT_" #name "_vtable") "\n" \ "\t.globl " __ASM_NAME("MSVCRT_" #name "_vtable") "\n" \
__ASM_NAME("MSVCRT_" #name "_vtable") ":\n" \ __ASM_NAME("MSVCRT_" #name "_vtable") ":\n" \
"\t.long " THISCALL_NAME(MSVCRT_ ## name ## _vector_dtor) "\n" \ "\t.long " THISCALL_NAME(MSVCRT_ ## name ## _vector_dtor) "\n" \
funcs); funcs "\n\t.text");
#define __ASM_EXCEPTION_VTABLE(name) \ #define __ASM_EXCEPTION_VTABLE(name) \
__ASM_VTABLE(name, "\t.long " THISCALL_NAME(MSVCRT_what_exception) ); __ASM_VTABLE(name, "\t.long " THISCALL_NAME(MSVCRT_what_exception) );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment