Bug 183474

Summary: MIPS+Armv7 builds are broken since r229391
Product: WebKit Reporter: Guillaume Emont <guijemont>
Component: JavaScriptCoreAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: commit-queue, ews-watchlist, keith_miller, mark.lam, msaboff, sbarati, webkit-bug-importer, ysuzuki
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Other   
OS: Linux   
Bug Depends on:    
Bug Blocks: 183786    
Attachments:
Description Flags
Patch
none
Patch
none
Patch none

Description Guillaume Emont 2018-03-08 13:29:40 PST
Some extra work is needed to make them build again (I started work on this).
Comment 1 Guillaume Emont 2018-03-09 19:49:06 PST
Created attachment 335497 [details]
Patch

Preliminary patch that fixes a bunch of small things. With that, things compile on arm and mips, but will follow the x86 calling convention and therefore should be expected to fail at runtime.
Comment 2 Guillaume Emont 2018-03-09 19:58:15 PST
From what I understood of the armv7 calling convention, it should be relatively easy to get that working, as it seems to be pretty similar to what we have for x86_64 or arm64.
Mips on the other hand has a whole bunch of special rules that will need to be put in place, especially when floats/doubles come into the equation, incuding, but not limited to:
 - a float/double passed as first argument is always in $f12
 - a float/double in second argument will be in $f14 if the first argument is a float/double, but in $a3 (or $a3 and $a4 for double) if the first argument is integral.
Comment 3 Guillaume Emont 2018-03-09 20:02:29 PST
Also a note regarding the operationGetByValCell call: this looks like it was a bug that was found thanks to the new system, so yay! It was quite hard to find where was the offending call with the output I got from gcc though (more recent versions of gcc might be better at it, not sure, I should try).

Relatedly, I guess it would be nice to add a unit test for that operationGetByValCell call if we can.
Comment 4 Guillaume Emont 2018-03-20 10:53:12 PDT
Created attachment 336132 [details]
Patch

Rebased patch. A patch fixing the CCallHelpers will be provided in a separate bug by Dominik Infuehr
Comment 5 Guillaume Emont 2018-03-20 11:40:48 PDT
Created attachment 336137 [details]
Patch

Fixed CellTag → JSCellType
Comment 6 Yusuke Suzuki 2018-03-20 12:26:45 PDT
Comment on attachment 336137 [details]
Patch

r=me
Comment 7 WebKit Commit Bot 2018-03-20 13:37:51 PDT
Comment on attachment 336137 [details]
Patch

Clearing flags on attachment: 336137

Committed r229772: <https://trac.webkit.org/changeset/229772>
Comment 8 WebKit Commit Bot 2018-03-20 13:37:52 PDT
All reviewed patches have been landed.  Closing bug.
Comment 9 Radar WebKit Bug Importer 2018-03-20 13:38:22 PDT
<rdar://problem/38677603>