Summary: | DFG operation calls should be stdcall in Linux JSVALUE32_64 DFG JIT | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Yuqiang Xian <yuqiang.xian> | ||||||
Component: | JavaScriptCore | Assignee: | Nobody <webkit-unassigned> | ||||||
Status: | RESOLVED FIXED | ||||||||
Severity: | Normal | CC: | barraclough, ggaren | ||||||
Priority: | P2 | ||||||||
Version: | 528+ (Nightly build) | ||||||||
Hardware: | Unspecified | ||||||||
OS: | Unspecified | ||||||||
Bug Depends on: | 69413 | ||||||||
Bug Blocks: | |||||||||
Attachments: |
|
Description
Yuqiang Xian
2011-09-28 20:42:25 PDT
Created attachment 109118 [details]
the patch
Comment on attachment 109118 [details] the patch Looks like this patch is pre r96293, is there still a problem post-r96293? I don't think we want to take this change. We should be able to give FunctionPtr an appropriate set of constructors. If Linux defaults to stdcall, it is possible that the '#if CPU(X86) && COMPILER(GCC)' check in DFGOperations.h should be '#if CALLING_CONVENTION_IS_CDECL'. We should be able to fix the problem without littering the JIT with explicit constructor calls. Hi Gavin, Linux also defaults to cdecl. And surely we expects stdcall for JSValue32_64 DFG operations (which was a bug in previous code). Created attachment 109153 [details]
patch
This patch fixed the stdcall FunctionPtr constructors issue on Linux.
Comment on attachment 109153 [details] patch View in context: https://bugs.webkit.org/attachment.cgi?id=109153&action=review > Source/JavaScriptCore/assembler/MacroAssemblerCodeRef.h:55 > +#if CPU(X86) && COMPILER(GCC) I don't think GCC is the right test here. It will definitely be wrong for people building with clang. But I think it may also be wrong for people building with GCC on non-cdecl platforms, since cdecl is a property of the platform ABI, not the compiler. I'd suggest (OS(DARWIN) || OS(LINUX)) here. I think stdcall is only a convention in windows, so per geoff's comments I'm going to make this !PLATFORM(WINDOWS), r+ & land. (In reply to comment #6) > I think stdcall is only a convention in windows, so per geoff's comments I'm going to make this !PLATFORM(WINDOWS), r+ & land. But what about Open Watcom C++??? :) |