aboutsummaryrefslogtreecommitdiff
path: root/vm/compiler/codegen/arm/CodegenDriver.c
diff options
context:
space:
mode:
authorBen Cheng <bccheng@android.com>2011-01-14 11:08:38 -0800
committerAndroid Git Automerger <android-git-automerger@android.com>2011-01-14 11:08:38 -0800
commit45e9a9908f8874b64294dbd3e4dcfb6b76c4b6e3 (patch)
tree92dd1f0ccc63509d5138e8bf3e53c7cf256c3c33 /vm/compiler/codegen/arm/CodegenDriver.c
parent660095cc310535c4874e953f5eea0abc2540f655 (diff)
parent80211d2b18daa79c7b4c9b04f0cb366660c86f73 (diff)
am 80211d2b: Only generate debugging LIRs in verbose mode.
* commit '80211d2b18daa79c7b4c9b04f0cb366660c86f73': Only generate debugging LIRs in verbose mode.
Diffstat (limited to 'vm/compiler/codegen/arm/CodegenDriver.c')
-rw-r--r--vm/compiler/codegen/arm/CodegenDriver.c35
1 files changed, 22 insertions, 13 deletions
diff --git a/vm/compiler/codegen/arm/CodegenDriver.c b/vm/compiler/codegen/arm/CodegenDriver.c
index 02c39f6d0..061ffb825 100644
--- a/vm/compiler/codegen/arm/CodegenDriver.c
+++ b/vm/compiler/codegen/arm/CodegenDriver.c
@@ -4107,21 +4107,30 @@ void dvmCompilerMIR2LIR(CompilationUnit *cUnit)
note = NULL;
}
- ArmLIR *boundaryLIR =
- newLIR2(cUnit, kArmPseudoDalvikByteCodeBoundary,
- mir->offset,
- (int) dvmCompilerGetDalvikDisassembly(&mir->dalvikInsn,
- note));
- if (mir->ssaRep) {
- char *ssaString = dvmCompilerGetSSAString(cUnit, mir->ssaRep);
- newLIR1(cUnit, kArmPseudoSSARep, (int) ssaString);
+ ArmLIR *boundaryLIR;
+
+ /*
+ * Don't generate the boundary LIR unless we are debugging this
+ * trace or we need a scheduling barrier.
+ */
+ if (headLIR == NULL || cUnit->printMe == true) {
+ boundaryLIR =
+ newLIR2(cUnit, kArmPseudoDalvikByteCodeBoundary,
+ mir->offset,
+ (int) dvmCompilerGetDalvikDisassembly(
+ &mir->dalvikInsn, note));
+ /* Remember the first LIR for this block */
+ if (headLIR == NULL) {
+ headLIR = boundaryLIR;
+ /* Set the first boundaryLIR as a scheduling barrier */
+ headLIR->defMask = ENCODE_ALL;
+ }
}
- /* Remember the first LIR for this block */
- if (headLIR == NULL) {
- headLIR = boundaryLIR;
- /* Set the first boundaryLIR as a scheduling barrier */
- headLIR->defMask = ENCODE_ALL;
+ /* Don't generate the SSA annotation unless verbose mode is on */
+ if (cUnit->printMe && mir->ssaRep) {
+ char *ssaString = dvmCompilerGetSSAString(cUnit, mir->ssaRep);
+ newLIR1(cUnit, kArmPseudoSSARep, (int) ssaString);
}
bool notHandled;