You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Scratching my own itch #2814 to make sure react-native works on 64-bit Android devices. Using abifilters to restrict it to bundle only 32-bit .so files drops performance heavily on 64-bit devices.
I have attempted to tackle the issue. Much of it 'just' worked, but without being able to verify them with the full suite of tests, I will leave this as Work in Progress. I pored over https://facebook.github.io/react-native/docs/testing.html but it wasn't a lot of help. I'll leave the details of the errors from the PR description for now.
Headline changes
Enabled the 64bit arm eabi and x86_64
Changed the CXX11 flags for folly & cxxreact
Upgraded to use the new soloader(0.3.0) that no longer restricts the so files to be copied.
Upgraded double-conversion to 1.1.6, for 64-bit support.
Updated generator templates
Test Plan
Used gradle to make the .aar file and verified that it contains the .so files for all architectures ("armeabi-v7a", "x86", "x86_64", "arm64-v8a").
Used that aar as a gradle dependency to build my react native app and verified it on a Nexus 6p.
SoLoader copies the right files, and React Native screens work as they should.
Automated Tests
It's not ideal. Probably because this is the first time I have attempted to run these.
Android Unit Tests pass but having massive trouble getting the integration tests going. Its the same both on master and on my branch. Would like some help with it.
Gradle tests fail on master (at least on my setup) for all yoga tests as its unable to load yoga.so. We have the same failures on this branch as well.
There also an oddity with robolectric, where the jars are not getting copied to their correct locations. Had to do it manually.
Buck tests for iOS fail on snapshots for Scroll View. Looks like the scroll view test page now has a new component that is not there in the snapshots. But that component has loading animation, and it is not going to be possible to have a 100% match (it's probable, but the probability is low). Have the same issue on master.
Other Considerations
Finally, we also need the 64-bit enabled JSC. There are two options,
Is to resurrect this Add x86_64 support facebookarchive/android-jsc#19. The tar location is gone now, so the script has to be modified to checkout the repo at the correct revision. Its a known version and since there are no "tests", seems like a safer option for this PR. Which is what I had to do locally and pointed it to our internal mvn that has the 64-bit enabled JSC.
@govi I tried to find reviewers for this pull request and wanted to ping them to take another look. However, based on the blame information for the files in this pull request I couldn't find any reviewers. This sometimes happens when the files in the pull request are new or don't exist on master anymore. Is this pull request still relevant? If yes could you please rebase? In case you know who has context on this code feel free to mention them in a comment (one person is fine). Thanks for reading and hope you will continue contributing to the project.
@gengjiawen yup.. but we prolly have to update the PR. The tar ball location is 404. I had to checkout their SVN repo and up to the revision. I think I'll prolly get to it. If nothing, it will make some of these tests pass.
This issue is super important for us. We have started RN integration into our app, and this may hold us back. Please let us know what we need to do to increase the priority of this issue, or if we can help somehow to get issue resolved.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BugCLA SignedThis label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.Platform: AndroidAndroid applications.Ran CommandsOne of our bots successfully processed a command.Resolution: FixedA PR that fixes this issue has been merged.
12 participants
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
Scratching my own itch #2814 to make sure react-native works on 64-bit Android devices. Using abifilters to restrict it to bundle only 32-bit .so files drops performance heavily on 64-bit devices.
I have attempted to tackle the issue. Much of it 'just' worked, but without being able to verify them with the full suite of tests, I will leave this as Work in Progress. I pored over https://facebook.github.io/react-native/docs/testing.html but it wasn't a lot of help. I'll leave the details of the errors from the PR description for now.
Headline changes
Test Plan
Automated Tests
It's not ideal. Probably because this is the first time I have attempted to run these.
Android Unit Tests pass but having massive trouble getting the integration tests going. Its the same both on master and on my branch. Would like some help with it.
Gradle tests fail on master (at least on my setup) for all yoga tests as its unable to load yoga.so. We have the same failures on this branch as well.
There also an oddity with robolectric, where the jars are not getting copied to their correct locations. Had to do it manually.
Buck tests for iOS fail on snapshots for Scroll View. Looks like the scroll view test page now has a new component that is not there in the snapshots. But that component has loading animation, and it is not going to be possible to have a 100% match (it's probable, but the probability is low). Have the same issue on master.
Other Considerations
Finally, we also need the 64-bit enabled JSC. There are two options,
Is to resurrect this Add x86_64 support facebookarchive/android-jsc#19. The tar location is gone now, so the script has to be modified to checkout the repo at the correct revision. Its a known version and since there are no "tests", seems like a safer option for this PR. Which is what I had to do locally and pointed it to our internal mvn that has the 64-bit enabled JSC.
The other option is to https://github.com/SoftwareMansion/jsc-android-buildscripts. Seems to be what expo are using/planning to use. Of course, it needs more testing. Last I have seen is expo rolling it back
Related PRs
Nothing at the moment.
Release Notes
[ANDROID] [BUGFIX] [ReactAndroid] - Enabled 64-bit support