[Bug ld/23854] -no-pie -export-dynamic corrupts binary

2018-11-05 Thread stsp at users dot sourceforge.net
https://sourceware.org/bugzilla/show_bug.cgi?id=23854 --- Comment #9 from Stas Sergeev --- (In reply to H.J. Lu from comment #6) > Please provide pre-processed dpmi.c from gcc -E and command-line > options to generate dpmi.s gcc -xc -S -fverbose-asm -O -o dpmi.s dpmi.E gcc version 7.3.0 (Ubuntu

[Bug ld/23854] -no-pie -export-dynamic corrupts binary

2018-11-05 Thread stsp at users dot sourceforge.net
https://sourceware.org/bugzilla/show_bug.cgi?id=23854 --- Comment #8 from Stas Sergeev --- Created attachment 11381 --> https://sourceware.org/bugzilla/attachment.cgi?id=11381=edit preprocessed output -- You are receiving this mail because: You are on the CC list for the bug.

[Bug ld/23854] -no-pie -export-dynamic corrupts binary

2018-11-05 Thread stsp at users dot sourceforge.net
https://sourceware.org/bugzilla/show_bug.cgi?id=23854 --- Comment #7 from Stas Sergeev --- Created attachment 11379 --> https://sourceware.org/bugzilla/attachment.cgi?id=11379=edit verbose asm > Please provide pre-processed dpmi.c from gcc -E and command-line > options to generate dpmi.s

[Bug ld/23854] -no-pie -export-dynamic corrupts binary

2018-11-04 Thread hjl.tools at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=23854 --- Comment #6 from H.J. Lu --- Please provide pre-processed dpmi.c from gcc -E and command-line options to generate dpmi.s -- You are receiving this mail because: You are on the CC list for the bug.

[Bug ld/23854] -no-pie -export-dynamic corrupts binary

2018-11-04 Thread stsp at users dot sourceforge.net
https://sourceware.org/bugzilla/show_bug.cgi?id=23854 --- Comment #5 from Stas Sergeev --- Basically this code calculates the distance between "DPMI_return_from_realmode" and "DPMI_dummy_start", and puts the result into a 16bit variable. That explains the use of %ax. Its possible because those

[Bug ld/23854] -no-pie -export-dynamic corrupts binary

2018-11-04 Thread stsp at users dot sourceforge.net
https://sourceware.org/bugzilla/show_bug.cgi?id=23854 --- Comment #4 from Stas Sergeev --- (In reply to H.J. Lu from comment #3) > do_dpmi_int has Ah, I see now what you mean. > 8f69: 8b 83 00 00 00 00 mov0x0(%ebx),%eax 8f6b: > R_386_GOT32X DPMI_return_from_realmode >

[Bug ld/23854] -no-pie -export-dynamic corrupts binary

2018-11-04 Thread hjl.tools at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=23854 --- Comment #3 from H.J. Lu --- (In reply to Stas Sergeev from comment #2) > (In reply to H.J. Lu from comment #1) > > dpmi.o has: > > > > 8f69: 8b 83 00 00 00 00 mov0x0(%ebx),%eax 8f6b: > > R_386_GOT32X

[Bug ld/23854] -no-pie -export-dynamic corrupts binary

2018-11-04 Thread stsp at users dot sourceforge.net
https://sourceware.org/bugzilla/show_bug.cgi?id=23854 --- Comment #2 from Stas Sergeev --- (In reply to H.J. Lu from comment #1) > dpmi.o has: > > 8f69: 8b 83 00 00 00 00 mov0x0(%ebx),%eax 8f6b: > R_386_GOT32X DPMI_return_from_realmode > 8f6f: 66 05 00 48

[Bug ld/23854] -no-pie -export-dynamic corrupts binary

2018-11-04 Thread hjl.tools at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=23854 H.J. Lu changed: What|Removed |Added Status|UNCONFIRMED |WAITING Last reconfirmed|