Bug 214553 - [webkitpy] Build with arm64e when on Apple Internal
Summary: [webkitpy] Build with arm64e when on Apple Internal
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: Safari 13
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Jonathan Bedard
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2020-07-20 08:17 PDT by Jonathan Bedard
Modified: 2020-07-20 11:12 PDT (History)
5 users (show)

See Also:


Attachments
Patch (1.40 KB, patch)
2020-07-20 08:30 PDT, Jonathan Bedard
no flags Details | Formatted Diff | Diff
Patch (1.50 KB, patch)
2020-07-20 09:48 PDT, Jonathan Bedard
no flags Details | Formatted Diff | Diff
Patch for landing (1.48 KB, patch)
2020-07-20 10:44 PDT, Jonathan Bedard
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
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].