From 9d2d2a0b28d86d5c638d48b33fcfb8ab9e2388a0 Mon Sep 17 00:00:00 2001 From: nsfisis Date: Wed, 4 Sep 2024 06:38:14 +0900 Subject: 13-Mod-3 --- problems/13-Mod-3/06.vsm | 51 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 problems/13-Mod-3/06.vsm diff --git a/problems/13-Mod-3/06.vsm b/problems/13-Mod-3/06.vsm new file mode 100644 index 0000000..df20981 --- /dev/null +++ b/problems/13-Mod-3/06.vsm @@ -0,0 +1,51 @@ +imm f"8388608" $r0v +imm f"0.3333333333333333333333" $r4v + +# (32 / 8).times do |i| +# j = i * 8 +# # itof +# puts "ior $lm#{j}v $lr0 $nowrite" +# puts "fvadd $aluf -$lr0 $nowrite" +# # /3 +# puts "fvmul $mauf $lr4 $nowrite" +# # ftoi +# puts "fftoi $mauf $ls0v" +# # x3 +# puts "ipackbit $aluf $lr8 $nowrite" +# puts "iadd $ls0v $aluf $nowrite" +# # %3 +# puts "isub $lm#{j}v $aluf $ln#{j}v" +# puts +# end + +ior $lm0v $lr0 $nowrite +fvadd $aluf -$lr0 $nowrite +fvmul $mauf $lr4 $nowrite +fftoi $mauf $ls0v +ipackbit $aluf $lr8 $nowrite +iadd $ls0v $aluf $nowrite +isub $lm0v $aluf $ln0v + +ior $lm8v $lr0 $nowrite +fvadd $aluf -$lr0 $nowrite +fvmul $mauf $lr4 $nowrite +fftoi $mauf $ls0v +ipackbit $aluf $lr8 $nowrite +iadd $ls0v $aluf $nowrite +isub $lm8v $aluf $ln8v + +ior $lm16v $lr0 $nowrite +fvadd $aluf -$lr0 $nowrite +fvmul $mauf $lr4 $nowrite +fftoi $mauf $ls0v +ipackbit $aluf $lr8 $nowrite +iadd $ls0v $aluf $nowrite +isub $lm16v $aluf $ln16v + +ior $lm24v $lr0 $nowrite +fvadd $aluf -$lr0 $nowrite +fvmul $mauf $lr4 $nowrite +fftoi $mauf $ls0v +ipackbit $aluf $lr8 $nowrite +iadd $ls0v $aluf $nowrite +isub $lm24v $aluf $ln24v -- cgit v1.2.3-70-g09d2