react-native-executorch 0.5.2 → 0.5.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/android/CMakeLists.txt +24 -0
- package/android/build.gradle +1 -0
- package/android/src/main/cpp/CMakeLists.txt +25 -0
- package/android/src/main/java/com/swmansion/rnexecutorch/RnExecutorchPackage.kt +1 -13
- package/common/rnexecutorch/RnExecutorchInstaller.cpp +52 -18
- package/common/rnexecutorch/RnExecutorchInstaller.h +0 -25
- package/common/rnexecutorch/TokenizerModule.cpp +1 -1
- package/common/rnexecutorch/TokenizerModule.h +4 -1
- package/common/rnexecutorch/data_processing/FileUtils.h +2 -2
- package/common/rnexecutorch/data_processing/ImageProcessing.cpp +5 -5
- package/common/rnexecutorch/data_processing/ImageProcessing.h +2 -2
- package/common/rnexecutorch/data_processing/Numerical.cpp +13 -0
- package/common/rnexecutorch/host_objects/JsiConversions.h +43 -62
- package/common/rnexecutorch/host_objects/ModelHostObject.h +43 -24
- package/common/rnexecutorch/metaprogramming/ConstructorHelpers.h +8 -6
- package/common/rnexecutorch/metaprogramming/FunctionHelpers.h +1 -1
- package/common/rnexecutorch/models/BaseModel.cpp +2 -2
- package/common/rnexecutorch/models/BaseModel.h +5 -0
- package/common/rnexecutorch/models/EncoderDecoderBase.cpp +2 -2
- package/common/rnexecutorch/models/EncoderDecoderBase.h +2 -2
- package/common/rnexecutorch/models/classification/Classification.cpp +6 -6
- package/common/rnexecutorch/models/classification/Classification.h +5 -0
- package/common/rnexecutorch/models/classification/Constants.h +3 -3
- package/common/rnexecutorch/models/embeddings/BaseEmbeddings.cpp +2 -2
- package/common/rnexecutorch/models/embeddings/BaseEmbeddings.h +2 -2
- package/common/rnexecutorch/models/embeddings/image/ImageEmbeddings.cpp +3 -3
- package/common/rnexecutorch/models/embeddings/image/ImageEmbeddings.h +5 -0
- package/common/rnexecutorch/models/embeddings/text/TextEmbeddings.cpp +2 -2
- package/common/rnexecutorch/models/embeddings/text/TextEmbeddings.h +6 -1
- package/common/rnexecutorch/models/image_segmentation/Constants.h +3 -3
- package/common/rnexecutorch/models/image_segmentation/ImageSegmentation.cpp +6 -5
- package/common/rnexecutorch/models/image_segmentation/ImageSegmentation.h +8 -1
- package/common/rnexecutorch/models/llm/LLM.cpp +58 -0
- package/common/rnexecutorch/models/llm/LLM.h +35 -0
- package/common/rnexecutorch/models/object_detection/Constants.h +3 -3
- package/common/rnexecutorch/models/object_detection/ObjectDetection.cpp +8 -8
- package/common/rnexecutorch/models/object_detection/ObjectDetection.h +11 -5
- package/common/rnexecutorch/models/object_detection/Types.h +13 -0
- package/common/rnexecutorch/models/object_detection/Utils.cpp +13 -11
- package/common/rnexecutorch/models/object_detection/Utils.h +7 -13
- package/common/rnexecutorch/models/ocr/CTCLabelConverter.cpp +2 -2
- package/common/rnexecutorch/models/ocr/CTCLabelConverter.h +2 -2
- package/common/rnexecutorch/models/ocr/Constants.h +33 -26
- package/common/rnexecutorch/models/ocr/Detector.cpp +20 -22
- package/common/rnexecutorch/models/ocr/Detector.h +4 -4
- package/common/rnexecutorch/models/ocr/OCR.cpp +9 -8
- package/common/rnexecutorch/models/ocr/OCR.h +11 -3
- package/common/rnexecutorch/models/ocr/RecognitionHandler.cpp +20 -19
- package/common/rnexecutorch/models/ocr/RecognitionHandler.h +9 -7
- package/common/rnexecutorch/models/ocr/Recognizer.cpp +7 -7
- package/common/rnexecutorch/models/ocr/Recognizer.h +2 -2
- package/common/rnexecutorch/models/ocr/Types.h +4 -6
- package/common/rnexecutorch/models/ocr/{DetectorUtils.cpp → utils/DetectorUtils.cpp} +70 -63
- package/common/rnexecutorch/models/ocr/{DetectorUtils.h → utils/DetectorUtils.h} +12 -11
- package/common/rnexecutorch/models/ocr/{RecognitionHandlerUtils.cpp → utils/RecognitionHandlerUtils.cpp} +14 -11
- package/common/rnexecutorch/models/ocr/{RecognitionHandlerUtils.h → utils/RecognitionHandlerUtils.h} +5 -5
- package/common/rnexecutorch/models/ocr/{RecognizerUtils.cpp → utils/RecognizerUtils.cpp} +28 -26
- package/common/rnexecutorch/models/ocr/{RecognizerUtils.h → utils/RecognizerUtils.h} +15 -14
- package/common/rnexecutorch/models/speech_to_text/SpeechToText.cpp +2 -2
- package/common/rnexecutorch/models/speech_to_text/SpeechToText.h +9 -2
- package/common/rnexecutorch/models/speech_to_text/SpeechToTextStrategy.h +2 -2
- package/common/rnexecutorch/models/speech_to_text/WhisperStrategy.cpp +2 -2
- package/common/rnexecutorch/models/speech_to_text/WhisperStrategy.h +2 -2
- package/common/rnexecutorch/models/style_transfer/StyleTransfer.cpp +5 -5
- package/common/rnexecutorch/models/style_transfer/StyleTransfer.h +6 -0
- package/common/rnexecutorch/models/vertical_ocr/VerticalDetector.cpp +23 -22
- package/common/rnexecutorch/models/vertical_ocr/VerticalDetector.h +4 -4
- package/common/rnexecutorch/models/vertical_ocr/VerticalOCR.cpp +34 -34
- package/common/rnexecutorch/models/vertical_ocr/VerticalOCR.h +27 -20
- package/{third-party/ios/ExecutorchLib/ExecutorchLib/sampler → common/runner}/sampler.cpp +3 -2
- package/{third-party/ios/ExecutorchLib/ExecutorchLib/sampler → common/runner}/sampler.h +3 -2
- package/ios/libs/executorch/libbackend_coreml_ios.a +0 -0
- package/ios/libs/executorch/libbackend_coreml_simulator.a +0 -0
- package/{third-party/ios/ExecutorchLib/frameworks/backend_mps.xcframework/ios-arm64 → ios/libs/executorch}/libbackend_mps_ios.a +0 -0
- package/{third-party/ios/ExecutorchLib/frameworks/backend_mps.xcframework/ios-arm64-simulator → ios/libs/executorch}/libbackend_mps_simulator.a +0 -0
- package/ios/libs/executorch/libbackend_xnnpack_ios.a +0 -0
- package/ios/libs/executorch/libbackend_xnnpack_simulator.a +0 -0
- package/ios/libs/executorch/libexecutorch_ios.a +0 -0
- package/ios/libs/executorch/libexecutorch_simulator.a +0 -0
- package/ios/libs/executorch/libkernels_custom_ios.a +0 -0
- package/ios/libs/executorch/libkernels_custom_simulator.a +0 -0
- package/ios/libs/executorch/libkernels_optimized_ios.a +0 -0
- package/ios/libs/executorch/libkernels_optimized_simulator.a +0 -0
- package/ios/libs/executorch/libkernels_portable_ios.a +0 -0
- package/ios/libs/executorch/libkernels_portable_simulator.a +0 -0
- package/ios/libs/executorch/libkernels_quantized_ios.a +0 -0
- package/ios/libs/executorch/libkernels_quantized_simulator.a +0 -0
- package/ios/libs/tokenizers-cpp/physical-arm64-release/libsentencepiece.a +0 -0
- package/ios/{ExecutorchLib.xcframework/ios-arm64-simulator/ExecutorchLib.framework/ExecutorchLib → libs/tokenizers-cpp/physical-arm64-release/libtokenizers_c.a} +0 -0
- package/ios/libs/tokenizers-cpp/physical-arm64-release/libtokenizers_cpp.a +0 -0
- package/ios/libs/tokenizers-cpp/simulator-arm64-debug/libsentencepiece.a +0 -0
- package/ios/{ExecutorchLib.xcframework/ios-arm64/ExecutorchLib.framework/ExecutorchLib → libs/tokenizers-cpp/simulator-arm64-debug/libtokenizers_c.a} +0 -0
- package/ios/libs/tokenizers-cpp/simulator-arm64-debug/libtokenizers_cpp.a +0 -0
- package/lib/Error.js +9 -6
- package/lib/ThreadPool.d.ts +10 -0
- package/lib/ThreadPool.js +28 -0
- package/lib/constants/modelUrls.js +1 -1
- package/lib/controllers/OCRController.js +9 -14
- package/lib/controllers/VerticalOCRController.js +9 -14
- package/lib/hooks/computer_vision/useOCR.js +7 -8
- package/lib/hooks/computer_vision/useVerticalOCR.js +3 -5
- package/lib/index.d.ts +0 -2
- package/lib/index.js +1 -3
- package/lib/module/controllers/LLMController.js +6 -10
- package/lib/module/controllers/LLMController.js.map +1 -1
- package/lib/module/hooks/computer_vision/useClassification.js +2 -2
- package/lib/module/hooks/computer_vision/useClassification.js.map +1 -1
- package/lib/module/hooks/computer_vision/useImageEmbeddings.js +2 -2
- package/lib/module/hooks/computer_vision/useImageEmbeddings.js.map +1 -1
- package/lib/module/hooks/computer_vision/useImageSegmentation.js +2 -2
- package/lib/module/hooks/computer_vision/useImageSegmentation.js.map +1 -1
- package/lib/module/hooks/computer_vision/useObjectDetection.js +2 -2
- package/lib/module/hooks/computer_vision/useObjectDetection.js.map +1 -1
- package/lib/module/hooks/computer_vision/useStyleTransfer.js +2 -2
- package/lib/module/hooks/computer_vision/useStyleTransfer.js.map +1 -1
- package/lib/module/hooks/general/useExecutorchModule.js +2 -2
- package/lib/module/hooks/general/useExecutorchModule.js.map +1 -1
- package/lib/module/hooks/natural_language_processing/useTextEmbeddings.js +2 -2
- package/lib/module/hooks/natural_language_processing/useTextEmbeddings.js.map +1 -1
- package/lib/module/hooks/useModule.js +13 -9
- package/lib/module/hooks/useModule.js.map +1 -1
- package/lib/module/index.js +1 -1
- package/lib/module/index.js.map +1 -1
- package/lib/module/modules/BaseModule.js +9 -17
- package/lib/module/modules/BaseModule.js.map +1 -1
- package/lib/module/modules/computer_vision/ClassificationModule.js +2 -2
- package/lib/module/modules/computer_vision/ClassificationModule.js.map +1 -1
- package/lib/module/modules/computer_vision/ImageEmbeddingsModule.js +2 -2
- package/lib/module/modules/computer_vision/ImageEmbeddingsModule.js.map +1 -1
- package/lib/module/modules/computer_vision/ImageSegmentationModule.js +2 -2
- package/lib/module/modules/computer_vision/ImageSegmentationModule.js.map +1 -1
- package/lib/module/modules/computer_vision/ObjectDetectionModule.js +2 -2
- package/lib/module/modules/computer_vision/ObjectDetectionModule.js.map +1 -1
- package/lib/module/modules/computer_vision/StyleTransferModule.js +2 -2
- package/lib/module/modules/computer_vision/StyleTransferModule.js.map +1 -1
- package/lib/module/modules/general/ExecutorchModule.js +2 -2
- package/lib/module/modules/general/ExecutorchModule.js.map +1 -1
- package/lib/module/modules/natural_language_processing/TextEmbeddingsModule.js +2 -2
- package/lib/module/modules/natural_language_processing/TextEmbeddingsModule.js.map +1 -1
- package/lib/module/native/RnExecutorchModules.js +1 -2
- package/lib/module/native/RnExecutorchModules.js.map +1 -1
- package/lib/module/utils/SpeechToTextModule/ASR.js +3 -3
- package/lib/module/utils/SpeechToTextModule/ASR.js.map +1 -1
- package/lib/modules/computer_vision/OCRModule.d.ts +4 -5
- package/lib/modules/computer_vision/OCRModule.js +9 -12
- package/lib/modules/computer_vision/VerticalOCRModule.d.ts +4 -5
- package/lib/modules/computer_vision/VerticalOCRModule.js +9 -12
- package/lib/native/RnExecutorchModules.d.ts +5 -1
- package/lib/native/RnExecutorchModules.js +3 -1
- package/lib/tsconfig.tsbuildinfo +1 -0
- package/lib/types/common.d.ts +1 -0
- package/lib/typescript/controllers/LLMController.d.ts +1 -1
- package/lib/typescript/controllers/LLMController.d.ts.map +1 -1
- package/lib/typescript/hooks/useModule.d.ts +8 -5
- package/lib/typescript/hooks/useModule.d.ts.map +1 -1
- package/lib/typescript/index.d.ts +1 -0
- package/lib/typescript/index.d.ts.map +1 -1
- package/lib/typescript/modules/BaseModule.d.ts +7 -6
- package/lib/typescript/modules/BaseModule.d.ts.map +1 -1
- package/lib/typescript/modules/computer_vision/ClassificationModule.d.ts +2 -2
- package/lib/typescript/modules/computer_vision/ClassificationModule.d.ts.map +1 -1
- package/lib/typescript/modules/computer_vision/ImageEmbeddingsModule.d.ts +2 -2
- package/lib/typescript/modules/computer_vision/ImageEmbeddingsModule.d.ts.map +1 -1
- package/lib/typescript/modules/computer_vision/ImageSegmentationModule.d.ts +2 -2
- package/lib/typescript/modules/computer_vision/ImageSegmentationModule.d.ts.map +1 -1
- package/lib/typescript/modules/computer_vision/ObjectDetectionModule.d.ts +2 -2
- package/lib/typescript/modules/computer_vision/ObjectDetectionModule.d.ts.map +1 -1
- package/lib/typescript/modules/computer_vision/StyleTransferModule.d.ts +2 -2
- package/lib/typescript/modules/computer_vision/StyleTransferModule.d.ts.map +1 -1
- package/lib/typescript/modules/general/ExecutorchModule.d.ts +2 -2
- package/lib/typescript/modules/general/ExecutorchModule.d.ts.map +1 -1
- package/lib/typescript/modules/natural_language_processing/TextEmbeddingsModule.d.ts +2 -2
- package/lib/typescript/modules/natural_language_processing/TextEmbeddingsModule.d.ts.map +1 -1
- package/lib/typescript/native/RnExecutorchModules.d.ts +1 -3
- package/lib/typescript/native/RnExecutorchModules.d.ts.map +1 -1
- package/lib/utils/ResourceFetcherUtils.js +0 -1
- package/lib/utils/llm.js +0 -1
- package/package.json +1 -2
- package/react-native-executorch.podspec +47 -44
- package/src/controllers/LLMController.ts +8 -13
- package/src/hooks/computer_vision/useClassification.ts +2 -2
- package/src/hooks/computer_vision/useImageEmbeddings.ts +2 -2
- package/src/hooks/computer_vision/useImageSegmentation.ts +2 -2
- package/src/hooks/computer_vision/useObjectDetection.ts +2 -2
- package/src/hooks/computer_vision/useStyleTransfer.ts +2 -2
- package/src/hooks/general/useExecutorchModule.ts +2 -2
- package/src/hooks/natural_language_processing/useTextEmbeddings.ts +2 -2
- package/src/hooks/useModule.ts +23 -13
- package/src/index.ts +3 -2
- package/src/modules/BaseModule.ts +17 -28
- package/src/modules/computer_vision/ClassificationModule.ts +2 -2
- package/src/modules/computer_vision/ImageEmbeddingsModule.ts +2 -2
- package/src/modules/computer_vision/ImageSegmentationModule.ts +2 -2
- package/src/modules/computer_vision/ObjectDetectionModule.ts +2 -2
- package/src/modules/computer_vision/StyleTransferModule.ts +2 -2
- package/src/modules/general/ExecutorchModule.ts +2 -2
- package/src/modules/natural_language_processing/TextEmbeddingsModule.ts +2 -2
- package/src/native/RnExecutorchModules.ts +1 -5
- package/src/utils/SpeechToTextModule/ASR.ts +4 -4
- package/third-party/android/libs/cpuinfo/arm64-v8a/libcpuinfo.so +0 -0
- package/third-party/android/libs/pthreadpool/arm64-v8a/libpthreadpool.so +0 -0
- package/third-party/include/cpuinfo/cpuinfo.h +2305 -0
- package/third-party/include/executorch/extension/threadpool/cpuinfo_utils.h +26 -0
- package/third-party/include/executorch/extension/threadpool/threadpool.h +94 -0
- package/third-party/include/pthreadpool/pthreadpool.h +2236 -0
- package/android/src/main/java/com/swmansion/rnexecutorch/LLM.kt +0 -63
- package/ios/ExecutorchLib.xcframework/Info.plist +0 -43
- package/ios/ExecutorchLib.xcframework/ios-arm64/ExecutorchLib.framework/Headers/ETModel.h +0 -27
- package/ios/ExecutorchLib.xcframework/ios-arm64/ExecutorchLib.framework/Headers/HuggingFaceTokenizer.h +0 -14
- package/ios/ExecutorchLib.xcframework/ios-arm64/ExecutorchLib.framework/Headers/LLaMARunner.h +0 -32
- package/ios/ExecutorchLib.xcframework/ios-arm64/ExecutorchLib.framework/Info.plist +0 -0
- package/ios/ExecutorchLib.xcframework/ios-arm64-simulator/ExecutorchLib.framework/Headers/ETModel.h +0 -27
- package/ios/ExecutorchLib.xcframework/ios-arm64-simulator/ExecutorchLib.framework/Headers/HuggingFaceTokenizer.h +0 -14
- package/ios/ExecutorchLib.xcframework/ios-arm64-simulator/ExecutorchLib.framework/Headers/LLaMARunner.h +0 -32
- package/ios/ExecutorchLib.xcframework/ios-arm64-simulator/ExecutorchLib.framework/Info.plist +0 -0
- package/ios/RnExecutorch/LLM.h +0 -5
- package/ios/RnExecutorch/LLM.mm +0 -78
- package/lib/Error.d.ts +0 -30
- package/lib/constants/directories.d.ts +0 -1
- package/lib/constants/ocr/symbols.d.ts +0 -75
- package/lib/controllers/OCRController.d.ts +0 -23
- package/lib/controllers/VerticalOCRController.d.ts +0 -25
- package/lib/hooks/useModule.d.ts +0 -17
- package/lib/module/modules/BaseNonStaticModule.js +0 -17
- package/lib/module/modules/BaseNonStaticModule.js.map +0 -1
- package/lib/module/native/NativeLLM.js +0 -5
- package/lib/module/native/NativeLLM.js.map +0 -1
- package/lib/modules/BaseModule.d.ts +0 -8
- package/lib/modules/BaseNonStaticModule.d.ts +0 -9
- package/lib/native/NativeETInstaller.d.ts +0 -6
- package/lib/native/NativeOCR.d.ts +0 -8
- package/lib/native/NativeVerticalOCR.d.ts +0 -8
- package/lib/types/imageSegmentation.d.ts +0 -24
- package/lib/types/objectDetection.d.ts +0 -104
- package/lib/types/ocr.d.ts +0 -11
- package/lib/typescript/modules/BaseNonStaticModule.d.ts +0 -10
- package/lib/typescript/modules/BaseNonStaticModule.d.ts.map +0 -1
- package/lib/typescript/native/NativeLLM.d.ts +0 -12
- package/lib/typescript/native/NativeLLM.d.ts.map +0 -1
- package/lib/utils/stt.d.ts +0 -1
- package/src/modules/BaseNonStaticModule.ts +0 -26
- package/src/native/NativeLLM.ts +0 -14
- package/third-party/include/tokenizers-cpp/tokenizers_c.h +0 -61
- package/third-party/ios/ExecutorchLib/ExecutorchLib/Exported/ETModel.h +0 -27
- package/third-party/ios/ExecutorchLib/ExecutorchLib/Exported/ETModel.mm +0 -249
- package/third-party/ios/ExecutorchLib/ExecutorchLib/Exported/HuggingFaceTokenizer.h +0 -14
- package/third-party/ios/ExecutorchLib/ExecutorchLib/Exported/HuggingFaceTokenizer.mm +0 -80
- package/third-party/ios/ExecutorchLib/ExecutorchLib/Exported/LLaMARunner.h +0 -32
- package/third-party/ios/ExecutorchLib/ExecutorchLib/Exported/LLaMARunner.mm +0 -95
- package/third-party/ios/ExecutorchLib/ExecutorchLib/InputType.h +0 -12
- package/third-party/ios/ExecutorchLib/ExecutorchLib/Utils.hpp +0 -217
- package/third-party/ios/ExecutorchLib/ExecutorchLib/model/Model.cpp +0 -11
- package/third-party/ios/ExecutorchLib/ExecutorchLib/model/Model.h +0 -11
- package/third-party/ios/ExecutorchLib/ExecutorchLib/tokenizer/base64.h +0 -202
- package/third-party/ios/ExecutorchLib/ExecutorchLib/tokenizer/bpe_tokenizer.cpp +0 -313
- package/third-party/ios/ExecutorchLib/ExecutorchLib/tokenizer/bpe_tokenizer.h +0 -57
- package/third-party/ios/ExecutorchLib/ExecutorchLib/tokenizer/llama_tiktoken.cpp +0 -78
- package/third-party/ios/ExecutorchLib/ExecutorchLib/tokenizer/llama_tiktoken.h +0 -23
- package/third-party/ios/ExecutorchLib/ExecutorchLib/tokenizer/tiktoken.cpp +0 -427
- package/third-party/ios/ExecutorchLib/ExecutorchLib/tokenizer/tiktoken.h +0 -87
- package/third-party/ios/ExecutorchLib/ExecutorchLib/tokenizer/tokenizer.h +0 -76
- package/third-party/ios/ExecutorchLib/ExecutorchLib.xcodeproj/project.pbxproj +0 -683
- package/third-party/ios/ExecutorchLib/build.sh +0 -44
- package/third-party/ios/ExecutorchLib/frameworks/backend_coreml.xcframework/Info.plist +0 -43
- package/third-party/ios/ExecutorchLib/frameworks/backend_coreml.xcframework/ios-arm64/libbackend_coreml_ios.a +0 -0
- package/third-party/ios/ExecutorchLib/frameworks/backend_coreml.xcframework/ios-arm64-simulator/libbackend_coreml_simulator.a +0 -0
- package/third-party/ios/ExecutorchLib/frameworks/backend_mps.xcframework/Info.plist +0 -43
- package/third-party/ios/ExecutorchLib/frameworks/backend_xnnpack.xcframework/Info.plist +0 -43
- package/third-party/ios/ExecutorchLib/frameworks/backend_xnnpack.xcframework/ios-arm64/libbackend_xnnpack_ios.a +0 -0
- package/third-party/ios/ExecutorchLib/frameworks/backend_xnnpack.xcframework/ios-arm64-simulator/libbackend_xnnpack_simulator.a +0 -0
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/Info.plist +0 -47
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/c10/macros/Export.h +0 -163
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/c10/macros/Macros.h +0 -497
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/c10/util/BFloat16-inl.h +0 -342
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/c10/util/BFloat16-math.h +0 -266
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/c10/util/BFloat16.h +0 -125
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/c10/util/Half-inl.h +0 -347
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/c10/util/Half.h +0 -416
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/c10/util/TypeSafeSignMath.h +0 -133
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/c10/util/bit_cast.h +0 -43
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/c10/util/floating_point_utils.h +0 -33
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/c10/util/irange.h +0 -107
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/ExecuTorch.h +0 -13
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/ExecuTorchError.h +0 -16
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/ExecuTorchLog.h +0 -76
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/ExecuTorchModule.h +0 -286
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/ExecuTorchTensor.h +0 -742
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/ExecuTorchValue.h +0 -219
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/extension/module/module.h +0 -492
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/extension/tensor/tensor.h +0 -13
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/extension/tensor/tensor_accessor.h +0 -190
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/extension/tensor/tensor_ptr.h +0 -347
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/extension/tensor/tensor_ptr_maker.h +0 -653
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/backend/backend_execution_context.h +0 -71
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/backend/backend_init_context.h +0 -72
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/backend/interface.h +0 -166
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/array_ref.h +0 -235
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/data_loader.h +0 -136
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/defines.h +0 -20
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/error.h +0 -229
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/evalue.h +0 -521
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/event_tracer.h +0 -565
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/event_tracer_hooks.h +0 -323
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/event_tracer_hooks_delegate.h +0 -197
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/exec_aten/exec_aten.h +0 -147
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/exec_aten/util/dim_order_util.h +0 -263
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/exec_aten/util/scalar_type_util.h +0 -1331
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/exec_aten/util/tensor_dimension_limit.h +0 -21
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/exec_aten/util/tensor_shape_to_c_string.h +0 -69
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/exec_aten/util/tensor_util.h +0 -1250
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/freeable_buffer.h +0 -107
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/hierarchical_allocator.h +0 -107
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/memory_allocator.h +0 -198
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/named_data_map.h +0 -86
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/bfloat16.h +0 -27
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/bfloat16_math.h +0 -14
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/bits_types.h +0 -83
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/c10/c10/macros/Export.h +0 -163
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/c10/c10/macros/Macros.h +0 -497
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/c10/c10/util/BFloat16-inl.h +0 -342
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/c10/c10/util/BFloat16-math.h +0 -266
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/c10/c10/util/BFloat16.h +0 -125
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/c10/c10/util/Half-inl.h +0 -347
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/c10/c10/util/Half.h +0 -416
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/c10/c10/util/TypeSafeSignMath.h +0 -133
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/c10/c10/util/bit_cast.h +0 -43
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/c10/c10/util/floating_point_utils.h +0 -33
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/c10/c10/util/irange.h +0 -107
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/complex.h +0 -44
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/device.h +0 -70
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/half.h +0 -27
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/optional.h +0 -36
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/qint_types.h +0 -83
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/scalar.h +0 -110
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/scalar_type.h +0 -154
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/string_view.h +0 -29
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/tensor.h +0 -142
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/tensor_impl.h +0 -261
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/portable_type/tensor_options.h +0 -60
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/result.h +0 -258
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/span.h +0 -93
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/tag.h +0 -71
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/tensor_layout.h +0 -79
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/core/tensor_shape_dynamism.h +0 -39
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/executor/memory_manager.h +0 -113
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/executor/method.h +0 -387
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/executor/method_meta.h +0 -251
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/executor/program.h +0 -320
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/executor/pte_data_map.h +0 -144
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/executor/tensor_parser.h +0 -156
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/kernel/kernel_runtime_context.h +0 -122
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/kernel/operator_registry.h +0 -278
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/platform/abort.h +0 -36
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/platform/assert.h +0 -119
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/platform/clock.h +0 -43
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/platform/compat_unistd.h +0 -75
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/platform/compiler.h +0 -191
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/platform/log.h +0 -177
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/platform/platform.h +0 -133
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/platform/profiler.h +0 -292
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/platform/runtime.h +0 -35
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/platform/system.h +0 -49
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/runtime/platform/types.h +0 -24
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/executorch/schema/extended_header.h +0 -76
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/Headers/module.modulemap +0 -5
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64/libexecutorch_ios.a +0 -0
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/c10/macros/Export.h +0 -163
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/c10/macros/Macros.h +0 -497
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/c10/util/BFloat16-inl.h +0 -342
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/c10/util/BFloat16-math.h +0 -266
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/c10/util/BFloat16.h +0 -125
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/c10/util/Half-inl.h +0 -347
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/c10/util/Half.h +0 -416
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/c10/util/TypeSafeSignMath.h +0 -133
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/c10/util/bit_cast.h +0 -43
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/c10/util/floating_point_utils.h +0 -33
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/c10/util/irange.h +0 -107
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/ExecuTorch.h +0 -13
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/ExecuTorchError.h +0 -16
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/ExecuTorchLog.h +0 -76
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/ExecuTorchModule.h +0 -286
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/ExecuTorchTensor.h +0 -742
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/ExecuTorchValue.h +0 -219
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/extension/module/module.h +0 -492
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/extension/tensor/tensor.h +0 -13
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/extension/tensor/tensor_accessor.h +0 -190
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/extension/tensor/tensor_ptr.h +0 -347
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/extension/tensor/tensor_ptr_maker.h +0 -653
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/backend/backend_execution_context.h +0 -71
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/backend/backend_init_context.h +0 -72
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/backend/interface.h +0 -166
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/array_ref.h +0 -235
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/data_loader.h +0 -136
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/defines.h +0 -20
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/error.h +0 -229
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/evalue.h +0 -521
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/event_tracer.h +0 -565
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/event_tracer_hooks.h +0 -323
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/event_tracer_hooks_delegate.h +0 -197
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/exec_aten/exec_aten.h +0 -147
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/exec_aten/util/dim_order_util.h +0 -263
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/exec_aten/util/scalar_type_util.h +0 -1331
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/exec_aten/util/tensor_dimension_limit.h +0 -21
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/exec_aten/util/tensor_shape_to_c_string.h +0 -69
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/exec_aten/util/tensor_util.h +0 -1250
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/freeable_buffer.h +0 -107
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/hierarchical_allocator.h +0 -107
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/memory_allocator.h +0 -198
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/named_data_map.h +0 -86
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/bfloat16.h +0 -27
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/bfloat16_math.h +0 -14
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/bits_types.h +0 -83
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/c10/c10/macros/Export.h +0 -163
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/c10/c10/macros/Macros.h +0 -497
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/c10/c10/util/BFloat16-inl.h +0 -342
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/c10/c10/util/BFloat16-math.h +0 -266
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/c10/c10/util/BFloat16.h +0 -125
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/c10/c10/util/Half-inl.h +0 -347
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/c10/c10/util/Half.h +0 -416
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/c10/c10/util/TypeSafeSignMath.h +0 -133
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/c10/c10/util/bit_cast.h +0 -43
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/c10/c10/util/floating_point_utils.h +0 -33
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/c10/c10/util/irange.h +0 -107
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/complex.h +0 -44
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/device.h +0 -70
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/half.h +0 -27
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/optional.h +0 -36
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/qint_types.h +0 -83
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/scalar.h +0 -110
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/scalar_type.h +0 -154
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/string_view.h +0 -29
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/tensor.h +0 -142
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/tensor_impl.h +0 -261
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/portable_type/tensor_options.h +0 -60
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/result.h +0 -258
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/span.h +0 -93
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/tag.h +0 -71
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/tensor_layout.h +0 -79
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/core/tensor_shape_dynamism.h +0 -39
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/executor/memory_manager.h +0 -113
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/executor/method.h +0 -387
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/executor/method_meta.h +0 -251
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/executor/program.h +0 -320
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/executor/pte_data_map.h +0 -144
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/executor/tensor_parser.h +0 -156
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/kernel/kernel_runtime_context.h +0 -122
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/kernel/operator_registry.h +0 -278
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/platform/abort.h +0 -36
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/platform/assert.h +0 -119
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/platform/clock.h +0 -43
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/platform/compat_unistd.h +0 -75
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/platform/compiler.h +0 -191
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/platform/log.h +0 -177
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/platform/platform.h +0 -133
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/platform/profiler.h +0 -292
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/platform/runtime.h +0 -35
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/platform/system.h +0 -49
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/runtime/platform/types.h +0 -24
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/executorch/schema/extended_header.h +0 -76
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/Headers/module.modulemap +0 -5
- package/third-party/ios/ExecutorchLib/frameworks/executorch.xcframework/ios-arm64-simulator/libexecutorch_simulator.a +0 -0
- package/third-party/ios/ExecutorchLib/frameworks/kernels_custom.xcframework/Info.plist +0 -43
- package/third-party/ios/ExecutorchLib/frameworks/kernels_custom.xcframework/ios-arm64/libkernels_custom_ios.a +0 -0
- package/third-party/ios/ExecutorchLib/frameworks/kernels_custom.xcframework/ios-arm64-simulator/libkernels_custom_simulator.a +0 -0
- package/third-party/ios/ExecutorchLib/frameworks/kernels_optimized.xcframework/Info.plist +0 -43
- package/third-party/ios/ExecutorchLib/frameworks/kernels_optimized.xcframework/ios-arm64/libkernels_optimized_ios.a +0 -0
- package/third-party/ios/ExecutorchLib/frameworks/kernels_optimized.xcframework/ios-arm64-simulator/libkernels_optimized_simulator.a +0 -0
- package/third-party/ios/ExecutorchLib/frameworks/kernels_portable.xcframework/Info.plist +0 -43
- package/third-party/ios/ExecutorchLib/frameworks/kernels_portable.xcframework/ios-arm64/libkernels_portable_ios.a +0 -0
- package/third-party/ios/ExecutorchLib/frameworks/kernels_portable.xcframework/ios-arm64-simulator/libkernels_portable_simulator.a +0 -0
- package/third-party/ios/ExecutorchLib/frameworks/kernels_quantized.xcframework/Info.plist +0 -43
- package/third-party/ios/ExecutorchLib/frameworks/kernels_quantized.xcframework/ios-arm64/libkernels_quantized_ios.a +0 -0
- package/third-party/ios/ExecutorchLib/frameworks/kernels_quantized.xcframework/ios-arm64-simulator/libkernels_quantized_simulator.a +0 -0
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/Info.plist +0 -43
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64/re2.framework/Headers/bitmap256.h +0 -82
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64/re2.framework/Headers/filtered_re2.h +0 -111
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64/re2.framework/Headers/pod_array.h +0 -43
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64/re2.framework/Headers/prefilter.h +0 -130
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64/re2.framework/Headers/prefilter_tree.h +0 -139
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64/re2.framework/Headers/prog.h +0 -483
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64/re2.framework/Headers/re2.h +0 -994
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64/re2.framework/Headers/regexp.h +0 -692
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64/re2.framework/Headers/set.h +0 -85
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64/re2.framework/Headers/sparse_array.h +0 -367
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64/re2.framework/Headers/sparse_set.h +0 -241
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64/re2.framework/Headers/stringpiece.h +0 -205
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64/re2.framework/Headers/unicode_casefold.h +0 -78
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64/re2.framework/Headers/unicode_groups.h +0 -64
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64/re2.framework/Headers/walker-inl.h +0 -235
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64/re2.framework/Info.plist +0 -26
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64/re2.framework/re2 +0 -0
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64-simulator/re2.framework/Headers/bitmap256.h +0 -82
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64-simulator/re2.framework/Headers/filtered_re2.h +0 -111
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64-simulator/re2.framework/Headers/pod_array.h +0 -43
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64-simulator/re2.framework/Headers/prefilter.h +0 -130
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64-simulator/re2.framework/Headers/prefilter_tree.h +0 -139
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64-simulator/re2.framework/Headers/prog.h +0 -483
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64-simulator/re2.framework/Headers/re2.h +0 -994
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64-simulator/re2.framework/Headers/regexp.h +0 -692
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64-simulator/re2.framework/Headers/set.h +0 -85
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64-simulator/re2.framework/Headers/sparse_array.h +0 -367
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64-simulator/re2.framework/Headers/sparse_set.h +0 -241
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64-simulator/re2.framework/Headers/stringpiece.h +0 -205
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64-simulator/re2.framework/Headers/unicode_casefold.h +0 -78
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64-simulator/re2.framework/Headers/unicode_groups.h +0 -64
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64-simulator/re2.framework/Headers/walker-inl.h +0 -235
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64-simulator/re2.framework/Info.plist +0 -26
- package/third-party/ios/ExecutorchLib/frameworks/re2.xcframework/ios-arm64-simulator/re2.framework/re2 +0 -0
- /package/{third-party/ios/ExecutorchLib/ExecutorchLib → common}/runner/irunner.h +0 -0
- /package/{third-party/ios/ExecutorchLib/ExecutorchLib → common}/runner/runner.cpp +0 -0
- /package/{third-party/ios/ExecutorchLib/ExecutorchLib → common}/runner/runner.h +0 -0
- /package/{third-party/ios/ExecutorchLib/ExecutorchLib → common}/runner/stats.h +0 -0
- /package/{third-party/ios/ExecutorchLib/ExecutorchLib → common}/runner/text_decoder_runner.cpp +0 -0
- /package/{third-party/ios/ExecutorchLib/ExecutorchLib → common}/runner/text_decoder_runner.h +0 -0
- /package/{third-party/ios/ExecutorchLib/ExecutorchLib → common}/runner/text_prefiller.cpp +0 -0
- /package/{third-party/ios/ExecutorchLib/ExecutorchLib → common}/runner/text_prefiller.h +0 -0
- /package/{third-party/ios/ExecutorchLib/ExecutorchLib → common}/runner/text_token_generator.h +0 -0
- /package/{third-party/ios/ExecutorchLib/ExecutorchLib → common}/runner/util.h +0 -0
|
@@ -1,258 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
3
|
-
* All rights reserved.
|
|
4
|
-
*
|
|
5
|
-
* This source code is licensed under the BSD-style license found in the
|
|
6
|
-
* LICENSE file in the root directory of this source tree.
|
|
7
|
-
*/
|
|
8
|
-
|
|
9
|
-
/**
|
|
10
|
-
* @file
|
|
11
|
-
* Result type to be used in conjunction with ExecuTorch Error type.
|
|
12
|
-
*/
|
|
13
|
-
|
|
14
|
-
#pragma once
|
|
15
|
-
|
|
16
|
-
#include <new>
|
|
17
|
-
#include <utility>
|
|
18
|
-
|
|
19
|
-
#include "executorch/runtime/core/error.h"
|
|
20
|
-
#include "executorch/runtime/platform/assert.h"
|
|
21
|
-
|
|
22
|
-
namespace executorch {
|
|
23
|
-
namespace runtime {
|
|
24
|
-
|
|
25
|
-
/**
|
|
26
|
-
* Result type wrapping either a value of type T or an error.
|
|
27
|
-
*
|
|
28
|
-
* Example use case:
|
|
29
|
-
* @code
|
|
30
|
-
* Result<OpFn> getOp(int opcode) {
|
|
31
|
-
* if (isValidOpCode(opcode)) {
|
|
32
|
-
* return opFns[opcode];
|
|
33
|
-
* }
|
|
34
|
-
* return Error::NotFound;
|
|
35
|
-
* }
|
|
36
|
-
*
|
|
37
|
-
* Error useOp(int opcode) {
|
|
38
|
-
* Result<OpFn> op = getOp(opcode);
|
|
39
|
-
* if (!op.ok()) {
|
|
40
|
-
* return op.error();
|
|
41
|
-
* }
|
|
42
|
-
* print(op->toString());
|
|
43
|
-
* execute(*op);
|
|
44
|
-
* return Error::Ok;
|
|
45
|
-
* }
|
|
46
|
-
* @endcode
|
|
47
|
-
*/
|
|
48
|
-
template <typename T> class Result final {
|
|
49
|
-
public:
|
|
50
|
-
/// `value_type` member for generic programming.
|
|
51
|
-
typedef T value_type;
|
|
52
|
-
|
|
53
|
-
/**
|
|
54
|
-
* Creates a Result object from an Error.
|
|
55
|
-
*
|
|
56
|
-
* To preserve the invariant that `(result.error() == Error::Ok) ==
|
|
57
|
-
* result.ok()`, an `error` parameter value of `Error:Ok` will be converted to
|
|
58
|
-
* a non-Ok value.
|
|
59
|
-
*/
|
|
60
|
-
/* implicit */ Result(Error error)
|
|
61
|
-
: error_(error == Error::Ok ? Error::Internal : error), hasValue_(false) {
|
|
62
|
-
if ET_UNLIKELY (error == Error::Ok) {
|
|
63
|
-
ET_LOG(Debug, "Attempted to create Result from Error::Ok, this has been "
|
|
64
|
-
"converted to Error::Internal.");
|
|
65
|
-
}
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
/// Value copy constructor.
|
|
69
|
-
/* implicit */ Result(const T &val) : value_(val), hasValue_(true) {}
|
|
70
|
-
|
|
71
|
-
/// Value move constructor.
|
|
72
|
-
/* implicit */ Result(T &&val) : value_(std::move(val)), hasValue_(true) {}
|
|
73
|
-
|
|
74
|
-
/// Result move constructor.
|
|
75
|
-
/* implicit */ Result(Result &&rhs) noexcept : hasValue_(rhs.hasValue_) {
|
|
76
|
-
if (hasValue_) {
|
|
77
|
-
// Use the value type's move constructor.
|
|
78
|
-
new (&value_) T(std::move(rhs.value_));
|
|
79
|
-
} else {
|
|
80
|
-
error_ = rhs.error_;
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
~Result() {
|
|
85
|
-
if (hasValue_) {
|
|
86
|
-
// Manual value destruction.
|
|
87
|
-
// Result "owns" the memory, so `delete` would segfault.
|
|
88
|
-
value_.~T();
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
/**
|
|
93
|
-
* Returns true if this Result has a value.
|
|
94
|
-
*
|
|
95
|
-
* If true, it is guaranteed that `error()` will return `Error::Ok`.
|
|
96
|
-
* If false, it is guaranteed that `error()` will not return `Error::Ok`.
|
|
97
|
-
*/
|
|
98
|
-
ET_NODISCARD bool ok() const { return hasValue_; }
|
|
99
|
-
|
|
100
|
-
/**
|
|
101
|
-
* Returns the error code of this Result.
|
|
102
|
-
*
|
|
103
|
-
* If this returns `Error::Ok`, it is guaranteed that `ok()` will return true.
|
|
104
|
-
* If this does not return `Error:Ok`, it is guaranteed that `ok()` will
|
|
105
|
-
* return false.
|
|
106
|
-
*/
|
|
107
|
-
ET_NODISCARD Error error() const {
|
|
108
|
-
if (hasValue_) {
|
|
109
|
-
return Error::Ok;
|
|
110
|
-
} else {
|
|
111
|
-
return error_;
|
|
112
|
-
}
|
|
113
|
-
}
|
|
114
|
-
|
|
115
|
-
/**
|
|
116
|
-
* Returns a reference to the Result's value; longhand for operator*().
|
|
117
|
-
*
|
|
118
|
-
* Only legal to call if `ok()` returns true.
|
|
119
|
-
*/
|
|
120
|
-
T &get() {
|
|
121
|
-
CheckOk();
|
|
122
|
-
return value_;
|
|
123
|
-
}
|
|
124
|
-
|
|
125
|
-
/**
|
|
126
|
-
* Returns a reference to the Result's value; longhand for operator*().
|
|
127
|
-
*
|
|
128
|
-
* Only legal to call if `ok()` returns true.
|
|
129
|
-
*/
|
|
130
|
-
const T &get() const {
|
|
131
|
-
CheckOk();
|
|
132
|
-
return value_;
|
|
133
|
-
}
|
|
134
|
-
|
|
135
|
-
/*
|
|
136
|
-
* Returns a reference to the Result's value; shorthand for get().
|
|
137
|
-
*
|
|
138
|
-
* Only legal to call if `ok()` returns true.
|
|
139
|
-
*/
|
|
140
|
-
const T &operator*() const &;
|
|
141
|
-
T &operator*() &;
|
|
142
|
-
|
|
143
|
-
/*
|
|
144
|
-
* Returns a pointer to the Result's value.
|
|
145
|
-
*
|
|
146
|
-
* Only legal to call if `ok()` returns true.
|
|
147
|
-
*/
|
|
148
|
-
const T *operator->() const;
|
|
149
|
-
T *operator->();
|
|
150
|
-
|
|
151
|
-
private:
|
|
152
|
-
/**
|
|
153
|
-
* Delete default constructor since all Results should contain a value or
|
|
154
|
-
* error.
|
|
155
|
-
*/
|
|
156
|
-
Result() = delete;
|
|
157
|
-
/// Delete copy constructor since T may not be copyable.
|
|
158
|
-
Result(const Result &) = delete;
|
|
159
|
-
/// Delete copy assignment since T may not be copyable.
|
|
160
|
-
Result &operator=(const Result &) = delete;
|
|
161
|
-
/// Delete move assignment since it's not a supported pattern to reuse Result.
|
|
162
|
-
Result &operator=(Result &&rhs) = delete;
|
|
163
|
-
|
|
164
|
-
// Panics if ok() would return false;
|
|
165
|
-
void CheckOk() const { ET_CHECK(hasValue_); }
|
|
166
|
-
|
|
167
|
-
union {
|
|
168
|
-
T value_; // Used if hasValue_ is true.
|
|
169
|
-
Error error_; // Used if hasValue_ is false.
|
|
170
|
-
};
|
|
171
|
-
|
|
172
|
-
/// True if the Result contains a value.
|
|
173
|
-
const bool hasValue_;
|
|
174
|
-
};
|
|
175
|
-
|
|
176
|
-
template <typename T> const T &Result<T>::operator*() const & {
|
|
177
|
-
CheckOk();
|
|
178
|
-
return value_;
|
|
179
|
-
}
|
|
180
|
-
|
|
181
|
-
template <typename T> T &Result<T>::operator*() & {
|
|
182
|
-
CheckOk();
|
|
183
|
-
return value_;
|
|
184
|
-
}
|
|
185
|
-
|
|
186
|
-
template <typename T> const T *Result<T>::operator->() const {
|
|
187
|
-
CheckOk();
|
|
188
|
-
return &value_;
|
|
189
|
-
}
|
|
190
|
-
|
|
191
|
-
template <typename T> T *Result<T>::operator->() {
|
|
192
|
-
CheckOk();
|
|
193
|
-
return &value_;
|
|
194
|
-
}
|
|
195
|
-
|
|
196
|
-
} // namespace runtime
|
|
197
|
-
} // namespace executorch
|
|
198
|
-
|
|
199
|
-
namespace torch {
|
|
200
|
-
namespace executor {
|
|
201
|
-
// TODO(T197294990): Remove these deprecated aliases once all users have moved
|
|
202
|
-
// to the new `::executorch` namespaces.
|
|
203
|
-
using ::executorch::runtime::Result;
|
|
204
|
-
} // namespace executor
|
|
205
|
-
} // namespace torch
|
|
206
|
-
|
|
207
|
-
/**
|
|
208
|
-
* Unwrap a Result to obtain its value. If the Result contains an error,
|
|
209
|
-
* propogate the error via trivial function return.
|
|
210
|
-
*
|
|
211
|
-
* Note: A function using ET_UNWRAP should itself return a Result or Error.
|
|
212
|
-
*
|
|
213
|
-
* @param[in] result__ Expression yielding the result to unwrap.
|
|
214
|
-
* @param[in] ... Optional format string for the log error message and its
|
|
215
|
-
* arguments.
|
|
216
|
-
*/
|
|
217
|
-
#define ET_UNWRAP(result__, ...) ET_INTERNAL_UNWRAP(result__, ##__VA_ARGS__)
|
|
218
|
-
|
|
219
|
-
// Internal only: Use ET_UNWRAP() instead.
|
|
220
|
-
#define ET_INTERNAL_UNWRAP(...) \
|
|
221
|
-
ET_INTERNAL_UNWRAP_SELECT(__VA_ARGS__, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1) \
|
|
222
|
-
(__VA_ARGS__)
|
|
223
|
-
|
|
224
|
-
// Internal only: Use ET_UNWRAP() instead.
|
|
225
|
-
#define ET_INTERNAL_UNWRAP_SELECT(_1, _2, _3, _4, _5, _6, _7, _8, _9, _10, N, \
|
|
226
|
-
...) \
|
|
227
|
-
ET_INTERNAL_UNWRAP_##N
|
|
228
|
-
|
|
229
|
-
// Internal only: Use ET_UNWRAP() instead.
|
|
230
|
-
#define ET_INTERNAL_UNWRAP_1(result__) \
|
|
231
|
-
({ \
|
|
232
|
-
auto et_result__ = (result__); \
|
|
233
|
-
if (!et_result__.ok()) { \
|
|
234
|
-
return et_result__.error(); \
|
|
235
|
-
} \
|
|
236
|
-
std::move(*et_result__); \
|
|
237
|
-
})
|
|
238
|
-
|
|
239
|
-
// Internal only: Use ET_UNWRAP() instead.
|
|
240
|
-
#define ET_INTERNAL_UNWRAP_2(result__, message__, ...) \
|
|
241
|
-
({ \
|
|
242
|
-
auto et_result__ = (result__); \
|
|
243
|
-
if (!et_result__.ok()) { \
|
|
244
|
-
ET_LOG(Error, message__, ##__VA_ARGS__); \
|
|
245
|
-
return et_result__.error(); \
|
|
246
|
-
} \
|
|
247
|
-
std::move(*et_result__); \
|
|
248
|
-
})
|
|
249
|
-
|
|
250
|
-
// Internal only: Use ET_UNWRAP() instead.
|
|
251
|
-
#define ET_INTERNAL_UNWRAP_3 ET_INTERNAL_UNWRAP_2
|
|
252
|
-
#define ET_INTERNAL_UNWRAP_4 ET_INTERNAL_UNWRAP_2
|
|
253
|
-
#define ET_INTERNAL_UNWRAP_5 ET_INTERNAL_UNWRAP_2
|
|
254
|
-
#define ET_INTERNAL_UNWRAP_6 ET_INTERNAL_UNWRAP_2
|
|
255
|
-
#define ET_INTERNAL_UNWRAP_7 ET_INTERNAL_UNWRAP_2
|
|
256
|
-
#define ET_INTERNAL_UNWRAP_8 ET_INTERNAL_UNWRAP_2
|
|
257
|
-
#define ET_INTERNAL_UNWRAP_9 ET_INTERNAL_UNWRAP_2
|
|
258
|
-
#define ET_INTERNAL_UNWRAP_10 ET_INTERNAL_UNWRAP_2
|
|
@@ -1,93 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
3
|
-
* All rights reserved.
|
|
4
|
-
*
|
|
5
|
-
* This source code is licensed under the BSD-style license found in the
|
|
6
|
-
* LICENSE file in the root directory of this source tree.
|
|
7
|
-
*/
|
|
8
|
-
|
|
9
|
-
#pragma once
|
|
10
|
-
|
|
11
|
-
#include <cstdint>
|
|
12
|
-
|
|
13
|
-
#include <executorch/runtime/platform/assert.h>
|
|
14
|
-
|
|
15
|
-
namespace executorch {
|
|
16
|
-
namespace runtime {
|
|
17
|
-
|
|
18
|
-
/**
|
|
19
|
-
* Represent a reference to an array (0 or more elements
|
|
20
|
-
* consecutively in memory), i.e. a start pointer and a length. It allows
|
|
21
|
-
* various APIs to take consecutive elements easily and conveniently.
|
|
22
|
-
*
|
|
23
|
-
* This class does not own the underlying data, it is expected to be used in
|
|
24
|
-
* situations where the data resides in some other buffer, whose lifetime
|
|
25
|
-
* extends past that of the Span.
|
|
26
|
-
*
|
|
27
|
-
* Span and ArrayRef are extrememly similar with the difference being ArrayRef
|
|
28
|
-
* views a list of constant elements and Span views a list of mutable elements.
|
|
29
|
-
* Clients should decide between the two based on if the list elements for their
|
|
30
|
-
* use case should be mutable.
|
|
31
|
-
*
|
|
32
|
-
* This is intended to be trivially copyable, so it should be passed by
|
|
33
|
-
* value.
|
|
34
|
-
*/
|
|
35
|
-
template <typename T> class Span final {
|
|
36
|
-
public:
|
|
37
|
-
using value_type = T;
|
|
38
|
-
using iterator = T *;
|
|
39
|
-
using size_type = size_t;
|
|
40
|
-
|
|
41
|
-
public:
|
|
42
|
-
/// Construct an empty Span.
|
|
43
|
-
/* implicit */ constexpr Span() noexcept : data_(nullptr), length_(0) {}
|
|
44
|
-
|
|
45
|
-
/// Construct a Span from a pointer and length.
|
|
46
|
-
Span(T *data, size_t length) : data_(data), length_(length) {
|
|
47
|
-
ET_DCHECK(data_ != nullptr || length_ == 0);
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
/// Construct a Span from a range.
|
|
51
|
-
Span(T *begin, T *end) : data_(begin), length_(end - begin) {}
|
|
52
|
-
|
|
53
|
-
/// Construct a Span from a C array.
|
|
54
|
-
template <size_t N>
|
|
55
|
-
/* implicit */ constexpr Span(T (&Arr)[N]) : data_(Arr), length_(N) {}
|
|
56
|
-
|
|
57
|
-
/// @returns a pointer to the start of the underlying element buffer.
|
|
58
|
-
iterator begin() const noexcept { return data_; }
|
|
59
|
-
|
|
60
|
-
/// @returns a pointer to the end of the underlying element buffer.
|
|
61
|
-
iterator end() const noexcept { return data_ + length_; }
|
|
62
|
-
|
|
63
|
-
/// @retval a boolean indicating if the Span is empty.
|
|
64
|
-
constexpr bool empty() const noexcept { return length_ == 0; }
|
|
65
|
-
|
|
66
|
-
/// @returns a pointer to the start of the underlying element buffer.
|
|
67
|
-
constexpr T *data() const noexcept { return data_; }
|
|
68
|
-
|
|
69
|
-
/// @returns the number of elements in the Span.
|
|
70
|
-
constexpr size_t size() const noexcept { return length_; }
|
|
71
|
-
|
|
72
|
-
/// Unchecked index into the array according to the argument index.
|
|
73
|
-
/// @returns a reference to the element at the specified index.
|
|
74
|
-
T &operator[](size_t index) const { return data_[index]; }
|
|
75
|
-
|
|
76
|
-
private:
|
|
77
|
-
/// The start of the array, in an external buffer.
|
|
78
|
-
T *data_;
|
|
79
|
-
|
|
80
|
-
/// The number of elements.
|
|
81
|
-
size_type length_;
|
|
82
|
-
};
|
|
83
|
-
|
|
84
|
-
} // namespace runtime
|
|
85
|
-
} // namespace executorch
|
|
86
|
-
|
|
87
|
-
namespace torch {
|
|
88
|
-
namespace executor {
|
|
89
|
-
// TODO(T197294990): Remove these deprecated aliases once all users have moved
|
|
90
|
-
// to the new `::executorch` namespaces.
|
|
91
|
-
using ::executorch::runtime::Span;
|
|
92
|
-
} // namespace executor
|
|
93
|
-
} // namespace torch
|
|
@@ -1,71 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
3
|
-
* All rights reserved.
|
|
4
|
-
*
|
|
5
|
-
* This source code is licensed under the BSD-style license found in the
|
|
6
|
-
* LICENSE file in the root directory of this source tree.
|
|
7
|
-
*/
|
|
8
|
-
|
|
9
|
-
#pragma once
|
|
10
|
-
|
|
11
|
-
#include <cstdint>
|
|
12
|
-
#include <executorch/runtime/core/defines.h>
|
|
13
|
-
#include <executorch/runtime/platform/compiler.h>
|
|
14
|
-
|
|
15
|
-
namespace executorch {
|
|
16
|
-
namespace runtime {
|
|
17
|
-
|
|
18
|
-
#define EXECUTORCH_FORALL_TAGS(_) \
|
|
19
|
-
_(None) \
|
|
20
|
-
_(Tensor) \
|
|
21
|
-
_(String) \
|
|
22
|
-
_(Double) \
|
|
23
|
-
_(Int) \
|
|
24
|
-
_(Bool) \
|
|
25
|
-
_(ListBool) \
|
|
26
|
-
_(ListDouble) \
|
|
27
|
-
_(ListInt) \
|
|
28
|
-
_(ListTensor) \
|
|
29
|
-
_(ListScalar) \
|
|
30
|
-
_(ListOptionalTensor)
|
|
31
|
-
|
|
32
|
-
/**
|
|
33
|
-
* The dynamic type of an EValue.
|
|
34
|
-
*/
|
|
35
|
-
enum class Tag : uint32_t {
|
|
36
|
-
#define DEFINE_TAG(x) x,
|
|
37
|
-
EXECUTORCH_FORALL_TAGS(DEFINE_TAG)
|
|
38
|
-
#undef DEFINE_TAG
|
|
39
|
-
};
|
|
40
|
-
|
|
41
|
-
/**
|
|
42
|
-
* Convert a tag value to a string representation. If ET_ENABLE_ENUM_STRINGS is
|
|
43
|
-
* set (it is on by default), this will return a string name (for example,
|
|
44
|
-
* "Tensor"). Otherwise, it will return a string representation of the index
|
|
45
|
-
* value ("1").
|
|
46
|
-
*
|
|
47
|
-
* If the user buffer is not large enough to hold the string representation, the
|
|
48
|
-
* string will be truncated.
|
|
49
|
-
*
|
|
50
|
-
* The return value is the number of characters written, or in the case of
|
|
51
|
-
* truncation, the number of characters that would be written if the buffer was
|
|
52
|
-
* large enough.
|
|
53
|
-
*/
|
|
54
|
-
size_t tag_to_string(Tag tag, char *buffer, size_t buffer_size);
|
|
55
|
-
|
|
56
|
-
/* The size of the buffer needed to hold the longest tag string, including the
|
|
57
|
-
* null terminator. This value is expected to be updated manually, but it
|
|
58
|
-
* checked in test_tag.cpp.
|
|
59
|
-
*/
|
|
60
|
-
constexpr size_t kTagNameBufferSize = 19;
|
|
61
|
-
|
|
62
|
-
} // namespace runtime
|
|
63
|
-
} // namespace executorch
|
|
64
|
-
|
|
65
|
-
namespace torch {
|
|
66
|
-
namespace executor {
|
|
67
|
-
// TODO(T197294990): Remove these deprecated aliases once all users have moved
|
|
68
|
-
// to the new `::executorch` namespaces.
|
|
69
|
-
using ::executorch::runtime::Tag;
|
|
70
|
-
} // namespace executor
|
|
71
|
-
} // namespace torch
|
|
@@ -1,79 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
3
|
-
* All rights reserved.
|
|
4
|
-
*
|
|
5
|
-
* This source code is licensed under the BSD-style license found in the
|
|
6
|
-
* LICENSE file in the root directory of this source tree.
|
|
7
|
-
*/
|
|
8
|
-
|
|
9
|
-
#pragma once
|
|
10
|
-
|
|
11
|
-
#include <executorch/runtime/core/exec_aten/exec_aten.h>
|
|
12
|
-
#include <executorch/runtime/core/exec_aten/util/scalar_type_util.h>
|
|
13
|
-
#include <executorch/runtime/core/result.h>
|
|
14
|
-
#include <executorch/runtime/core/span.h>
|
|
15
|
-
|
|
16
|
-
namespace executorch {
|
|
17
|
-
namespace runtime {
|
|
18
|
-
|
|
19
|
-
/**
|
|
20
|
-
* Describes the layout of a tensor.
|
|
21
|
-
*/
|
|
22
|
-
class ET_EXPERIMENTAL TensorLayout final {
|
|
23
|
-
public:
|
|
24
|
-
TensorLayout() = delete;
|
|
25
|
-
|
|
26
|
-
/**
|
|
27
|
-
* Creates a TensorLayout from the given parameters.
|
|
28
|
-
*
|
|
29
|
-
* @param[in] sizes The sizes of the tensor. Note: the span passed here must
|
|
30
|
-
* outlive the TensorLayout and all copies of it.
|
|
31
|
-
* @param[in] dim_order The dim order of the tensor. Note: the span passed
|
|
32
|
-
* here must outlive the TensorLayout and all copies of it.
|
|
33
|
-
* @param[in] scalar_type The scalar type of the tensor.
|
|
34
|
-
* @return A Result containing the TensorLayout on success, or an error.
|
|
35
|
-
*/
|
|
36
|
-
static executorch::runtime::Result<const TensorLayout>
|
|
37
|
-
create(Span<const int32_t> sizes, Span<const uint8_t> dim_order,
|
|
38
|
-
executorch::aten::ScalarType scalar_type);
|
|
39
|
-
|
|
40
|
-
/**
|
|
41
|
-
* Returns the sizes of the tensor.
|
|
42
|
-
*
|
|
43
|
-
* NOTE: The TensorLayout must outlive the spans returned here.
|
|
44
|
-
*/
|
|
45
|
-
Span<const int32_t> sizes() const { return sizes_; }
|
|
46
|
-
|
|
47
|
-
/**
|
|
48
|
-
* Returns the dim order of the tensor.
|
|
49
|
-
*
|
|
50
|
-
* NOTE: The TensorLayout must outlive the spans returned here.
|
|
51
|
-
*/
|
|
52
|
-
Span<const uint8_t> dim_order() const { return dim_order_; }
|
|
53
|
-
|
|
54
|
-
/// Returns the scalar type of the tensor.
|
|
55
|
-
executorch::aten::ScalarType scalar_type() const { return scalar_type_; }
|
|
56
|
-
|
|
57
|
-
/// Returns the size of the tensor in bytes.
|
|
58
|
-
size_t nbytes() const { return nbytes_; }
|
|
59
|
-
|
|
60
|
-
private:
|
|
61
|
-
TensorLayout(Span<const int32_t> sizes, Span<const uint8_t> dim_order,
|
|
62
|
-
executorch::aten::ScalarType scalar_type, size_t nbytes)
|
|
63
|
-
: sizes_(sizes), dim_order_(dim_order), scalar_type_(scalar_type),
|
|
64
|
-
nbytes_(nbytes) {}
|
|
65
|
-
/// The sizes of the tensor.
|
|
66
|
-
const Span<const int32_t> sizes_;
|
|
67
|
-
|
|
68
|
-
/// The dim order of the tensor.
|
|
69
|
-
const Span<const uint8_t> dim_order_;
|
|
70
|
-
|
|
71
|
-
/// The scalar type of the tensor.
|
|
72
|
-
const executorch::aten::ScalarType scalar_type_;
|
|
73
|
-
|
|
74
|
-
/// The size in bytes of the tensor.
|
|
75
|
-
const size_t nbytes_;
|
|
76
|
-
};
|
|
77
|
-
|
|
78
|
-
} // namespace runtime
|
|
79
|
-
} // namespace executorch
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
3
|
-
* All rights reserved.
|
|
4
|
-
*
|
|
5
|
-
* This source code is licensed under the BSD-style license found in the
|
|
6
|
-
* LICENSE file in the root directory of this source tree.
|
|
7
|
-
*/
|
|
8
|
-
|
|
9
|
-
#pragma once
|
|
10
|
-
|
|
11
|
-
#include <cstdint>
|
|
12
|
-
|
|
13
|
-
namespace executorch {
|
|
14
|
-
namespace runtime {
|
|
15
|
-
|
|
16
|
-
/**
|
|
17
|
-
* The resizing capabilities of a Tensor.
|
|
18
|
-
*
|
|
19
|
-
* The rank of an ExecuTorch Tensors can never change, but shape sometimes can.
|
|
20
|
-
*/
|
|
21
|
-
enum class TensorShapeDynamism : uint8_t {
|
|
22
|
-
/// Cannot change shape.
|
|
23
|
-
STATIC = 0,
|
|
24
|
-
/// Shape cannot exceed initial capacity.
|
|
25
|
-
DYNAMIC_BOUND = 1,
|
|
26
|
-
/// No restriction on shape and capacity.
|
|
27
|
-
DYNAMIC_UNBOUND = 2,
|
|
28
|
-
};
|
|
29
|
-
|
|
30
|
-
} // namespace runtime
|
|
31
|
-
} // namespace executorch
|
|
32
|
-
|
|
33
|
-
namespace torch {
|
|
34
|
-
namespace executor {
|
|
35
|
-
// TODO(T197294990): Remove these deprecated aliases once all users have moved
|
|
36
|
-
// to the new `::executorch` namespaces.
|
|
37
|
-
using ::executorch::runtime::TensorShapeDynamism;
|
|
38
|
-
} // namespace executor
|
|
39
|
-
} // namespace torch
|
|
@@ -1,113 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
3
|
-
* All rights reserved.
|
|
4
|
-
*
|
|
5
|
-
* This source code is licensed under the BSD-style license found in the
|
|
6
|
-
* LICENSE file in the root directory of this source tree.
|
|
7
|
-
*/
|
|
8
|
-
|
|
9
|
-
#pragma once
|
|
10
|
-
|
|
11
|
-
#include <executorch/runtime/core/hierarchical_allocator.h>
|
|
12
|
-
#include <executorch/runtime/core/memory_allocator.h>
|
|
13
|
-
|
|
14
|
-
namespace executorch {
|
|
15
|
-
namespace runtime {
|
|
16
|
-
|
|
17
|
-
/**
|
|
18
|
-
* A container class for allocators used during Method load and execution.
|
|
19
|
-
*
|
|
20
|
-
* This class consolidates all dynamic memory needs for Method load and
|
|
21
|
-
* execution. This can allow for heap-based as well as heap-less execution
|
|
22
|
-
* (relevant to some embedded scenarios), and overall provides more control over
|
|
23
|
-
* memory use.
|
|
24
|
-
*
|
|
25
|
-
* This class, however, cannot ensure all allocation is accounted for since
|
|
26
|
-
* kernel and backend implementations are free to use a separate way to allocate
|
|
27
|
-
* memory (e.g., for things like scratch space). But we do suggest that backends
|
|
28
|
-
* and kernels use these provided allocators whenever possible.
|
|
29
|
-
*/
|
|
30
|
-
class MemoryManager final {
|
|
31
|
-
public:
|
|
32
|
-
/**
|
|
33
|
-
* Constructs a new MemoryManager.
|
|
34
|
-
*
|
|
35
|
-
* @param[in] method_allocator The allocator to use when loading a Method and
|
|
36
|
-
* allocating its internal structures. Must outlive the Method that uses
|
|
37
|
-
* it.
|
|
38
|
-
* @param[in] planned_memory The memory-planned buffers to use for mutable
|
|
39
|
-
* tensor data when executing a Method. Must outlive the Method that uses
|
|
40
|
-
* it. May be `nullptr` if the Method does not use any memory-planned
|
|
41
|
-
* tensor data. The sizes of the buffers in this HierarchicalAllocator
|
|
42
|
-
* must agree with the corresponding
|
|
43
|
-
* `MethodMeta::num_memory_planned_buffers()` and
|
|
44
|
-
* `MethodMeta::memory_planned_buffer_size(N)` values, which are embedded
|
|
45
|
-
* in the Program.
|
|
46
|
-
* @param[in] temp_allocator The allocator to use when allocating temporary
|
|
47
|
-
* data during kernel or delegate execution. Must outlive the Method that
|
|
48
|
-
* uses it. May be `nullptr` if the Method does not use kernels or
|
|
49
|
-
* delegates that allocate temporary data. This allocator will be reset
|
|
50
|
-
* after every kernel or delegate call during execution.
|
|
51
|
-
*/
|
|
52
|
-
explicit MemoryManager(MemoryAllocator *method_allocator,
|
|
53
|
-
HierarchicalAllocator *planned_memory = nullptr,
|
|
54
|
-
MemoryAllocator *temp_allocator = nullptr)
|
|
55
|
-
: method_allocator_(method_allocator), planned_memory_(planned_memory),
|
|
56
|
-
temp_allocator_(temp_allocator) {
|
|
57
|
-
ET_CHECK_MSG(method_allocator != temp_allocator,
|
|
58
|
-
"method allocator cannot be the same as temp allocator");
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
/**
|
|
62
|
-
* DEPRECATED: Use the constructor without `constant_allocator` instead.
|
|
63
|
-
*
|
|
64
|
-
* TODO(T162089316): Remove this once all users migrate to the new ctor.
|
|
65
|
-
*/
|
|
66
|
-
ET_DEPRECATED MemoryManager(MemoryAllocator *constant_allocator,
|
|
67
|
-
HierarchicalAllocator *non_constant_allocator,
|
|
68
|
-
MemoryAllocator *runtime_allocator,
|
|
69
|
-
MemoryAllocator *temporary_allocator)
|
|
70
|
-
: MemoryManager(
|
|
71
|
-
/*method_allocator=*/runtime_allocator,
|
|
72
|
-
/*planned_memory=*/non_constant_allocator,
|
|
73
|
-
/*temp_allocator=*/temporary_allocator) {
|
|
74
|
-
(void)constant_allocator; // Suppress unused variable warning
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
/**
|
|
78
|
-
* Returns the allocator that the runtime will use to allocate internal
|
|
79
|
-
* structures while loading a Method. Must not be used after its associated
|
|
80
|
-
* Method has been loaded.
|
|
81
|
-
*/
|
|
82
|
-
MemoryAllocator *method_allocator() const { return method_allocator_; }
|
|
83
|
-
|
|
84
|
-
/**
|
|
85
|
-
* Returns the memory-planned buffers to use for mutable tensor data.
|
|
86
|
-
*/
|
|
87
|
-
HierarchicalAllocator *planned_memory() const { return planned_memory_; }
|
|
88
|
-
|
|
89
|
-
/**
|
|
90
|
-
* Returns the allocator to use for allocating temporary data during kernel or
|
|
91
|
-
* delegate execution.
|
|
92
|
-
*
|
|
93
|
-
* This allocator will be reset after every kernel or delegate call during
|
|
94
|
-
* execution.
|
|
95
|
-
*/
|
|
96
|
-
MemoryAllocator *temp_allocator() const { return temp_allocator_; }
|
|
97
|
-
|
|
98
|
-
private:
|
|
99
|
-
MemoryAllocator *method_allocator_;
|
|
100
|
-
HierarchicalAllocator *planned_memory_;
|
|
101
|
-
MemoryAllocator *temp_allocator_;
|
|
102
|
-
};
|
|
103
|
-
|
|
104
|
-
} // namespace runtime
|
|
105
|
-
} // namespace executorch
|
|
106
|
-
|
|
107
|
-
namespace torch {
|
|
108
|
-
namespace executor {
|
|
109
|
-
// TODO(T197294990): Remove these deprecated aliases once all users have moved
|
|
110
|
-
// to the new `::executorch` namespaces.
|
|
111
|
-
using ::executorch::runtime::MemoryManager;
|
|
112
|
-
} // namespace executor
|
|
113
|
-
} // namespace torch
|