mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 915846 - Spew the full name of an MDefinition instead of just the number. r=nbp
This commit is contained in:
parent
0d4f665710
commit
38ae4b4b4b
@ -1893,6 +1893,15 @@ LinearSum::print(Sprinter &sp) const
|
||||
sp.printf("%d", constant_);
|
||||
}
|
||||
|
||||
void
|
||||
LinearSum::dump(FILE *fp) const
|
||||
{
|
||||
Sprinter sp(GetIonContext()->cx);
|
||||
sp.init();
|
||||
print(sp);
|
||||
fprintf(fp, "%s\n", sp.string());
|
||||
}
|
||||
|
||||
static bool
|
||||
AnalyzePoppedThis(JSContext *cx, types::TypeObject *type,
|
||||
MDefinition *thisValue, MInstruction *ins, bool definitelyExecuted,
|
||||
|
@ -118,6 +118,7 @@ class LinearSum
|
||||
LinearTerm term(size_t i) const { return terms_[i]; }
|
||||
|
||||
void print(Sprinter &sp) const;
|
||||
void dump(FILE *) const;
|
||||
|
||||
private:
|
||||
Vector<LinearTerm, 2, IonAllocPolicy> terms_;
|
||||
|
@ -106,10 +106,10 @@ SpewRange(MDefinition *def)
|
||||
{
|
||||
#ifdef DEBUG
|
||||
if (IonSpewEnabled(IonSpew_Range) && def->type() != MIRType_None && def->range()) {
|
||||
Sprinter sp(GetIonContext()->cx);
|
||||
sp.init();
|
||||
def->range()->print(sp);
|
||||
IonSpew(IonSpew_Range, "%d has range %s", def->id(), sp.string());
|
||||
IonSpewHeader(IonSpew_Range);
|
||||
def->printName(IonSpewFile);
|
||||
fprintf(IonSpewFile, " has range ");
|
||||
def->range()->dump(IonSpewFile);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
@ -235,7 +235,12 @@ RangeAnalysis::addBetaNodes()
|
||||
// [-\inf, bound-1] U [bound+1, \inf] but we only use contiguous ranges.
|
||||
}
|
||||
|
||||
IonSpew(IonSpew_Range, "Adding beta node for %d", val->id());
|
||||
if (IonSpewEnabled(IonSpew_Range)) {
|
||||
IonSpewHeader(IonSpew_Range);
|
||||
fprintf(IonSpewFile, "Adding beta node for %d with range ", val->id());
|
||||
comp.dump(IonSpewFile);
|
||||
}
|
||||
|
||||
MBeta *beta = MBeta::New(val, new Range(comp));
|
||||
block->insertBefore(*block->begin(), beta);
|
||||
replaceDominatedUsesWith(val, beta, block);
|
||||
@ -322,6 +327,15 @@ Range::print(Sprinter &sp) const
|
||||
sp.printf(" (< pow(2, %d+1))", max_exponent_);
|
||||
}
|
||||
|
||||
void
|
||||
Range::dump(FILE *fp) const
|
||||
{
|
||||
Sprinter sp(GetIonContext()->cx);
|
||||
sp.init();
|
||||
print(sp);
|
||||
fprintf(fp, "%s\n", sp.string());
|
||||
}
|
||||
|
||||
Range *
|
||||
Range::intersect(const Range *lhs, const Range *rhs, bool *emptyRange)
|
||||
{
|
||||
|
@ -328,6 +328,7 @@ class Range : public TempObject {
|
||||
}
|
||||
|
||||
void print(Sprinter &sp) const;
|
||||
void dump(FILE *fp) const;
|
||||
bool update(const Range *other);
|
||||
|
||||
// Unlike the other operations, unionWith is an in-place
|
||||
|
Loading…
Reference in New Issue
Block a user