{"id":943,"date":"2026-07-24T15:44:51","date_gmt":"2026-07-24T15:44:51","guid":{"rendered":"https:\/\/boochlin.com\/?p=943"},"modified":"2026-08-18T14:14:04","modified_gmt":"2026-08-18T14:14:04","slug":"android-%e7%88%9b%e8%a3%9d%e7%bd%ae%e6%83%b3%e8%b7%91%e4%ba%ba%e8%87%89%e8%be%a8%e8%ad%988-%e5%85%84%e5%bc%9f%e9%bd%8a%e5%bf%83%ef%bc%8c%e8%bb%9f%e7%a1%ac%e5%85%bc%e6%96%bd-arm-compute-lib","status":"publish","type":"post","link":"https:\/\/boochlin.com\/?p=943","title":{"rendered":"Android \u721b\u88dd\u7f6e\u60f3\u8dd1\u4eba\u81c9\u8fa8\u8b589- \u5144\u5f1f\u9f4a\u5fc3\uff0c\u8edf\u786c\u517c\u65bd arm compute lib"},"content":{"rendered":"\n<p>\u524d\u9762\u90fd\u5728\u8ddf\u8a18\u61b6\u9ad4\u640f\u9b25\u3001\u8ddf GC \u7b97\u5e33\uff0c\u4eca\u5929\u4f86\u8ac7\u7d14\u7cb9\u7684\u300c\u7b97\u529b\u300d\u3002<\/p>\n\n\n\n<p>\u5728 1.3GHz \u7684\u7834\u677f\u5b50\u4e0a\u8dd1\u5373\u6642\u4eba\u81c9\u8fa8\u8b58\uff1a\u76f8\u6a5f\u6293\u5230\u4e00\u4e32 512 \u7dad\u7684\u4eba\u81c9\u7279\u5fb5\uff0c\u8981\u8ddf\u8cc7\u6599\u5eab\u88e1\u7684 5,000 \u540d\u54e1\u5de5\u7279\u5fb5\u9032\u884c\u6bd4\u5c0d\u3002<\/p>\n\n\n\n<p>\u5728\u8001\u95c6\u6700\u521d\u63d0\u51fa\u300c\u8fa8\u8b58\u81f3\u5c11\u8981 10 FPS\u300d\u7684\u7121\u7406\u8981\u6c42\u4e0b\uff0cCPU \u6bcf\u79d2\u5f97\u541e\u4e0b 512 \u00d7 5000 \u00d7 10 = 25,600,000 \u6b21\uff082,560 \u842c\u6b21\uff09\u6d6e\u9ede\u6578\u4e58\u52a0\u904b\u7b97\u3002<\/p>\n\n\n\n<p>\u70ba\u4e86\u6d3b\u4e0b\u4f86\uff0c\u6211\u7b2c\u4e00\u6642\u9593\u5148\u8aaa\u670d\u8001\u95c6\u628a\u76ee\u6a19\u780d\u5230 3 FPS\u2014\u2014\u7562\u7adf\u6211\u5011\u8981\u7684\u662f\u4eba\u81c9\u8fa8\u8b58\u6210\u529f\u958b\u9580\uff0c\u4e0d\u662f\u5728\u9580\u7981\u6a5f\u4e0a\u770b 60fps \u7d72\u6ed1\u52d5\u756b\u3002\u4f46\u5c31\u7b97\u628a\u5e40\u7387\u58d3\u4f4e\uff0c\u55ae\u6b21\u6bd4\u5c0d 5,000 \u4eba\u4f9d\u7136\u8981\u7b97 256 \u842c\u6b21\u6d6e\u9ede\u6578\u3002<\/p>\n\n\n\n<p>\u5728\u6211\u5011\u9019\u53f0\u53ea\u6709 4 \u6838\u5fc3 Cortex-A53 \u5f31 CPU \u7684\u7834\u677f\u5b50\u4e0a\uff0c\u6bd4\u5c0d\u6a21\u7d44\u6b77\u7d93\u4e86\u4e09\u6b21\u6975\u5176\u6158\u70c8\u7684\u6f14\u5316\u3002<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">\u7b2c\u4e00\u6b21\u6f14\u5316\uff1a\u5929\u771f\u7684 Java \u82e6\u5de5\uff08150ms\uff09<\/h2>\n\n\n\n<p>\u6700\u76f4\u89ba\u7684\u505a\u6cd5\uff0c\u5c31\u662f\u5728 Java \u88e1\u5beb\u500b\u96d9\u91cd\u8ff4\u5708\u7b97\u5167\u7a4d\uff08\u9918\u5f26\u76f8\u4f3c\u5ea6\uff09\uff1a<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nfloat bestScore = -1.0f;\nint bestIndex = -1;\n\nfor (int i = 0; i &amp;lt; 5000; i++) {\n    float&#x5B;] dbFeature = database.get(i);\n    float score = 0;\n    for (int j = 0; j &amp;lt; 512; j++) {\n        score += inputFeature&#x5B;j] * dbFeature&#x5B;j];\n    }\n    if (score &gt; bestScore) {\n        bestScore = score;\n        bestIndex = i;\n    }\n}\n<\/pre><\/div>\n\n\n<ul>\n<li><strong>\u5be6\u9a57\u6578\u64da<\/strong>\uff1a<strong>\u7d04 150 \u6beb\u79d2<\/strong>\u3002<\/li>\n\n\n\n<li><strong>\u6158\u6cc1\u5206\u6790<\/strong>\uff1a\u4f4e\u968e ARM \u6676\u7247\u4e0a\u7684 Android JVM \u6839\u672c\u6c92\u6709\u5f37\u5927\u7684\u81ea\u52d5\u5411\u91cf\u5316\u512a\u5316\u80fd\u529b\u3002CPU \u53ea\u80fd\u50cf\u500b\u8001\u5be6\u5df4\u4ea4\u7684\u82e6\u529b\uff0c\u8001\u8001\u5be6\u5be6\u8dd1\u5b8c\u9019 256 \u842c\u6b21\u4e58\u6cd5\u3002\u55ae\u6b21\u6bd4\u5c0d\u5403\u6389 150ms\uff0c\u807d\u8d77\u4f86\u597d\u50cf\u9084\u80fd\u64e0\u51fa 6 FPS\uff1f\u5225\u5929\u771f\u4e86\uff0c\u9019\u53ea\u662f\u6574\u500b Pipeline \u7684\u6700\u5f8c\u4e00\u6b65\uff0c\u524d\u9762\u7684\u4eba\u81c9\u5075\u6e2c\u3001\u54c1\u8cea\u904e\u6ffe\u30013D \u6d3b\u9ad4\u9632\u507d\u5168\u90fd\u8981\u5403\u6642\u9593\u554a\uff01<\/li>\n<\/ul>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">\u7b2c\u4e8c\u6b21\u6f14\u5316\uff1a\u628a 1:1 \u908f\u8f2f\u5957\u9032 1:N \u8ff4\u5708\u7684 JNI \u707d\u96e3\uff08320ms\uff09<\/h2>\n\n\n\n<p>\u5f88\u591a\u5de5\u7a0b\u5e2b\u76f4\u89ba\u8a8d\u70ba\uff1a\u300cJava \u6162\uff1f\u90a3\u5c31\u4ea4\u7d66\u5f71\u50cf\u795e\u5668 OpenCV \u7684 C++ \u5e95\u5c64\u4f86\u7b97\uff01\u300d<\/p>\n\n\n\n<p>\u5728\u6211\u5011\u7684\u5c08\u6848\u88e1\uff0c\u672c\u4f86\u5c31\u6709\u4e00\u500b\u5c08\u9580\u7d66\u300c1:1 \u5237\u5361\u8a8d\u8b49\u300d\u4f7f\u7528\u7684 <code>AuthFeatureMatcher.java<\/code>\u3002\u7576\u54e1\u5de5\u5148\u5237\u5de5\u865f\u5361\u3001\u5e36\u5165\u8eab\u5206\u5f8c\uff0c\u547c\u53eb OpenCV \u7684 <code>Core.gemm<\/code> \u6bd4\u5c0d\u55ae\u4e00\u76ee\u6a19\uff1a<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\n\/\/ AuthFeatureMatcher.java\uff08\u539f\u672c\u5c08\u70ba 1:1 \u5237\u5361\u6bd4\u5c0d\u8a2d\u8a08\uff09\nfeatureDet.put(0, 0, inputFeature);\nfeatureCmp.put(0, 0, authFace.getRgbFeature());\n\/\/ \u547c\u53eb OpenCV \u5e95\u5c64\u7b97\u55ae\u6b21\u5167\u7a4d\u5206\u6578\nCore.gemm(featureDet, featureCmp, 1.0, new Mat(), 0.0, cvResult);\n<\/pre><\/div>\n\n\n<p>\u5728 1:1 \u6a21\u5f0f\u4e0b\uff0c\u9019\u6bb5\u4ee3\u78bc\u53ea\u57f7\u884c\u4e00\u6b21\uff0c\u8017\u6642\u4e0d\u5230 0.5ms\uff0c\u723d\u5feb\u5f97\u5f88\u3002<\/p>\n\n\n\n<p>\u4f46\u5982\u679c\u628a\u5b83\u62ff\u4f86\u505a 1:N \u7121\u611f\u5237\u81c9\uff08\u4e0d\u5237\u5361\u3001\u5f9e 5,000 \u4eba\u5927\u6d77\u6488\u91dd\uff09\uff0c\u5728 Java \u5916\u5c64\u5957\u4e0a <code>for (int i = 0; i &lt; 5000; i++)<\/code> \u8ff4\u5708\u2014\u2014<strong>\u4e0b\u5834\u5c31\u662f\u4e00\u5834\u707d\u96e3<\/strong>\u3002<\/p>\n\n\n\n<ul>\n<li><strong>\u5be6\u9a57\u6578\u64da<\/strong>\uff1a<strong>\u7d04 320 \u6beb\u79d2\uff08\u5c45\u7136\u6bd4\u7d14 Java \u6162\u4e86\u5169\u500d\u4ee5\u4e0a\uff01\uff1f\uff09<\/strong>\u3002<\/li>\n\n\n\n<li><strong>\u81f4\u547d\u7684 JNI \u904e\u8def\u8cbb<\/strong>\uff1a<br>\u9019\u72af\u4e86\u8de8\u8a9e\u8a00\u547c\u53eb\u7684\u5927\u5fcc\uff1a\u5728 Java \u8ff4\u5708\u88e1\u760b\u72c2\u547c\u53eb JNI\u3002<br>\u70ba\u4e86\u7b97\u4e00\u7b46\u5c0f\u5c0f\u7684\u4e58\u6cd5\uff0c\u7a0b\u5f0f\u904e\u6d77\u95dc\uff08JNI Context Switch\uff09\u4f86\u56de\u8dd1\u4e86 5,000 \u8d9f\uff01<br>\u9019\u5c31\u50cf\u70ba\u4e86\u69a8 5,000 \u676f\u679c\u6c41\uff0c\u958b\u5361\u8eca\u4e00\u6b21\u53ea\u8f09\u300c\u4e00\u9846\u860b\u679c\u300d\u8dd1 5,000 \u8d9f\u53bb\u5de5\u5ee0\uff0c\u8def\u4e0a\u7684\u904e\u8def\u8cbb\u8207\u63db\u5411\u958b\u92b7\u65e9\u5c31\u9060\u9060\u8d85\u904e\u69a8\u679c\u6c41\u7684\u6642\u9593\u4e86\u3002<\/li>\n<\/ul>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">\u6700\u7d42\u9032\u5316\uff1a\u964d\u7dad\u6253\u64ca\uff08ACL SDK + ARM NEON\uff0c3ms\uff09<\/h2>\n\n\n\n<p>\u88ab JNI \u75db\u64ca\u4e4b\u5f8c\uff0c\u6211\u5011\u5fb9\u5e95\u63a8\u7ffb\u67b6\u69cb\uff0c\u70ba 1:N \u6253\u9020\u4e86\u5c08\u5c6c\u7684 <strong><code>NesFeatureMatcher.java<\/code><\/strong>\uff1a<\/p>\n\n\n\n<ol>\n<li><strong>\u4e0d\u80fd\u904e\u6d77\u95dc 5,000 \u6b21<\/strong>\uff1a\u6574\u500b 1:N \u6bd4\u5c0d\u8ff4\u5708\u5fc5\u9808\u6574\u5305\u642c\u5230 C++ \u5e95\u5c64\u3002<\/li>\n\n\n\n<li><strong>OpenCV \u592a\u901a\u7528<\/strong>\uff1a\u6211\u5011\u9700\u8981\u91dd\u5c0d\u9019\u9846 ARM Cortex-A53 \u91cf\u8eab\u6253\u9020\u7684\u5c08\u5c6c\u6b66\u5668\u3002<\/li>\n\n\n\n<li><strong>\u5f9e\u300c\u55ae\u6311\u300d\u5347\u7d1a\u70ba\u300c\u6253\u7fa4\u67b6\u300d<\/strong>\uff1a<br>\u6211\u5011\u4e0d\u518d\u4e00\u5c0d\u4e00\u55ae\u6311\u4e86\u3002\u7a0b\u5f0f\u555f\u52d5\u6642\uff0c\u76f4\u63a5\u5c07 5,000 \u540d\u54e1\u5de5\u7684\u7279\u5fb5\u5728 C++ \u8a18\u61b6\u9ad4\u4e2d\u62fc\u63a5\u6210\u4e00\u500b <strong>5000 \u00d7 512 \u7684\u4e8c\u7dad\u8d85\u7d1a\u77e9\u9663\uff08Tensor\uff09<\/strong>\u3002<\/li>\n<\/ol>\n\n\n\n<p>\u65b0\u756b\u9762\u9032\u4f86\u6642\uff0c<strong>\u5168\u6d41\u7a0b\u53ea\u904e\u300c\u4e00\u6b21\u300d\u6d77\u95dc<\/strong>\uff1a<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\n\/\/ NesFeatureMatcher.java\n\/\/ \u8de8\u4e00\u6b21 JNI\uff0c\u5e95\u5c64\u76f4\u63a5\u767c\u52d5 1 x 5000 \u5927\u77e9\u9663\u4e58\u6cd5\nint faceIndex = aclLib.cachedNesMatch(inputFeatures, threshold);\n<\/pre><\/div>\n\n\n<p>\u5728 C++ \u5e95\u5c64\uff0c\u6539\u7528 ARM \u539f\u5ee0\u7684 <strong>Compute Library (ACL)<\/strong> \u767c\u52d5 <code>NESGEMM<\/code>\uff1a<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\n\/\/ C++ \u5e95\u5c64\uff1aACL SGEMM \u904b\u7b97\nNESFeatureMatcher::copy_to_tensor(*_tensor_a, inputFeature);\n\/\/ \u547c\u53eb ARM \u5e95\u5c64\u786c\u9ad4\u52a0\u901f (NEON SIMD) \u4e00\u64ca\u5fc5\u6bba\nsgemm.run();\nNESFeatureMatcher::copy_from_tensor(*_tensor_o, results.get());\n<\/pre><\/div>\n\n\n<ul>\n<li><strong>\u5be6\u9a57\u6578\u64da<\/strong>\uff1a<strong>\u7d04 3 \u6beb\u79d2\uff08\u767e\u500d\u79d2\u6bba\uff01\uff09<\/strong>\u3002<\/li>\n<\/ul>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">\u70ba\u4f55\u5982\u6b64\u72c2\u66b4\uff1f\uff08\u84cb\u4e00\u842c\u4efd\u516c\u6587\u7684\u9802\u7d1a\u8fa6\u516c\u5ba4 SOP\uff09<\/h2>\n\n\n\n<p>\u5982\u679c\u8981\u7528\u6700\u751f\u6d3b\u5316\u7684\u65b9\u5f0f\u4f86\u7e3d\u7d50 SGEMM \u8207\u786c\u9ad4\u52a0\u901f\uff0c\u6211\u5011\u53ef\u4ee5\u60f3\u50cf <strong>\u300c\u4e00\u500b\u8fa6\u516c\u5ba4\u54e1\u5de5\uff08CPU\uff09\u8981\u84cb 1 \u842c\u4efd\u516c\u6587\uff08\u8cc7\u6599\uff09\u300d<\/strong> \u7684\u5834\u666f\uff1a<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">1. \u50b3\u7d71\u5beb\u6cd5\uff08\u4e00\u822c\u8ff4\u5708\uff09<\/h3>\n\n\n\n<p>\u54e1\u5de5\u8d70\u5230\u9059\u9060\u7684\u6a94\u6848\u5ba4\uff08\u4e3b\u8a18\u61b6\u9ad4 RAM\uff09\uff0c\u627e\u51fa\u4e00\u4efd\u516c\u6587\uff0c\u8d70\u56de\u4f4d\u5b50\uff0c\u62ff\u8d77\u5370\u7ae0\u84cb\u4e0b\u53bb\u3002\u7136\u5f8c\u518d\u8d70\u53bb\u6a94\u6848\u5ba4\u62ff\u4e0b\u4e00\u4efd\u2026\u2026<br><strong>\u7d50\u679c<\/strong>\uff1a\u4f86\u56de\u8dd1\u6b7b\uff0c\u4e00\u5929\u53ea\u80fd\u84cb 100 \u4efd\uff0c\u5927\u90e8\u5206\u6642\u9593\u90fd\u5728\u8d70\u8def\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">2. \u5feb\u53d6\u9810\u8b80\uff08Prefetch\uff09\u2014\u2014 \u8acb\u500b\u5c0f\u52a9\u624b<\/h3>\n\n\n\n<p>\u70ba\u4e86\u89e3\u6c7a\u8d70\u8def\u7684\u6642\u9593\uff0c\u54e1\u5de5\u8acb\u4e86\u4e00\u500b\u5c0f\u52a9\u624b\u3002\u7576\u54e1\u5de5\u5728\u4f4d\u5b50\u4e0a\u84cb\u7ae0\u6642\uff0c\u5c0f\u52a9\u624b\u62fc\u547d\u53bb\u6a94\u6848\u5ba4\u628a\u63a5\u4e0b\u4f86\u8981\u84cb\u7684\u516c\u6587\u4e00\u758a\u4e00\u758a\u642c\u5230\u54e1\u5de5\u684c\u4e0a\uff08L1 \u5feb\u53d6\uff09\u3002<br><strong>\u7d50\u679c<\/strong>\uff1a\u54e1\u5de5\u518d\u4e5f\u4e0d\u7528\u8d77\u8eab\uff0c\u4f38\u624b\u5c31\u80fd\u62ff\u5230\u4e0b\u4e00\u4efd\u516c\u6587\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">3. SIMD \u5411\u91cf\u5316 \u2014\u2014 \u7279\u88fd\u9023\u9ad4\u5370\u7ae0<\/h3>\n\n\n\n<p>\u5c31\u7b97\u4e0d\u7528\u8d70\u8def\uff0c\u4e00\u6b21\u84cb\u4e00\u4efd\u9084\u662f\u592a\u6162\u3002\u65bc\u662f\u516c\u53f8\u914d\u767c\u4e86\u4e00\u500b\u300c\u7279\u88fd\u7684\u56db\u9023\u9ad4\u5370\u7ae0\u300d\uff08ARM NEON 128-bit \u5411\u91cf\u66ab\u5b58\u5668\uff09\uff0c\u4e00\u6b21\u58d3\u4e0b\u53bb\u540c\u6642\u84cb 4 \u4efd\u516c\u6587\uff08FMA \u878d\u548c\u4e58\u52a0\uff09\u3002<br><strong>\u7d50\u679c<\/strong>\uff1a\u84cb\u7ae0\u901f\u5ea6\u76f4\u63a5\u7ffb\u4e86 4 \u500d\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">4. \u77e9\u9663\u5206\u584a\uff08Tiling\uff09\u2014\u2014 \u684c\u9762\u7a7a\u9593\u7ba1\u7406<\/h3>\n\n\n\n<p>\u96d6\u7136\u5c0f\u52a9\u624b\u4e00\u76f4\u642c\u516c\u6587\uff0c\u4f46\u54e1\u5de5\u7684\u300c\u684c\u9762\u7a7a\u9593\u6709\u9650\u300d\uff08Cortex-A53 L1 \u6578\u64da\u5feb\u53d6\u53ea\u6709 32KB\uff09\u3002\u5982\u679c\u4e00\u6b21\u642c 1 \u842c\u4efd\u904e\u4f86\uff0c\u6703\u585e\u7206\u684c\u9762\uff0c\u516c\u6587\u6389\u5230\u5730\u4e0a\u53cd\u800c\u66f4\u4e82\uff08Cache Thrashing\uff09\u3002<br>\u6240\u4ee5\u54e1\u5de5\u898f\u5b9a\uff1a\u300c\u6bcf\u6b21\u53ea\u642c\u525b\u597d\u92ea\u6eff\u684c\u9762\u7684\u6578\u91cf\u300d\uff084 \u00d7 4 \u6216 8 \u00d7 8 Tile\uff09\u3002\u9019\u758a\u84cb\u5b8c\u6536\u8d70\uff0c\u518d\u63db\u4e0b\u4e00\u758a\u3002<br><strong>\u7d50\u679c<\/strong>\uff1a\u684c\u9762\u6c38\u9060\u4fdd\u6301\u6700\u9ad8\u6548\u7387\u7684\u904b\u4f5c\u72c0\u614b\uff0c\u5feb\u53d6\u547d\u4e2d\u7387\u98c6\u7834 99%\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">5. \u91cd\u65b0\u6253\u5305\uff08Packing\uff09\u2014\u2014 \u4e8b\u524d\u6574\u7406<\/h3>\n\n\n\n<p>\u6a94\u6848\u5ba4\u88e1\u7684\u516c\u6587\u662f\u7167\u300c\u5e74\u4efd\u300d\u6392\u7684\uff0c\u4f46\u8001\u95c6\u8981\u6c42\u7167\u300c\u90e8\u9580\u300d\u84cb\u7ae0\u3002\u5982\u679c\u4f60\u4e00\u908a\u84cb\u7ae0\u4e00\u908a\u81ea\u5df1\u7ffb\u627e\uff0c\u6703\u6d6a\u8cbb\u8d85\u591a\u6642\u9593\uff08\u8de8\u6b65\u8b80\u53d6\u61f2\u7f70\uff09\u3002<br>\u6240\u4ee5\u5c0f\u52a9\u624b\u5728\u628a\u516c\u6587\u653e\u5230\u684c\u4e0a\u4e4b\u524d\uff0c\u6703\u5148\u5728\u65c1\u908a\u6392\u597d\u9806\u5e8f\uff08\u7dda\u6027\u9023\u7e8c\u8a18\u61b6\u9ad4\u4f48\u5c40\uff09\u3002<br><strong>\u7d50\u679c<\/strong>\uff1a\u54e1\u5de5\u9589\u8457\u773c\u775b\u4e00\u8def\u72c2\u84cb\u5c31\u597d\uff0c\u5b8c\u5168\u4e0d\u7528\u505c\u4e0b\u4f86\u627e\u3002<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">\u7d50\u8a9e<\/h2>\n\n\n\n<p>SGEMM \u5c31\u662f\u9019\u6574\u5957 <strong>\u300c\u9802\u7d1a\u8fa6\u516c\u5ba4 SOP\u300d<\/strong> \u7684\u7d42\u6975\u7d50\u5408\u9ad4\u3002<\/p>\n\n\n\n<p>\u4f60\u81ea\u5df1\u5beb\u7684 C++\uff0c\u5c31\u50cf\u662f\u53eb\u4e00\u500b\u5f88\u731b\u7684\u54e1\u5de5\u53bb\u84cb\u7ae0\uff0c\u4f46\u4ed6\u4e0d\u61c2\u8fa6\u516c\u5ba4\u653f\u6cbb\u548c SOP\uff0c\u53ea\u6703\u50bb\u50bb\u4f86\u56de\u8dd1\u3002<\/p>\n\n\n\n<p>\u800c ARM \u539f\u5ee0\u5beb\u7684 SGEMM\uff0c\u662f\u9023\u684c\u5b50\u5927\u5c0f\u3001\u5c0f\u52a9\u624b\u8d70\u8def\u901f\u5ea6\u3001\u5370\u7ae0\u5c3a\u5bf8\u90fd\u7cbe\u7b97\u904e\u7684\u5b8c\u7f8e\u751f\u7522\u7dda\u3002\u628a 1:N \u6bd4\u5c0d\u58d3\u5230 3ms\uff0c\u7701\u4e0b\u4f86\u7684\u7b97\u529b\u624d\u80fd\u8b93 1.3GHz \u5f31\u6676\u7247\u5728 500ms \u5167\u5f9e\u5bb9\u5b8c\u6210\u958b\u9580\u3002<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">\u53c3\u8003\u8cc7\u6599 (References)<\/h2>\n\n\n\n<ol>\n<li><strong>ARM Compute Library (ACL) Documentation and Architecture Overview<\/strong>.<br><a href=\"https:\/\/arm-software.github.io\/ComputeLibrary\/\" target=\"_blank\" rel=\"noreferrer noopener\">https:\/\/arm-software.github.io\/ComputeLibrary\/<\/a><\/li>\n\n\n\n<li><strong>BLAS (Basic Linear Algebra Subprograms) SGEMM: Matrix Multiplication Optimization<\/strong>.<br><a href=\"https:\/\/www.netlib.org\/blas\/\" target=\"_blank\" rel=\"noreferrer noopener\">https:\/\/www.netlib.org\/blas\/<\/a><\/li>\n\n\n\n<li><strong>ARM NEON SIMD Matrix Multiply and Accumulate Instructions<\/strong>.<br><a href=\"https:\/\/developer.arm.com\/architectures\/instruction-sets\/simd-isas\/neon\" target=\"_blank\" rel=\"noreferrer noopener\">https:\/\/developer.arm.com\/architectures\/instruction-sets\/simd-isas\/neon<\/a><\/li>\n<\/ol>\n","protected":false},"excerpt":{"rendered":"<p>\u5728 1.3GHz \u7684\u7834\u677f\u5b50\u4e0a\u8dd1\u5373\u6642\u4eba\u81c9\u8fa8\u8b58\uff1a\u4f60\u6709\u4e00\u4e32 512 \u7dad\u7684\u4eba\u81c9\u7279\u5fb5\uff0c\u8981\u8ddf\u8cc7\u6599\u5eab\u7684\u00a05,000 \u540d\u54e1\u5de5\u6bd4\u5c0d\u3002 \u5728 \u8001\u95c6\u8aaa\u898110 FPS \u7684\u8981\u6c42\u4e0b\uff0cCPU \u6bcf\u79d2\u5f97\u541e\u4e0b\u00a0512\u00d75000\u00d710=2560\u842c\u6b21512\u00d75000\u00d710=2560\u842c\u6b21\u00a0\u7684\u6d6e\u9ede\u6578\u904b\u7b97\u3002<\/p>\n<p>\u70ba\u4e86\u6d3b\u4e0b\u4f86\uff0c\u6211\u5148\u8aaa\u670d\u8001\u95c6\u4e86\uff0c\u6700\u591a\u53ea\u80fd3fps , \u7562\u7adf\u6211\u5011\u8981\u7684\u662f\u8fa8\u8b58\uff0c\u4e0d\u662f\u756b\u9762\u6d41\u66a2\uff0e\u6211\u5011\u7684\u6bd4\u5c0d\u6a21\u7d44\u6b77\u7d93\u4e86\u4e09\u6b21\u6158\u70c8\u7684\u6f14\u5316\u3002<\/p>\n","protected":false},"author":1,"featured_media":947,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[50,3,80],"tags":[],"_links":{"self":[{"href":"https:\/\/boochlin.com\/index.php?rest_route=\/wp\/v2\/posts\/943"}],"collection":[{"href":"https:\/\/boochlin.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/boochlin.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/boochlin.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/boochlin.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=943"}],"version-history":[{"count":8,"href":"https:\/\/boochlin.com\/index.php?rest_route=\/wp\/v2\/posts\/943\/revisions"}],"predecessor-version":[{"id":996,"href":"https:\/\/boochlin.com\/index.php?rest_route=\/wp\/v2\/posts\/943\/revisions\/996"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/boochlin.com\/index.php?rest_route=\/wp\/v2\/media\/947"}],"wp:attachment":[{"href":"https:\/\/boochlin.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=943"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/boochlin.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=943"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/boochlin.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=943"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}