CakeML/cakeml

The encoders are _big_

开放

#793 创建于 2020年10月15日

 (1 条评论) (0 个反应) (0 位负责人)Standard ML (98 个派生)auto 404
dev experienceenhancementgood first issuehigh reward

仓库指标

星标
 (1,169 个星标)
PR 合并指标
 (PR 指标待抓取)

描述

Some numbers from a --target=riscv --exp_cut=99999 build (9a0180e sexpr-bootstrap):

1069060 cml_x64Prog_x64_enc_5306
 990976 cml_arm7Prog_arm7_enc_5296
 938348 cml_riscvProg_riscv_enc_5348
 784956 cml_arm8Prog_arm8_enc_5342
 373572 cml_mipsProg_mips_enc_5352
 291168 cml_ag32_enc_5324

Some of this is probably unavoidable with heap-allocated words but looking at the HOL input to the translator in riscvProgScript and x64ProgScript we seem to be forcing the encoders into a highly canonical form where no logic can be shared between different instructions; particularly notable are the 16 reg/imm (not)(lower, less, equal, test) cases of JumpCmp which result in 16 copies of the logic to encode a conditional jump displacement. Improving the pre-translate conversions here could make the bootstrap significantly faster with no effect whatsoever on compiling things in the logic.

贡献者指南