-
Notifications
You must be signed in to change notification settings - Fork 231
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Floating-Point Conversion ( fcvt.d.s) #90
Comments
Thanks for the issue. The instruction should be taking a floating point argument. This is just a simple typo; the logic of the FCVT.D.S instruction is the correct logic. FCVT.S.D is broken in the same way. I thought these were both tested, but it seems that the FCVT.D.S psuedo-instruction can convert floating point to integer registers so the tests didn't fail to assemble. This is very easy to fix; only the example format and description for each instruction have to be changed. I am probably going to handle this issue and a few others tomorrow as a batch. |
Issue #90 brought this to my attention. Interestingly the psuedo-instruction system convered this up.
…ound to nearest even I found this bug while fixing #90 and saw the operands[3] on an instruction with only 3 arguments. I also started up a debugger to check if I had made this mistake elsewhere. I checked all calls to Floating.getRoundingMode called by the tests and none of them incorrectly use RNE. If another instruction is borked, the operand count is too low rather than too high. While debugging, I found that the toString method of ProgramStatement is completely borked.
This should be fixed now. Let me know if it is fixed for you in the continuous build. I found a separate issue with fcvt.s.d by fixing this so this issue helped doubly. |
Thanks. It is working as expected now.
Best wishes,
Bill Pierce
…________________________________
From: Benjamin Landers <[email protected]>
Sent: Tuesday, September 8, 2020 8:01 PM
To: TheThirdOne/rars <[email protected]>
Cc: Pierce, Bill <[email protected]>; Author <[email protected]>
Subject: Re: [TheThirdOne/rars] Floating-Point Conversion ( fcvt.d.s) (#90)
[CAUTION - External Email] This email originated from outside of Hood College. DO NOT click on links or open attachments if you do not recognize the sender.
This should be fixed now. Let me know if it is fixed for you in the continuous build.
I found a separate issue with fcvt.s.d by fixing this so this issue helped doubly.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#90 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/ANFDM2JKR5C3OW3IBQJ2EO3SE3AXNANCNFSM4Q6HWL3A>.
|
Error message on the following instruction: fcvt.d.s ft2, ft1, dyn
Error in test.asm line 31 column 12: "ft2": operand is of incorrect type
The help documentation states the following: fcvt.d.s t1, f1, dyn Convert a float to a double: Assigned the value of f2 to f1
(note register t1 is referenced in the format but f2 is stated in the description.)
Specification description: "The double-precision to single-precision and single-precision to double-precision conversion instructions, FCVT.S.D and FCVT.D.S, are encoded in the OP-FP major opcode space and both the source and destination are floating-point registers."
It seems the implementation of the instruction in RARS is attempting a floating to integer conversion where it should be a floating precision conversion from single-precision to double-precision.
The text was updated successfully, but these errors were encountered: