Bug 214553

Summary: [webkitpy] Build with arm64e when on Apple Internal
Product: WebKit Reporter: Jonathan Bedard <jbedard>
Component: Tools / TestsAssignee: Jonathan Bedard <jbedard>
Status: RESOLVED FIXED    
Severity: Normal CC: aakash_jain, ews-watchlist, glenn, thorton, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: Safari 13   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch
none
Patch for landing none

Description Jonathan Bedard 2020-07-20 08:17:18 PDT
Apple Internal builds should consider the runtime architecture arm64, but should build with arm64e.
Comment 1 Jonathan Bedard 2020-07-20 08:17:31 PDT
<rdar://problem/65745597>
Comment 2 Jonathan Bedard 2020-07-20 08:30:42 PDT
Created attachment 404716 [details]
Patch
Comment 3 Aakash Jain 2020-07-20 09:14:24 PDT
Comment on attachment 404716 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=404716&action=review

> Tools/Scripts/webkitpy/port/mac.py:79
> +            architecture = 'arm64e'

Might be a good idea to add a comment here about why are we doing this.
Also it might be better to modify architecture() method to return the architecture accordingly, rather than hacking this function.

> Tools/Scripts/webkitpy/port/mac.py:80
> +        return ['ARCHS=i386'] if architecture == 'x86' else ['ARCHS={}'.format(architecture)]

Can we convert this to multi-line if else for better readability?
Comment 4 Jonathan Bedard 2020-07-20 09:33:06 PDT
Comment on attachment 404716 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=404716&action=review

>> Tools/Scripts/webkitpy/port/mac.py:79
>> +            architecture = 'arm64e'
> 
> Might be a good idea to add a comment here about why are we doing this.
> Also it might be better to modify architecture() method to return the architecture accordingly, rather than hacking this function.

Modifying architecture() is the wrong thing to do, since we only want arm64e for build-time. The runtime architecture should still be thought of as arm64.
Comment 5 Jonathan Bedard 2020-07-20 09:48:00 PDT
Created attachment 404722 [details]
Patch
Comment 6 Tim Horton 2020-07-20 10:35:18 PDT
Comment on attachment 404722 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=404722&action=review

> Tools/Scripts/webkitpy/port/mac.py:78
> +        # The Internal SDK should always prefer arm64e binaries  to arm64 ones

Weird double space between "binaries" and "to"
Comment 7 Jonathan Bedard 2020-07-20 10:44:42 PDT
Created attachment 404726 [details]
Patch for landing
Comment 8 EWS 2020-07-20 11:12:53 PDT
Committed r264605: <https://trac.webkit.org/changeset/264605>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 404726 [details].