Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(76)

Unified Diff: src/trusted/validator_arm/inst_classes.h

Issue 10356115: Clean up code to clarify we are only tracking the condition flags of APSR. (Closed) Base URL: svn://svn.chromium.org/native_client/trunk/src/native_client/
Patch Set: Created 8 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: src/trusted/validator_arm/inst_classes.h
===================================================================
--- src/trusted/validator_arm/inst_classes.h (revision 8564)
+++ src/trusted/validator_arm/inst_classes.h (working copy)
@@ -223,21 +223,22 @@
};
// Interface class to pull out S (update) bit from bit 20, which
-// defines if the flags register is updated by the instruction.
-class UpdatesFlagsRegisterBit20Interface {
+// defines if the condition bits in APSR are updated by the instruction.
+class UpdatesConditionsBit20Interface {
public:
- inline UpdatesFlagsRegisterBit20Interface() {}
- // Returns true if bit is set that states that the flags register is updated.
+ inline UpdatesConditionsBit20Interface() {}
+ // Returns true if bit is set that states that the condition bits
+ // APSR is updated.
static inline bool is_updated(const Instruction i) {
return i.bit(20);
}
- // Returns the flags register if it is used.
- static inline Register reg_if_updated(const Instruction i) {
- return is_updated(i) ? kRegisterFlags : kRegisterNone;
+ // Returns the conditions register if it is used.
+ static inline Register conds_if_updated(const Instruction i) {
+ return is_updated(i) ? kConditions : kRegisterNone;
}
private:
- NACL_DISALLOW_COPY_AND_ASSIGN(UpdatesFlagsRegisterBit20Interface);
+ NACL_DISALLOW_COPY_AND_ASSIGN(UpdatesConditionsBit20Interface);
};
// A class decoder is designed to decode a set of instructions that

Powered by Google App Engine
This is Rietveld 408576698