about summary refs log tree commit diff stats
path: root/033check_operands.cc
diff options
context:
space:
mode:
authorKartik Agaram <vc@akkartik.com>2020-09-30 22:07:38 -0700
committerKartik Agaram <vc@akkartik.com>2020-09-30 22:09:26 -0700
commitd564633b240cfc0e8bfe49098a6ac49abf688a76 (patch)
treec91a9dd5dea293fcccb46d896bd8f9be1998a889 /033check_operands.cc
parent8b215b65cf989235de65827296f5566132e8abeb (diff)
downloadmu-d564633b240cfc0e8bfe49098a6ac49abf688a76.tar.gz
6910 - emulate most floating-point operations
Diffstat (limited to '033check_operands.cc')
-rw-r--r--033check_operands.cc13
1 files changed, 11 insertions, 2 deletions
diff --git a/033check_operands.cc b/033check_operands.cc
index bbe2837f..66f74e80 100644
--- a/033check_operands.cc
+++ b/033check_operands.cc
@@ -697,8 +697,17 @@ map</*op*/string, /*bitvector*/uint8_t> Permitted_arguments_f3_0f;
 //// Class M: using ModR/M byte
 //  imm32 imm8  disp32 |disp16  disp8 subop modrm
 //  0     0     0      |0       0     0     1
-put_new(Permitted_arguments_f3_0f, "2a", 0x01);
-put_new(Permitted_arguments_f3_0f, "5e", 0x01);
+put_new(Permitted_arguments_f3_0f, "2a", 0x01);  // convert-to-float
+put_new(Permitted_arguments_f3_0f, "2d", 0x01);  // convert-to-int
+put_new(Permitted_arguments_f3_0f, "51", 0x01);  // square root
+put_new(Permitted_arguments_f3_0f, "52", 0x01);  // inverse square root
+put_new(Permitted_arguments_f3_0f, "53", 0x01);  // reciprocal
+put_new(Permitted_arguments_f3_0f, "58", 0x01);  // add floats
+put_new(Permitted_arguments_f3_0f, "59", 0x01);  // multiply floats
+put_new(Permitted_arguments_f3_0f, "5c", 0x01);  // subtract floats
+put_new(Permitted_arguments_f3_0f, "5d", 0x01);  // minimum of floats
+put_new(Permitted_arguments_f3_0f, "5e", 0x01);  // divide floats
+put_new(Permitted_arguments_f3_0f, "5f", 0x01);  // maximum of floats
 
 :(code)
 void check_arguments_0f(const line& inst, const word& op) {