MATLAB Coder
R2026bMATLAB® Coder™ は、デスクトップ システムから組み込みハードウェアまで、さまざまなハードウェア プラットフォームに対応する C/C++ コードを MATLAB コードから生成します。ほとんどの MATLAB 言語と広い範囲のツールボックスがサポートされます。生成されたコードは読み取りと移植が可能であり、既存の C/C++ プロジェクトにソース コード、スタティック ライブラリ、またはダイナミック ライブラリとして統合できます。生成されたコードを MATLAB Coder で MEX 関数としてパッケージ化し、MATLAB で使用することができます。マルチコアのベクトル化コードを組み込み、最適化されたライブラリを呼び出すことで、生成コードを最適化できます。
MATLAB Coder では、コードのカスタマイズ、ハードウェア固有の最適化、コードのトレーサビリティ、ソフトウェアインザループ (SIL) テストやプロセッサインザループ (PIL) テストを使用したコードの検証、コードの MISRA™ ガイドラインへの準拠 (Embedded Coder® を使用) が提供されます。
MATLAB でサポートされるホスト プラットフォームに MATLAB プログラムを展開するには、MATLAB Compiler™ を使用します。
MATLAB Coder 入門
MATLAB Coder の基礎を学ぶ
コード生成のための MATLAB プログラミング
コード生成、データ定義のための MATLAB 言語構文と関数
コード生成
C/C++ および MEX コードの生成、エラーの修正、動作検証
展開
生成された C/C++ コードの使用と実行
パフォーマンス
コード生成時間の短縮、実行速度の改善、生成されたコードのメモリ使用量の削減
MATLAB アルゴリズムの高速化
生成された MEX 関数を使用した高速化
数値変換
固定小数点の変換、単精度の変換 (Fixed-Point Designer™ が必要)
MATLAB Coder を使用した深層学習
深層学習ニューラル ネットワークの C/C++ コードの生成 (Deep Learning Toolbox™ が必要)
PyTorch および LiteRT モデルのコード生成
PyTorch® ExportedProgram および LiteRT モデルの C、C++、および CUDA コードを生成する
MATLAB Coder でサポートされているハードウェア
サードパーティ製ハードウェアのサポート
問題と修正についてバグ レポートをチェック
Software is inherently complex and is not free of errors. The output of a code generator might contain bugs, some of which are not detected by a compiler. MathWorks reports critical known bugs brought to its attention on its Bug Report system at www.mathworks.com/support/bugreports/. Click the "Incorrect Code Generation" filter to obtain a report of known bugs that produce code that might compile and execute, but still produce wrong answers. To save the filtered results, click Save Search.
The bug reports are an integral part of the documentation for each release. Examine periodically all bug reports for a release, as such reports may identify inconsistencies between the actual behavior of a release you are using and the behavior described in this documentation.
In addition to reviewing bug reports, you should implement a verification and validation strategy to identify potential bugs in your design, code, and tools.