diff options
author | Tor Lillqvist <tlillqvist@novell.com> | 2011-01-22 03:20:19 +0200 |
---|---|---|
committer | Tor Lillqvist <tlillqvist@novell.com> | 2011-01-22 03:20:19 +0200 |
commit | 28787edbd8a6bc1e3a6486d42f316cc54a7ff0e3 (patch) | |
tree | cda3dd17bb6969d517e1700d95ad7a677de5c91b /bridges/source/cpp_uno/msvc_win32_x86-64/cpp2uno.cxx | |
parent | 525f7823d6f4b9bc625bc8c99be6683b11d46d48 (diff) |
More hacking on the C++-UNO bridge for x64 Windows
I think I might actually be able to manage without any assembly coding
here, thanks to the clean design of the x64 Windows calling
convention, and tricking the compiler (in a fully documented and
stable way) by using varargs. uno2cpp.cxx might even be getting close
to working now, but cpp2uno.cxx and except.cxx parts are just forced
to compile by using dummy code.
Diffstat (limited to 'bridges/source/cpp_uno/msvc_win32_x86-64/cpp2uno.cxx')
-rw-r--r-- | bridges/source/cpp_uno/msvc_win32_x86-64/cpp2uno.cxx | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/bridges/source/cpp_uno/msvc_win32_x86-64/cpp2uno.cxx b/bridges/source/cpp_uno/msvc_win32_x86-64/cpp2uno.cxx index d3a445bed2c1..41f46c352b59 100644 --- a/bridges/source/cpp_uno/msvc_win32_x86-64/cpp2uno.cxx +++ b/bridges/source/cpp_uno/msvc_win32_x86-64/cpp2uno.cxx @@ -362,6 +362,8 @@ extern void *cpp_vtable_call; //================================================================================================== int const codeSnippetSize = 28; +#if 0 + unsigned char * codeSnippet( unsigned char * code, sal_Int32 functionIndex, sal_Int32 vtableOffset) { @@ -383,6 +385,8 @@ unsigned char * codeSnippet( return code + codeSnippetSize; } +#endif + } struct bridges::cpp_uno::shared::VtableFactory::Slot { void * fn; }; @@ -420,6 +424,17 @@ bridges::cpp_uno::shared::VtableFactory::initializeBlock( return slots + slotCount; } +#if 0 + +#else + +static void whatthefuck(sal_Int64 i, ...) +{ + +} + +#endif + unsigned char * bridges::cpp_uno::shared::VtableFactory::addLocalFunctions( Slot ** slots, unsigned char * code, typelib_InterfaceTypeDescription const *, sal_Int32 functionOffset, @@ -428,8 +443,12 @@ unsigned char * bridges::cpp_uno::shared::VtableFactory::addLocalFunctions( (*slots) -= functionCount; Slot * s = *slots; for (sal_Int32 i = 0; i < functionCount; ++i) { +#if 0 (s++)->fn = code; code = codeSnippet(code, functionOffset++, vtableOffset); +#else + (s++)->fn = whatthefuck; +#endif } return code; } |