Main Content

코드 검증

생성 코드의 동작 검증, 추적성, 코드 생성 리포트

코드를 생성한 후 소스 코드를 검사하고 검증을 위해 결과를 출력합니다. 코드 생성 리포트는 생성된 C/C++ 소스 파일, 생성된 데이터형 및 기타 코드 인사이트를 검사하기 위한 대화형 방식의 인터페이스를 제공합니다. 리포트 정보 객체를 사용하여 프로그래밍 방식으로 코드 생성 리포트 정보의 일부에 액세스합니다. 생성된 MEX 코드의 출력값을 원래 MATLAB® 코드와 대조해 테스트하거나 MATLAB 단위 테스트 클래스를 기반으로 사용자 지정 테스트를 생성할 수 있습니다. 코드 실행 중에 발생하는 오류를 알려주는 런타임 오류 검사를 생성하도록 선택할 수 있습니다.

함수

codegenGenerate C/C++ code from MATLAB code
coder.configCreate MATLAB Coder code generation configuration objects
coder.runTestRun test replacing calls to MATLAB functions with calls to MEX functions
getLineColumnFind locations of beginning and end of MATLAB code involved in code generation
coder.ignoreConst표현식의 상수 값을 사용한 함수 특수화 금지
coder.ignoreSizePrevent code generator from creating function specializations for constant-size expressions (R2019b 이후)
coder.mfunctionnameName of calling function or method (R2021b 이후)

클래스

coder.HardwareImplementationHardware-specific configuration parameters for C/C++ code generation from MATLAB code

객체

coder.MexCodeConfigConfiguration parameters for MEX function generation from MATLAB code
coder.CodeConfigConfiguration parameters for C/C++ code generation from MATLAB code
coder.EmbeddedCodeConfigConfiguration parameters for C/C++ code generation from MATLAB code with Embedded Coder

속성

coder.ReportInfo PropertiesCode generation report information
coder.Summary PropertiesSummary of code generation from MATLAB code
coder.File PropertiesDescription of file without text that is involved in code generation
coder.CodeFile PropertiesDescription of file containing text that is involved in code generation
coder.Function PropertiesDescription of MATLAB function used in code generation
coder.Method PropertiesDescription of method in a MATLAB class used in code generation
coder.Message PropertiesDescription of message produced during code generation readiness analysis or during code generation
coder.BuildLog PropertiesBuild logs produced during code generation (R2019b 이후)

도움말 항목

코드 생성 리포트

생성 코드 테스트

런타임 오류 감지

문제 해결하기