Bug 126423

Summary: cstack Branch: ARM64 LLInt fails to compile due to instructions limitations with sp
Product: WebKit Reporter: Michael Saboff <msaboff>
Component: JavaScriptCoreAssignee: Michael Saboff <msaboff>
Status: RESOLVED FIXED    
Severity: Normal    
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Attachments:
Description Flags
Patch fpizlo: review+

Description Michael Saboff 2014-01-03 00:34:52 PST
ARM64 has many limitations on using the stack pointer as the register number 31 is also used as the zero source xzr register.  After recent CStack changes, the LLInt won't compile for ARM64 due to some of these limitations.  Examples include using sp as a source operand for a store or arithmetic instruction.
Comment 1 Michael Saboff 2014-01-03 00:48:48 PST
Created attachment 220289 [details]
Patch

It may make sense longer term to fix the offline assembler to transform improper pseudo ops using a source of SP to emit a "mov temp, sp ; op ..., temp, ...".  That change is much larger and it is easier to cover the few cases by changing the .asm files in this patch.
Comment 2 Filip Pizlo 2014-01-03 10:14:04 PST
Comment on attachment 220289 [details]
Patch

R=me.  Can you also file a bug against offlineasm?  *eventually* we can make offlineasm do these things for us.
Comment 3 Michael Saboff 2014-01-03 17:22:27 PST
(In reply to comment #2)
> (From update of attachment 220289 [details])
> R=me.  Can you also file a bug against offlineasm?  *eventually* we can make offlineasm do these things for us.

Filed <https://bugs.webkit.org/show_bug.cgi?id=126476> - "ARM64 backend for Offlineasm doesn't properly handle instructions limitations of SP register"
Comment 4 Michael Saboff 2014-01-03 17:23:16 PST
Committed r161300: <http://trac.webkit.org/changeset/161300>