[PATCH 0/1] MR3126: configure: Build x86_64 PE code with mcmodel=small.
Saving a huge number of .refptr indirections for all extern symbols. Proton is using this for a while now. -- https://gitlab.winehq.org/wine/wine/-/merge_requests/3126
From: Rémi Bernon <rbernon(a)codeweavers.com> Saving a huge number of .refptr indirections for all extern symbols. --- configure.ac | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index bed7b2dec28..606be62632e 100644 --- a/configure.ac +++ b/configure.ac @@ -960,7 +960,8 @@ do [AS_VAR_APPEND([${wine_arch}_LDFLAGS],[" -Wl,--disable-stdcall-fixup"])]) ;; x86_64) WINE_TRY_PE_CFLAGS([-Wformat-overflow]) WINE_TRY_PE_CFLAGS([-Wnonnull]) - WINE_TRY_PE_CFLAGS([-mcx16]) ;; + WINE_TRY_PE_CFLAGS([-mcx16]) + WINE_TRY_PE_CFLAGS([-mcmodel=small]) ;; esac dnl Determine debug info format -- GitLab https://gitlab.winehq.org/wine/wine/-/merge_requests/3126
That assumes all code will be mapped in the lower 2 GiB, I don't think we want that requirement? -- https://gitlab.winehq.org/wine/wine/-/merge_requests/3126#note_36508
On Wed Jun 21 16:22:38 2023 +0000, Zebediah Figura wrote:
That assumes all code will be mapped in the lower 2 GiB, I don't think we want that requirement? It's only a requirement for the pseudo-GOT that MinGW generates for its unix-like auto exported symbols feature, we use explicit exported symbols with import and export tables which support absolute addresses.
-- https://gitlab.winehq.org/wine/wine/-/merge_requests/3126#note_36509
participants (2)
-
Rémi Bernon -
Zebediah Figura (@zfigura)