mirror of
https://github.com/DarkPlacesEngine/gmqcc.git
synced 2025-01-18 14:21:36 +00:00
slight change to ir_value_dump_life; fixing ir_value_life_merge_into: TODO test this seperately, all cases
This commit is contained in:
parent
41d1ef37d2
commit
5e4b8846d1
2 changed files with 4 additions and 4 deletions
6
ir.c
6
ir.c
|
@ -919,7 +919,7 @@ bool ir_value_life_merge_into(ir_value *self, const ir_value *other)
|
|||
}
|
||||
|
||||
if (life->start < entry->start &&
|
||||
life->end >= entry->start)
|
||||
life->end+1 >= entry->start)
|
||||
{
|
||||
/* starts earlier and overlaps */
|
||||
entry->start = life->start;
|
||||
|
@ -3109,10 +3109,10 @@ void ir_value_dump(ir_value* v, int (*oprintf)(const char*, ...))
|
|||
}
|
||||
}
|
||||
|
||||
void ir_value_dump_life(ir_value *self, int (*oprintf)(const char*,...))
|
||||
void ir_value_dump_life(const ir_value *self, int (*oprintf)(const char*,...))
|
||||
{
|
||||
size_t i;
|
||||
oprintf("Life of %s:\n", self->name);
|
||||
oprintf("Life of %12s:", self->name);
|
||||
for (i = 0; i < self->life_count; ++i)
|
||||
{
|
||||
oprintf(" + [%i, %i]\n", self->life[i].start, self->life[i].end);
|
||||
|
|
2
ir.h
2
ir.h
|
@ -111,7 +111,7 @@ bool ir_value_lives(ir_value*, size_t);
|
|||
bool ir_values_overlap(const ir_value*, const ir_value*);
|
||||
|
||||
void ir_value_dump(ir_value*, int (*oprintf)(const char*,...));
|
||||
void ir_value_dump_life(ir_value *self, int (*oprintf)(const char*,...));
|
||||
void ir_value_dump_life(const ir_value *self, int (*oprintf)(const char*,...));
|
||||
|
||||
/* A vector of IR values */
|
||||
typedef struct {
|
||||
|
|
Loading…
Reference in a new issue