Граф коммитов

1271 Коммитов

Автор SHA1 Сообщение Дата
REDMOND\acoates 2e64c10da8 merge master 2019-05-28 13:08:40 -07:00
Anandraj 14729eddc2 Removing Chakra specific hack from JSIExecutor (#66) 2019-05-15 14:44:18 -07:00
Andrew Coates (REDMOND) 7300f9ae75 merge master 2019-05-13 21:34:06 -07:00
tudorms 0de1126cd6
Fix Office droid build (#65) 2019-05-13 17:39:02 -07:00
tudorms 1e6ff28993
Separate V8 code from the core JSI library (#64) 2019-05-13 13:51:11 -07:00
REDMOND\acoates 8f55ab65fc Turn off the usage of bitfields in yoga style until we sync to version with the fixes for MSC 2019-05-02 14:31:42 -07:00
rohitjain85 e4ca929e44
Merge branch 'master' into fb59merge 2019-05-02 18:52:12 +05:30
Rohit Jain (MOD) 925532d42c Android initial merge 2019-05-02 18:28:47 +05:30
Anandraj ea4aa04541
Cross platform/engine/storage abstraction for original and prepared scripts (#55)
// ScriptStore manages versioned storage of both source scripts and prepared scripts. We intent to pass a ScriptSTore implementation
// directly into the JSI runtime from host. It will enable the following,
// 1. Pass richer data and metadata on the source scripts from host to JSI runtime without being constrained by the various layers in between.
// 2. Potential performance benefits as it will allow us to directly stream the source script and the prepared scripts from arbitrary storages and encoding without being constrained by intermediate layers.
// 3. Consolidate Source script versioning and storage logic into a single component.
// 4. Consolidate prepared script storage and persistance formats across platforms and aross JS-engines.
// 5. Allow co-existance of multiple Javascript engines, versions, strategies. (Some more work required to support multi-version)
// 6. Allow platform/storage/engine specific extensions for better performance.
2019-05-02 09:10:16 +05:30
REDMOND\acoates 74ba0895ab Resolve conflicts to get ReactCommon building in RNW. 2019-05-01 12:59:07 -07:00
REDMOND\acoates 45bb86d5d7 merge master -> fb59merge 2019-05-01 12:25:06 -07:00
rohitjain85 a9a1962d59
Fixing devmain build break for droid 64 bit platforms (#56) 2019-04-30 14:38:33 +05:30
Christopher Hogan fedfabcecb facebook 59.0 merge- with conflicts 2019-04-22 10:37:26 -07:00
htpiv 7042cdba5d Fix c4244 (#49)
* (*pedantry alert*)
Right-shifting a 32-bit value by 32 is, strictly, undefined behavior,
although every compiler worth its salt will understand that this is
just a funny way to generate 0. But anyways, this code causes VC++ to
emit warning C4293, which, per Office policy, may not be disabled.

* Fix C4244 warnings in MethodCall.cpp when compiling for x86, caused
by implicitly truncating `int64_t` values to `int` values.
2019-04-16 19:15:02 +00:00
acoates-ms c3f19bd395
Sync from internal (#48) 2019-04-12 15:31:10 -07:00
acoates-ms 8fec294664
Remove a bunch of jsc files that should have been removed with 58 (#44)
* Remove a bunch of jsc files that should have been removed with 58

* more build fix

* Put back JSI JSCRuntime build switch

* Put back jni changes

* fix build

* Remove unneeded build logic
2019-04-10 10:38:16 -07:00
acoates-ms 21a8a91d9a
Sync from tenant (#43) 2019-04-08 13:05:10 -07:00
acoates-ms 7852153b4f
Revertglog (#38)
* Revert "Updating glog version to latest(0.3.5) which is the version RN is using now (#32)"

This reverts commit 4bfaca4eb5.

* Revert "Adding logging support on droid and logging failure message (#31)"

This reverts commit 7fd45d01b6.
2019-04-04 16:16:35 -07:00
rohitjain85 7fd45d01b6
Adding logging support on droid and logging failure message (#31) 2019-04-03 13:35:56 +05:30
rohitjain85 ebee9db144 Moving exception flag to LOCAL_CFLAGS to reduce the diff (#24) 2019-04-02 04:42:32 +00:00
REDMOND\acoates 7f3192cf9d put RN58 back 2019-03-28 13:44:57 -07:00
REDMOND\acoates b988169e72 Squashed commit of the following:
commit 4c43e301d97042e9eec4401dd81b8ebce053f691
Author: REDMOND\acoates <acoates@microsoft.com>
Date:   Tue Mar 26 10:49:02 2019 -0700

    Squashed commit of the following:

    commit 862f3fb5d9e3161feab6e5e0e61c7b28e8ac1ef9
    Author: REDMOND\acoates <acoates@microsoft.com>
    Date:   Tue Mar 26 10:46:37 2019 -0700

        Revert "Merge 1b12e2caaa into 9f1e90947421ad0ea2de1b534117c500dc8c9744"

        This reverts commit d036bc4c57, reversing
        changes made to 9f1e909474.

    commit 41477c33c1bcc78f40da00ac7e86ab4dd3f7d062
    Author: REDMOND\acoates <acoates@microsoft.com>
    Date:   Tue Mar 26 10:46:23 2019 -0700

        Revert "Applying package update to 0.58.6-microsoft.1"

        This reverts commit 852df1af0e.

    commit 4993963205e737849e4880309ef86aeac9f2a765
    Author: REDMOND\acoates <acoates@microsoft.com>
    Date:   Tue Mar 26 10:46:16 2019 -0700

        Revert "Applying package update to 0.58.6-microsoft.2"

        This reverts commit 774513fec9.

    commit 41f8beadb2030593208ffc6ff29339991dde3798
    Author: REDMOND\acoates <acoates@microsoft.com>
    Date:   Tue Mar 26 10:46:07 2019 -0700

        Revert "Merge 4f3c37886c into 774513fec948ee5595543e23ab4e7b9cccbdcbf1"

        This reverts commit a840490784, reversing
        changes made to 774513fec9.

    commit 143e70ec6228e110cd94a5ae9c56309040c1f1eb
    Author: REDMOND\acoates <acoates@microsoft.com>
    Date:   Tue Mar 26 10:45:57 2019 -0700

        Revert "Applying package update to 0.58.6-microsoft.3"

        This reverts commit 54dfee820d.

commit 138191b0d6bf9e4370fb5126dc2095a3fb122a57
Author: REDMOND\acoates <acoates@microsoft.com>
Date:   Tue Mar 26 10:45:16 2019 -0700

    Revert "Merge d8be239fac into 54dfee820d107cb897c5aca14131cf7fbde616d7"

    This reverts commit faae1e56f8, reversing
    changes made to 54dfee820d.

commit 40a77c8365c5273df0bba4fc2b0439db17d247d0
Author: REDMOND\acoates <acoates@microsoft.com>
Date:   Tue Mar 26 10:34:44 2019 -0700

    Revert "Applying package update to 0.58.6-microsoft.4"

    This reverts commit 043f6330e7.

commit adf5c26c8f7132a6643ecfea116226632173447b
Author: REDMOND\acoates <acoates@microsoft.com>
Date:   Tue Mar 26 10:34:42 2019 -0700

    Revert "Applying package update to 0.58.6-microsoft.5"

    This reverts commit 4004f889c2.

commit e68d497a58e32d26f0d04130895954d7b654c2bf
Author: REDMOND\acoates <acoates@microsoft.com>
Date:   Tue Mar 26 10:34:39 2019 -0700

    Revert "Fix the builds... (#20)"

    This reverts commit 745eeda26f.

commit 4cdef1eef22edbcdc9ca86e31846a175b944999e
Author: REDMOND\acoates <acoates@microsoft.com>
Date:   Tue Mar 26 10:34:31 2019 -0700

    Revert "Applying package update to 0.58.6-microsoft.6"

    This reverts commit 34a3077388.
2019-03-26 10:54:53 -07:00
Christopher Hogan 810173f5cf iOS building/running fixes 2019-03-20 11:17:57 -07:00
Christopher Hogan d884baec86 iOS 0.58.6 merge building, linking, running 2019-03-19 14:09:38 -07:00
REDMOND\acoates 2696dc6342 Fixes for windows 2019-03-18 17:13:43 -07:00
Rohit Jain (MOD) f74113318f more build fixes 2019-03-12 19:48:41 +05:30
Rohit Jain (MOD) 96633566cc Bunch of build fixes in ReactAndroid and ReactCommon 2019-03-12 15:48:05 +05:30
Christopher Hogan 27381d39db facebook 0.58.6 merge with conflicts (although some iOS files had conflicts removed) 2019-03-11 13:49:58 -07:00
ericlewis caba1cb2e1 Fix crash when calling substring() on a string containing emoji. (#23609)
Summary:
Fixes #23459. It is not legal to write the character array of a std::string, and can result in undefined behavior.

[General] [Fixed] - Crash when substring intersects with emoji
Pull Request resolved: https://github.com/facebook/react-native/pull/23609

Differential Revision: D14198159

Pulled By: mdvacca

fbshipit-source-id: 71060b1b99ddab89793c98c09f99ec9974479e62
2019-03-11 21:16:21 +01:00
acoates-ms c6cb0ad22e
sync from internal (#5) 2019-03-05 21:47:37 -08:00
REDMOND\acoates 5c0c3d4084 Initial commit of internal changes. 2019-03-01 10:09:07 -08:00
Alex Dvornikov 3c74b6ea34 Bring back the unit tests for the Cxx implementation
Reviewed By: jeanlauliac

Differential Revision: D14026623

fbshipit-source-id: 76a4089bb09b7e5152e992a91eae0427877767c0
2019-02-12 04:50:52 -08:00
Kevin Gozali 344b32bb64 TM iOS: avoid bad memory access when passing prop name to a lambda
Summary: Depending on the timing of the method call from JS to a CxxModule, we may be accessing memory that has been deallocated, causing exception to RN runtime. This fixes it.

Reviewed By: JoshuaGross, mdvacca

Differential Revision: D14033831

fbshipit-source-id: 5a77aa41223b1fc3146dcf78b7f8e93375605d6d
2019-02-11 17:29:14 -08:00
Valentin Shergin 222e650885 Fabric: Systraces are temporary disabled in Fabric C++ code
Summary: Now in BUCK file only, not in code.

Reviewed By: JoshuaGross

Differential Revision: D14019271

fbshipit-source-id: e1396be7156a374a1379a147ddecb83b51686121
2019-02-11 16:01:05 -08:00
Valentin Shergin 77838b5504 Fabric: Systraces are back
Summary:
It's better to comment `DWITH_FBSYSTRACE` out in BUCK files instead of removing them from the code.
I'll publish the BUCK changes as separate diff for simpler backout in the future.

Reviewed By: mdvacca

Differential Revision: D14019272

fbshipit-source-id: 8b322b5c115efe33c15929e008b97a05220813df
2019-02-11 16:01:05 -08:00
empyrical 78be6efda9 JSI: Minor tweaks for building on MSVC (#23367)
Summary:
This pull request makes two minor changes to `jsi.h`:

 * Tweak the `JSI_EXPORT` macro to automatically set itself to an empty value if `_MSC_VER` is defined - like how was done by acoates-ms [here](8beb4bb58a/ReactCommon/cxxreact/JSBigString.h (L15-L21)).
 * Tweak the call to constructor `Pointer(Runtime::PointerValue* ptr)` in the constructor for `PropNameID`. I am not sure why MSVC wasn't working with the original version, but it compiles after I tweak that.

[General] [Fixed] - Tweaked `jsi.h` to build on MSVC
Pull Request resolved: https://github.com/facebook/react-native/pull/23367

Differential Revision: D14032507

Pulled By: cpojer

fbshipit-source-id: 701c13e3509cc244dbe0c15f92067fae4382bee2
2019-02-11 15:42:18 -08:00
Valentin Shergin 1a26f97eb0 Clang-format for all files in Fabric folder
Summary:
Trivial.
If you have troubles with rebasing on top of this revision, run this on your diff:
$ find */*.h */*.mm */*.cpp */*.m -exec clang-format -style=file -i {} \;

Reviewed By: JoshuaGross

Differential Revision: D14018903

fbshipit-source-id: fd0ce2da0e11954e683385402738c701045e727c
2019-02-11 13:07:09 -08:00
Kevin Gozali d9f34bdbb2 TM iOS: added helper to check whether a class is TurboModule compatible
Summary: Similar macro as the existing one, but this one checks for the class directly.

Reviewed By: RSNara

Differential Revision: D14016664

fbshipit-source-id: aae9a9c1cc95f56d2eff6c9021a714ed4a843db3
2019-02-08 21:08:51 -08:00
Valentin Shergin 21290b569b Fabric: Enable all Fabric tests for Android
Summary: All our C++ Fabric tests are cross-platform, so it makes sense to run them for all platforms (especially because platform may behaive differently).

Reviewed By: JoshuaGross, mdvacca

Differential Revision: D13984574

fbshipit-source-id: e384c03c7f9839be38a1910e04ba2f7725abc378
2019-02-08 20:18:19 -08:00
David Vacca 6a71d51250 Trivial rename
Summary: Trivial rename

Reviewed By: fkgozali

Differential Revision: D14011984

fbshipit-source-id: dd2e7e0221bdad7b482c6a39b1cc877779c9704c
2019-02-08 18:55:35 -08:00
Valentin Shergin fd3b8f2000 Fabric: Introducing Better: For faster, clear and ideomatic codebase
Summary:
`Better` is a trivial collection of basic tools borrowed from other low-level general purpose libraries (like Folly, Abseil or Boost). The main goals of Better:
 - Make the codebase more portable;
 - Make the dependency list explicit (by decoupling it as a dependency list of Better);
 - Make relying on modern C++ patterns and tools in code simple and easy.
 - Make executing experiments with different dependencies easier.

 As a first example usage, this diff replaces std::unordered_map with an efficient one from folly on the one of the hottest paths.

Reviewed By: JoshuaGross

Differential Revision: D13944565

fbshipit-source-id: 5fa2c4abe6c17f7361eddcc25f968b6440d5d9db
2019-02-08 13:57:33 -08:00
David Aurelio 5319cb29a8 Move `.clang-format` to repo root (#23328)
Summary:
Moves `.clang-format` to repo root to allow for easier discoverability, and integration with auto-format plugins for editors and IDEs.
Pull Request resolved: https://github.com/facebook/react-native/pull/23328

Differential Revision: D13986715

Pulled By: davidaurelio

fbshipit-source-id: fcfda59842da10cd4bc02e4550b74782fbb59e0d
2019-02-07 04:19:49 -08:00
Valentin Shergin 9842e39019 Fabric: folly::dynamic was replaced with RawValue in prop-parsing infra
Summary:
Our long-term plan is to completely illuminate `jsi::Value`-to-`folly::dynamic` serialization step in prop parsing process improving performance and memory pressure. At the same time, we don't want to introduce a hard dependency in application code to JSI because it exposes direct access to VM and prevents parsing some data that come *NOT* from JSVM.
RawValue is an extremely light-weight (hopefully fully optimized-out) abstraction that provides limited JSON-like and C++-idiomatic interface.

The current particular implementation is still using `folly::dynamic` inside, but I have fully JSI-powered one which will replace the current one right after we figure out how to deal with folly::dynamic-specific callsites. Or we can implement RawValue in a hybrid manner if a code-size implication of that will be minimal.

Reviewed By: JoshuaGross, mdvacca

Differential Revision: D13962466

fbshipit-source-id: e848522fd242f21e9e771773f2103f1c1d9d7f21
2019-02-06 16:34:46 -08:00
Valentin Shergin b0c8275369 Fabric: Lost comment in EventQueue
Summary: Just a comment.

Reviewed By: JoshuaGross

Differential Revision: D13962465

fbshipit-source-id: 31780a8ccf02d768e3d4b91e7205ceb0ee10fedf
2019-02-06 16:34:46 -08:00
Valentin Shergin 2332cb6fe2 Fabric: A bunch of `#ifdef ANDROID`
Summary: Nothing really changed; the change is only to better express an original intent.

Reviewed By: JoshuaGross

Differential Revision: D13962464

fbshipit-source-id: f385db8ba8662f2150181e47fc6a2a981f809e96
2019-02-06 16:34:46 -08:00
Kevin Gozali 94925d5eb7 TM iOS: Verify that module class conforms to RCTTurboModule before instantiating
Summary: At times, the lookup logic may find a class that's not compliant with RCTTurboModule. If so, it shouldn't be instantiated, and we assume the module doesn't exist.

Reviewed By: JoshuaGross, RSNara

Differential Revision: D13979004

fbshipit-source-id: ac1fa9cc456715cddd101fff13f5a41f9528a74e
2019-02-06 16:10:30 -08:00
Kevin Gozali 3e9f9cfe47 TM iOS: Util to check if an id is TurboModule instance
Summary: Simple macro to do check if TurboModule is enabled and the particular object is RCTTurboModule compliant.

Reviewed By: PeteTheHeat

Differential Revision: D13978368

fbshipit-source-id: 660c7cab7bb074d80d57abead951dad19306ae73
2019-02-06 16:01:31 -08:00
Joshua Gross 550a14c216 ImageResponseObserverCoordinator does not need to be shared_ptr
Summary: Don't use shared_ptr in this case, it's not needed.

Reviewed By: shergin

Differential Revision: D13965413

fbshipit-source-id: ec98c13f53c7d558a0cb68cea0f97568dd202cd8
2019-02-06 11:51:32 -08:00
Joshua Gross b6318acbab Support image props for Slider component, feature parity with pre-Fabric Slider
Summary: The biggest change is that (1) the image proxy/observer code from the Image component has been generalized, (2) the four image props for the Slider component are fully supported, (3) a handful of props that were ignored or buggy on iOS now perform as expected.

Reviewed By: shergin

Differential Revision: D13954892

fbshipit-source-id: bec8ad3407c39a1cb186d9541a73b509dccc92ce
2019-02-05 17:31:40 -08:00
empyrical cae6beff74 JSBigString.h: Remove duplicate include of 'unistd.h' (#23297)
Summary:
This removes the accidental double include of the header `unistd.h` from `JSBigString.h`. One was added by me as part of #22330, and one by matthargett as part of #21764

[General] [Fixed] - `JSBigString.h`: Removed accidental double include of header `unistd.h`
Pull Request resolved: https://github.com/facebook/react-native/pull/23297

Differential Revision: D13961223

Pulled By: hramos

fbshipit-source-id: c0dba8a475b3c09356d34cb65b989c286793fa67
2019-02-05 12:41:46 -08:00