工具/软件:TI C/C++编译器
当我编译下面的简短程序时、我会遇到编译器内部错误。
有关详细信息、请参阅以下来源。
谢谢你。
源文件"hello.cpp"
#include
#include
#include
命名空间数据
{
类别 DATE_t
{
公共:
constexpr date_t();
内联 bool is_leap_yeon() const;
uint8_t days_in_month() const;
uint8_t 年;
uint8_t 月;
uint8_t Day;
专用:
};
constexpr date_t::date_t ()
:年(0)、月(1)、日(1)
{}
内联 bool date_t:::is_leap_year () const
{
返回(年份和3)==0;
}
uint8_t DATE_t::days_in_month()常量
{
静态常量 uint8_t DaysOfMonthTable[16]={
/* 0 */ 30,/*预防措施*/
/* 1..12 */ 31、28、31、30、31、 30、31、31、30、31、 30、31、
/* 13..15 */ 30、30、30 /*预防措施*/};
uint8_t 结果;
结果= DaysOfMonthTable[Month & 15];
如果((month ==2)和 is_leap_year ())
{
Result ++;
}
返回结果;
}
}
/**
* hello.c
*
int main (空)
{
WDTCTL = WDTPW | WDTHOLD; //停止看门狗计时器
printf ("Hello World!\n");
返回0;
}
控制台:
****项目 Error_1的配置调试构建****
"C:\\ti\\ccsv7\\utils\\bin\\gmake"-k -j 8 all -O
'生成文件:./hello.cpp'
'调用:MSP430编译器'
"c:/ti/ccsv7/tools/compiler/ti-cgt-msp430_18.1.4.LTS/bin/cl430 -vmspx --data_model=restricted --use_hw_mpy=F5 --include_path="C:/ti/ccsv7/ccs_base/msp430/include --include_path="D:/sontex/dev/Produit/Integr/731/4_FW/ESSAIS_JMM/Error_1 --include_path="C:/ti/ccsv7/tools/compiler/ti-cgt-msp430_18.1.4.LTS/include --use_path="C:--advice:power=all --advice:hw_config=all --include_erratiation="_msp430_erratina-us=cep_support/capsility=cepsi-support/cp_cp_support/capsility=us_support/capacitive-cepsility=us-up_cp_cp.cp_up_up_up_up_up_guide=us-up_up_up_up_up_guidature=us-up_up_cp.cp.cp.cp_up_up_up_up_up_up_up_up_up_up_up_support
>>编译失败
subdir_rules.mk:9:目标'hello.obj'的配方失败
内部错误:C:\ti\ccsv7\tools\compiler\ti-cgt-msp430_18.1.4.sps\bin\acpia430.exe 遇到分段错误
处理函数时(未知或文件范围)文件./hello.cpp 行43
这是由 TI EABI C/C++解析器中的缺陷导致的。
TI 客户支持可能会建议解决方法来避免这种情况。
升级到编译器的最新版本可能会解决此问题。
在 E2E 支持论坛中联系 TI、网址 为 http://e2e.ti.com 、位于
"开发工具"、"TI C/C++编译器"。 请参阅标题为的链接
"提交问题"。
我们需要看到整个错误消息以及完整、可重现的消息
包括所有命令行选项的测试用例。
包含由选项--preproc_with_comment 创建的.pp 文件
gmake:***[hello.obj]错误1.
gmake:目标"全部"不会由于错误而重新生成。
****构建完成****
编译器
编译器版本: TI v18.1.4.LTS
编译器标志:
vmspx
--data_model=受限
--use_hw_mpy=F5
--include_path="${ccs_base_root}/msp430/include "
--include_path="${project_root}"
--include_path="${cG_tool_root}/include"
--advice:power=all
--advice:hw_config=all
--define=__MSP430FR5994__
--define=_MPU_enable
-g
--printf_support=minimal
--diag_warning=225
--diag_wrap=off
--display_error_number
--silicon_errater=CPU21
--silicon_errater=CPU22
--silicon_errater=CPU40
链接器标志:
-m"${ProjName}.map"
--heap_size=300
--stack_size=300
-cinit_hold_wdt=on
-i"${ccs_base_root}/msp430/include"
-i"${CCS_base_root}/MSP430/lib/5xx_6xx_FRxx"
-i"${CCS_base_root}/MSP430/lib/FR59xx"
-i"${CG_TOOL_ROOT}/lib"
-i"${CG_TOOL_ROOT}/include"
--优先级
--reread_libs
--define=_MPU_enable
--diag_wrap=off
--display_error_number
--warn_sections
-xml_link_info="${ProjName}_linkInfo.xml"
--use_hw_mpy=F5
-rom_model