Skip to content

Commit

Permalink
Bug 1500154 - Link with -Bsymbolic-functions whenever possible. r=gla…
Browse files Browse the repository at this point in the history
…ndium

This speeds up calls within libxul by avoiding PLT jumps.

Differential Revision: https://phabricator.services.mozilla.com/D9686
  • Loading branch information
mbrubeck committed Oct 26, 2018
1 parent d4c1b0c commit b7eb142
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
7 changes: 7 additions & 0 deletions js/src/old-configure.in
Original file line number Diff line number Diff line change
Expand Up @@ -485,6 +485,13 @@ if test "$GNU_CC"; then
AC_MSG_RESULT([no])
LDFLAGS=$_SAVE_LDFLAGS)

AC_MSG_CHECKING([for -Bsymbolic-functions option to ld])
_SAVE_LDFLAGS=$LDFLAGS
LDFLAGS="$LDFLAGS -Wl,-Bsymbolic-functions"
AC_TRY_LINK(,,AC_MSG_RESULT([yes]),
AC_MSG_RESULT([no])
LDFLAGS=$_SAVE_LDFLAGS)

AC_MSG_CHECKING([for --build-id=sha1 option to ld])
_SAVE_LDFLAGS=$LDFLAGS
LDFLAGS="$LDFLAGS -Wl,--build-id=sha1"
Expand Down
7 changes: 7 additions & 0 deletions old-configure.in
Original file line number Diff line number Diff line change
Expand Up @@ -518,6 +518,13 @@ if test "$GNU_CC"; then
AC_MSG_RESULT([no])
LDFLAGS=$_SAVE_LDFLAGS)

AC_MSG_CHECKING([for -Bsymbolic-functions option to ld])
_SAVE_LDFLAGS=$LDFLAGS
LDFLAGS="$LDFLAGS -Wl,-Bsymbolic-functions"
AC_TRY_LINK(,,AC_MSG_RESULT([yes]),
AC_MSG_RESULT([no])
LDFLAGS=$_SAVE_LDFLAGS)

AC_MSG_CHECKING([for --build-id=sha1 option to ld])
_SAVE_LDFLAGS=$LDFLAGS
LDFLAGS="$LDFLAGS -Wl,--build-id=sha1"
Expand Down

0 comments on commit b7eb142

Please sign in to comment.