forked from moonbitlang/moonbit-compiler
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Optimize suitable R-type instructions into I-type
- Loading branch information
Showing
10 changed files
with
246 additions
and
84 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
(** Gathers all optimizations. *) | ||
open Riscv_opt | ||
|
||
let opt ssa = | ||
iter_fn2 build_cfg ssa; | ||
|
||
(* Peephole *) | ||
Riscv_opt_peephole.peephole ssa; | ||
|
||
let s = map_fn ssa_of_cfg ssa in | ||
let out = Printf.sprintf "%s.ssa" !Driver_config.Linkcore_Opt.output_file in | ||
Basic_io.write out (String.concat "\n" (List.map Riscv_ssa.to_string s)); | ||
s |
Oops, something went wrong.