assert to DCHECK conversion
Also replaced static function defs with a STATIC macro to make normally
hidden functions visible to DCHECK's traceback listing). Additionally,
added some portions of the new type & size inference mechanism (but not
taking advantage of them yet).
Change-Id: Ib42a08777f28ab879d0df37617e1b77e3f09ba52
diff --git a/src/compiler/IntermediateRep.cc b/src/compiler/IntermediateRep.cc
index 23486ba..a7da037 100644
--- a/src/compiler/IntermediateRep.cc
+++ b/src/compiler/IntermediateRep.cc
@@ -32,7 +32,7 @@
void oatAppendMIR(BasicBlock* bb, MIR* mir)
{
if (bb->firstMIRInsn == NULL) {
- assert(bb->lastMIRInsn == NULL);
+ DCHECK(bb->lastMIRInsn == NULL);
bb->lastMIRInsn = bb->firstMIRInsn = mir;
mir->prev = mir->next = NULL;
} else {
@@ -47,7 +47,7 @@
void oatPrependMIR(BasicBlock* bb, MIR* mir)
{
if (bb->firstMIRInsn == NULL) {
- assert(bb->lastMIRInsn == NULL);
+ DCHECK(bb->lastMIRInsn == NULL);
bb->lastMIRInsn = bb->firstMIRInsn = mir;
mir->prev = mir->next = NULL;
} else {
@@ -81,7 +81,7 @@
void oatAppendLIR(CompilationUnit *cUnit, LIR* lir)
{
if (cUnit->firstLIRInsn == NULL) {
- assert(cUnit->lastLIRInsn == NULL);
+ DCHECK(cUnit->lastLIRInsn == NULL);
cUnit->lastLIRInsn = cUnit->firstLIRInsn = lir;
lir->prev = lir->next = NULL;
} else {
@@ -100,7 +100,7 @@
*/
void oatInsertLIRBefore(LIR* currentLIR, LIR* newLIR)
{
- assert(currentLIR->prev != NULL);
+ DCHECK(currentLIR->prev != NULL);
LIR *prevLIR = currentLIR->prev;
prevLIR->next = newLIR;