Bug 147243

Summary: jsc-tailcall: Repatching tail calls as jump should depend on the opcode, not the JS CallLinkInfo
Product: WebKit Reporter: Basile Clement <basile_clement>
Component: JavaScriptCoreAssignee: Basile Clement <basile_clement>
Status: RESOLVED FIXED    
Severity: Normal CC: fpizlo, msaboff
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 146477    
Attachments:
Description Flags
Patch
none
Patch msaboff: review+

Description Basile Clement 2015-07-23 16:46:03 PDT
Patch forthcoming. The apparent source of failures on ARM devices for https://bugs.webkit.org/show_bug.cgi?id=146484 looks to be that we are patching NearCalls as jump when the CallLinkInfo tells us we are a tail call.

However even for a tail call, the slow path will still have an actual call (and not jump) opcode: we should be patching based on that information instead.
Comment 1 Basile Clement 2015-07-23 16:50:49 PDT
Created attachment 257408 [details]
Patch
Comment 2 Michael Saboff 2015-07-24 11:03:54 PDT
Comment on attachment 257408 [details]
Patch

Looks fine except could you change the "bool tail" to an enum.
Comment 3 Basile Clement 2015-07-24 11:26:56 PDT
Created attachment 257461 [details]
Patch

Patch with enum
Comment 4 Michael Saboff 2015-07-24 11:32:22 PDT
Comment on attachment 257461 [details]
Patch

r=me
Comment 5 Basile Clement 2015-07-24 11:59:15 PDT
Landed in https://trac.webkit.org/changeset/187354.