Changeset 174682 in webkit for trunk/Source/JavaScriptCore/jit
- Timestamp:
- Oct 14, 2014, 9:25:25 AM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/jit/ThunkGenerators.cpp
r174503 r174682 806 806 extern "C" { \ 807 807 MathThunkCallingConvention function##Thunk(MathThunkCallingConvention); \ 808 } \ 809 static MathThunk UnaryDoubleOpWrapper(function) = &function##Thunk; 810 811 #elif CPU(X86) && COMPILER(MSVC) && OS(WINDOWS) 812 813 // MSVC does not accept floor, etc, to be called directly from inline assembly, so we need to wrap these functions. 814 static double (_cdecl *floorFunction)(double) = floor; 815 static double (_cdecl *ceilFunction)(double) = ceil; 816 static double (_cdecl *expFunction)(double) = exp; 817 static double (_cdecl *logFunction)(double) = log; 818 static double (_cdecl *jsRoundFunction)(double) = jsRound; 819 820 #define defineUnaryDoubleOpWrapper(function) \ 821 extern "C" __declspec(naked) MathThunkCallingConvention function##Thunk(MathThunkCallingConvention) \ 822 { \ 823 __asm \ 824 { \ 825 __asm sub esp, 20 \ 826 __asm movsd mmword ptr [esp], xmm0 \ 827 __asm call function##Function \ 828 __asm fstp qword ptr [esp] \ 829 __asm movsd xmm0, mmword ptr [esp] \ 830 __asm add esp, 20 \ 831 __asm ret \ 832 } \ 808 833 } \ 809 834 static MathThunk UnaryDoubleOpWrapper(function) = &function##Thunk;
Note:
See TracChangeset
for help on using the changeset viewer.