Closed Bug 474904 Opened 16 years ago Closed 2 years ago

freebl MPI performance enhancements for Darwin on x86

Categories

(NSS :: Libraries, enhancement, P3)

x86
macOS
enhancement

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: nelson, Unassigned)

Details

Attachments

(1 file)

NSS's MPI has assembly language optimizations for X86 CPUs on numerous OSes, but not for Darwin. This RFE asks that those optimizations be made available for Darwin, too. A patch to accomplish that has been submitted to the dev-tech-crypto mailing list by one Jean-Daniel <jddupas@gmail.com>. He wrote: > The new asm file does not try to determine at runtime if SSE2 is > present, but it does it at compile time. > By default the Apple GCC version define __SSE2__, so the default is to > use it on Mac. > And as mention before, all supported Mac have a processor with SSE2 > available, so it should be fine. > Else, this is a simple copy/paste of the Linux version (without > the .type lines, as the Darwin assembler does not like them).
I got an account on a OSX system and tried to build NSS with this patch. The build barfed on the new .s file. The command line that tried to build it was: cc -o Darwin9.6.0_DBG.OBJ/Darwin_SINGLE_SHLIB/mpi_x86-darwin.o -g -fPIC -Di386 -Wmost -fpascal-strings -fno-common -pipe -DDARWIN -DHAVE_STRERROR -DHAVE_BSD_FLOCK -DXP_UNIX -DSHLIB_SUFFIX=\"dylib\" -DSHLIB_PREFIX=\"lib\" -DSHLIB_VERSION=\"3\" -DSOFTOKEN_SHLIB_VERSION=\"3\" -DRIJNDAEL_INCLUDE_TABLES -DDEBUG -UNDEBUG -DDEBUG_nb95248 -DNSS_ENABLE_ECC -DNSS_ECC_MORE_THAN_SUITE_B -DUSE_UTIL_DIRECTLY -DMP_USE_UINT_DIGIT -DMP_ASSEMBLY_MULTIPLY -DMP_ASSEMBLY_SQUARE -DMP_ASSEMBLY_DIV_2DX1D -DMP_CHAR_STORE_SLOW -DMP_IS_LITTLE_ENDIAN -DMP_API_COMPATIBLE -I../../../../dist/Darwin9.6.0_DBG.OBJ/include -I../../../../dist/public/nss -I../../../../dist/private/nss -Impi -Iecl -c mpi/mpi_x86-darwin.s The error messages were all similar to these: mpi/mpi_x86-darwin.s:204:junk `f' after expression mpi/mpi_x86-darwin.s:207:Spurious digit 1. mpi/mpi_x86-darwin.s:207:Rest of line ignored. 1st junk character valued 53 (5).mpi/mpi_x86-darwin.s:218:junk `b' after expression mpi/mpi_x86-darwin.s:219:Spurious digit 1. mpi/mpi_x86-darwin.s:219:Rest of line ignored. 1st junk character valued 54 (6).mpi/mpi_x86-darwin.s:305:junk `f' after expression mpi/mpi_x86-darwin.s:308:Spurious digit 2. mpi/mpi_x86-darwin.s:308:Rest of line ignored. 1st junk character valued 53 (5). It complained about "junk after expression" for all the jump instructions, where the target labels had an 'f' or 'b' suffix. It complained about "Spurious digit" for all the lines with labels, e.g., 14: This was Darwin 9.6.0 running gcc 4.0.
This bug is a duplicate of bug 333601.
Severity: normal → S3
Severity: S3 → S4
Status: NEW → RESOLVED
Closed: 2 years ago
Priority: -- → P3
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: