Skip to content
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

Bug with fgt.s command #140

Closed
ShadowCreator250 opened this issue Nov 26, 2021 · 2 comments
Closed

Bug with fgt.s command #140

ShadowCreator250 opened this issue Nov 26, 2021 · 2 comments

Comments

@ShadowCreator250
Copy link

I have RARS 1.5 (rars_46ab74d.jar) installed and ran into an issue when comparing 2 floats with the fgt.s t0, f1, f2 command.
I would expect that the command checks if f1 > f2 but it appears to check if f1 < f2.

Here is a little program to reproduce this:

.data
float1: .float 3.5001
float2: .float 3.5089

.text
flw ft0, float1, t0
flw ft1, float2, t0
flt.s t0, ft0, ft1 # check if flaot1 < flaot2. returns 1 (true)

flw ft0, float1, t1
flw ft1, float2, t1
fgt.s t1, ft0, ft1 # check if flaot1 > flaot2. Should return 0 (false) but returns 1 (true)

#exit program
li a7, 10
ecall

Let me know if you need anything else from me.

@TheThirdOne
Copy link
Owner

You are right that this is a bug. It was fixed in #131; the continuous release has the update for this, but it is not included in a numbered release yet. Let me know if that release does not fix this.

This is a well written issue though. It would have been easy to track down the issue if this had been the first I heard of it.

@ShadowCreator250
Copy link
Author

ShadowCreator250 commented Nov 27, 2021

As far as I can see, I have the Continuous Release installed. That's why I included the name of the jar.

So it seems that the bug is still present in the Continuous Release because #131 is not included in the release because commit 46ab74d (where the release is) comes before the commit done in #131. (See Commit History on Master)

I didn't find any issue that addressed this bug directly, and I didn't look through the PRs, my bad.

Thanks, though, I try. ^^

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants