summaryrefslogtreecommitdiff
path: root/sim/mips/sim-main.h
diff options
context:
space:
mode:
authorChris Demetriou <cgd@google.com>2002-06-04 16:17:20 +0000
committerChris Demetriou <cgd@google.com>2002-06-04 16:17:20 +0000
commit294700a2cb9f8f022f4232772520522f4293ffe4 (patch)
tree0bbaa7cb3df34a9e051c838d6f5503721e17cbc6 /sim/mips/sim-main.h
parentb1ada216995bf55fb80c759208d5bd6cfd198766 (diff)
downloadgdb-294700a2cb9f8f022f4232772520522f4293ffe4.tar.gz
2002-06-04 Chris Demetriou <cgd@broadcom.com>
Ed Satterthwaite <ehs@broadcom.com> * cp1.c (Infinity): Remove. * sim-main.h (Infinity): Likewise. * cp1.c (fp_unary, fp_binary): New functions. (fp_abs, fp_neg, fp_add, fp_sub, fp_mul, fp_div, fp_recip) (fp_sqrt): New functions, implemented in terms of the above. (AbsoluteValue, Negate, Add, Sub, Multiply, Divide) (Recip, SquareRoot): Remove (replaced by functions above). * sim-main.h (fp_abs, fp_neg, fp_add, fp_sub, fp_mul, fp_div) (fp_recip, fp_sqrt): New prototypes. (AbsoluteValue, Negate, Add, Sub, Multiply, Divide) (Recip, SquareRoot): Replace prototypes with #defines which invoke the functions above.
Diffstat (limited to 'sim/mips/sim-main.h')
-rw-r--r--sim/mips/sim-main.h25
1 files changed, 16 insertions, 9 deletions
diff --git a/sim/mips/sim-main.h b/sim/mips/sim-main.h
index 47b5feb0ff2..8087a3a3f8e 100644
--- a/sim/mips/sim-main.h
+++ b/sim/mips/sim-main.h
@@ -716,17 +716,24 @@ void store_fpr (SIM_STATE, int fpr, FP_formats fmt, unsigned64 value);
/* FPU operations. */
int NaN (unsigned64 op, FP_formats fmt);
-int Infinity (unsigned64 op, FP_formats fmt);
int Less (unsigned64 op1, unsigned64 op2, FP_formats fmt);
int Equal (unsigned64 op1, unsigned64 op2, FP_formats fmt);
-unsigned64 AbsoluteValue (unsigned64 op, FP_formats fmt);
-unsigned64 Negate (unsigned64 op, FP_formats fmt);
-unsigned64 Add (unsigned64 op1, unsigned64 op2, FP_formats fmt);
-unsigned64 Sub (unsigned64 op1, unsigned64 op2, FP_formats fmt);
-unsigned64 Multiply (unsigned64 op1, unsigned64 op2, FP_formats fmt);
-unsigned64 Divide (unsigned64 op1, unsigned64 op2, FP_formats fmt);
-unsigned64 Recip (unsigned64 op, FP_formats fmt);
-unsigned64 SquareRoot (unsigned64 op, FP_formats fmt);
+unsigned64 fp_abs (SIM_STATE, unsigned64 op, FP_formats fmt);
+#define AbsoluteValue(op,fmt) fp_abs(SIM_ARGS, op, fmt)
+unsigned64 fp_neg (SIM_STATE, unsigned64 op, FP_formats fmt);
+#define Negate(op,fmt) fp_neg(SIM_ARGS, op, fmt)
+unsigned64 fp_add (SIM_STATE, unsigned64 op1, unsigned64 op2, FP_formats fmt);
+#define Add(op1,op2,fmt) fp_add(SIM_ARGS, op1, op2, fmt)
+unsigned64 fp_sub (SIM_STATE, unsigned64 op1, unsigned64 op2, FP_formats fmt);
+#define Sub(op1,op2,fmt) fp_sub(SIM_ARGS, op1, op2, fmt)
+unsigned64 fp_mul (SIM_STATE, unsigned64 op1, unsigned64 op2, FP_formats fmt);
+#define Multiply(op1,op2,fmt) fp_mul(SIM_ARGS, op1, op2, fmt)
+unsigned64 fp_div (SIM_STATE, unsigned64 op1, unsigned64 op2, FP_formats fmt);
+#define Divide(op1,op2,fmt) fp_div(SIM_ARGS, op1, op2, fmt)
+unsigned64 fp_recip (SIM_STATE, unsigned64 op, FP_formats fmt);
+#define Recip(op,fmt) fp_recip(SIM_ARGS, op, fmt)
+unsigned64 fp_sqrt (SIM_STATE, unsigned64 op, FP_formats fmt);
+#define SquareRoot(op,fmt) fp_sqrt(SIM_ARGS, op, fmt)
unsigned64 convert (SIM_STATE, int rm, unsigned64 op, FP_formats from, FP_formats to);
#define Convert(rm,op,from,to) convert (SIM_ARGS, rm, op, from, to)