similar to: [LLVMdev] Problem with code generated for call using stdcall convention

Displaying 20 results from an estimated 300 matches similar to: "[LLVMdev] Problem with code generated for call using stdcall convention"

2009 Dec 09
0
[LLVMdev] Problem with code generated for call using stdcall convention
Hello > Is the x86_stdcallcc call convention actually supported? I found it by > digging into LLVM sources Yes. It's fully supported. > Is my initial LLVM-IR correct for invoking WIN32 API function? No. You forgot to put calling convention on the call itself. -- With best regards, Anton Korobeynikov Faculty of Mathematics and Mechanics, Saint Petersburg State University
2017 Jun 04
2
trying to get a minimal windows program linked with lld
Here's some C code: extern void *GetStdHandle(unsigned int nStdHandle); extern void ExitProcess(unsigned int exit_code); extern char WriteFile(void *HANDLE, const void * lpBuffer, unsigned int nNumberOfBytesToWrite, unsigned int *lpNumberOfBytesWritten, void *lpOverlapped); static const char *message_ptr = "hello\n"; static const unsigned int message_len = 6;
2009 Dec 09
3
[LLVMdev] Problem with code generated for call using stdcall convention
2009/12/9 Anton Korobeynikov <anton at korobeynikov.info> > Hello > > Is my initial LLVM-IR correct for invoking WIN32 API function? > No. You forgot to put calling convention on the call itself. > Thanks, this work great! I naively though it would pick up the call convention from the declaration as there was no error like we have when the wrong number of parameters is
2017 Jun 04
2
trying to get a minimal windows program linked with lld
+ruiu and compnerd, since there might be an lld issue here. A slightly simpler example. This is all x86_64; I haven't tried x86. % cat imp.c __declspec(dllimport) void ExitProcess(unsigned exitCode); int mainCRTStartup() { ExitProcess(0); } % cat kernel32.def LIBRARY kernel32 EXPORTS ExitProcess % dlltool –d kernel32.def –l kernel32.lib % cl /Zl /c imp.c % link /subsystem:console imp.obj
2009 Jan 09
1
[LLVMdev] naked assembler / function written entirely in asm
Hi everybody. I'm having (yet) another look at trying to get naked functions from D (1) working in our LLVM D Compiler - LDC (2). I have this test case: /// D CODE /// extern(C) int printf(char*, ...); ulong retval() { asm { naked; mov EAX, 0xff; mov EDX, 0xaa; ret; } } ulong retval2() { return (cast(ulong)0xaa << 32) | 0xff; } void main() {
2009 Jan 13
2
My console app doesn't run in wine
Hi, Dunno wether it's a problem in my app or wine, so I thought I'd better post here first before going to bugzilla. So pardon me if I'm wrong here with this. I wrote a Win32 console app which runs without problems on at least Win98 and WinXP. If I start it by doubleclick it also seems to run fine in wine (as far as it runs as a console app started without any command line args ;) )
2001 May 16
1
wine-20010510 fails to run?
The system I am using is a clean install of Mandrake 8.0 which has the gcc version 2.96 installed. I downloaded the wine-20010510 snapshot and successfully ran the ./tools/wininstall. The build seems to have run without problems and if I type: wine --version the correct release number is displayed indicating the install was also succesful. As per the FAQ I also did the following:
2009 Jan 07
3
[LLVMdev] LLVM optmization
The following C test program was compiled using LLVM with -O3 option and MSVC with /O2. The MSVC one is about 600 times faster than the one compiled with the LLVM. We can see that the for loop in MSVC assembler is solved in the optimization pass more efficiently than that in LLVM. Is there an way to get a optimization result in LLVM like that of the MSVC? Manoel Teixeira #include
2001 Sep 04
0
AOL/Jr Monopoly game installer. Crash on exit
Hello all, have some free time and desided to help in wine tasting :-) With a pack of serials I recerived a CD with AOL trial installation and a game Monopoly Jr of company Hasbro Interactive Games (www.hasbro-interactive.com) and tried to install the game with Wine. One of the problems: when I run autorun.exe it brings main installer dialog. I click "Quit" button and the
2011 Aug 17
1
Foxpro File Copying causes Invalid Name warning
Using foxpro database application which should copy some files L1_*.dbf from a server location to the local c:\TEMP directory, but just get invalid name, perhaps I am not setting something correctly in winecfg? Here is WINEDEBUG output: 001b:Ret KERNEL32.WriteFile() retval=00000001 ret=7ea97433 001b:Call
2013 Feb 19
1
[LLVMdev] x86_stdcallcc and extra name mangling on Windows
Hi all, I'm currently working on getting our (LDC) compiler to run on Win32/MinGW, now that DW2-style EH is available for it. The D programming language has a feature equivalent to LLVM module level inline assembly, so we need to at least partly follow the x86 D calling convention (http://dlang.org/abi.html). Most notably, the ABI mandates that the callee cleans the stack. On the various
2017 Jun 14
2
Using LLD to create a .lib from a .def
I'm copying some LLD code into my codebase like this: // workaround for LLD not exposing ability to convert .def to .lib #include <set> namespace lld { namespace coff { class SymbolBody; class StringChunk; struct Symbol; struct Export { StringRef Name; // N in /export:N or /export:E=N StringRef ExtName; // E in /export:E=N SymbolBody *Sym = nullptr; uint16_t Ordinal
2017 Jun 15
2
Using LLD to create a .lib from a .def
On Wed, Jun 14, 2017 at 7:37 PM, Rui Ueyama <ruiu at google.com> wrote: > On Wed, Jun 14, 2017 at 4:24 PM, Andrew Kelley via llvm-dev < > llvm-dev at lists.llvm.org> wrote: > >> I'm copying some LLD code into my codebase like this: >> >> // workaround for LLD not exposing ability to convert .def to .lib >> >> #include <set> >>
2009 Dec 23
1
[LLVMdev] MinGW llvm-gcc --enable-stdcall-fixup error
When attempting to compile this simple testing tool http://github.com/oneclick/rubyinstaller/blob/fake/resources/tools/fakeruby.c I get the following: C:\Users\Jon\Documents\CDev\sandbox>llvm-gcc -Wall -o fakeruby.exe fakeruby.c Warning: resolving _GetModuleHandleA by linking to _GetModuleHandleA at 4 Use --enable-stdcall-fixup to disable these warnings Use --disable-stdcall-fixup to disable
2017 Jun 16
2
Using LLD to create a .lib from a .def
I saw this change come in yesterday: commit 572ad839e2f66eaa82ffc71b1061eb3d06a4d126 Author: Saleem Abdulrasool <compnerd at compnerd.org> Date: Thu Jun 15 20:39:58 2017 +0000 COFF: add support for lib mode usage When link is invoked with `/def:` and no input files, it behaves as if `lib.exe` was invoked. Emulate this behaviour, generating the import library from the
2009 Dec 09
0
[LLVMdev] Problem with code generated for call using stdcall convention
Hello > I naively though it would pick up the call convention from the declaration > as there was no error like we have when the wrong number of parameters is > used. This is not an error, you're just invoking undefined behaviour. -- With best regards, Anton Korobeynikov Faculty of Mathematics and Mechanics, Saint Petersburg State University
2009 Dec 10
3
[LLVMdev] Problem with code generated for call using stdcall convention
I too have stumbled over this. Wouldn't it be a good idea to add a check for this to the function verifier pass? Hans Anton Korobeynikov wrote: > Hello > >> I naively though it would pick up the call convention from the declaration >> as there was no error like we have when the wrong number of parameters is >> used. > This is not an error, you're just
2009 Dec 10
0
[LLVMdev] Problem with code generated for call using stdcall convention
Hans Wennborg wrote: > I too have stumbled over this. > > Wouldn't it be a good idea to add a check for this to the function > verifier pass? No. This is a FAQ: http://llvm.org/docs/FAQ.html#callconvwrong Nick > > > Hans > > Anton Korobeynikov wrote: >> Hello >> >>> I naively though it would pick up the call convention from the declaration
2009 Dec 10
1
[LLVMdev] Problem with code generated for call using stdcall convention
On Thu, Dec 10, 2009 at 12:21 PM, Nick Lewycky <nicholas at mxc.ca> wrote: > Hans Wennborg wrote: >> I too have stumbled over this. >> >> Wouldn't it be a good idea to add a check for this to the function >> verifier pass? > > No. This is a FAQ: http://llvm.org/docs/FAQ.html#callconvwrong IMO you could move the cc to the type and still replace mismatched
2005 Sep 21
2
cdecl and stdcall
Hi, I'm trying to load a dynamic link library and it seems to work (is.loaded -> TRUE). When I run the function, which calls the .Fortran subroutine, R crashes! I'v tried the same in S-Plus 2000 and it worked. Therefore I suppose that the dll has been compiled with the stdcall calling convention (and not cdecl). But the problem is that I don't have access to the source code,