Some conditional branch instructions generated by this pass are checking the wrong condition code. The instructions TBZ and TBNZ are transformed into B.GE and B.LT instead of B.PL and B.MI respectively. They should only be checking the Negative bit.
Details
Details
Diff Detail
Diff Detail
Event Timeline
Comment Actions
Good catch. @mcrosier These test could probably be improved a little by making clear which way the branch was going by checking for the store instruction before the ret.
lib/Target/AArch64/AArch64CondBrTuning.cpp | ||
---|---|---|
25 | This comment should be fixed. |
Comment Actions
Thanks for the fix, Alexandros!
I'll improve the test cases shortly, Geoff.
lib/Target/AArch64/AArch64CondBrTuning.cpp | ||
---|---|---|
25 | I'll update this shortly. |
This comment should be fixed.