perf: optimize database query by adding composite index on user_id and created_at columns
This commit is contained in:
@@ -112,6 +112,19 @@ void rava_program_add_class(RavaProgram_t *program, RavaClass_t *class) {
|
||||
program->classes[program->class_count++] = class;
|
||||
}
|
||||
|
||||
void rava_program_prebuild_label_tables(RavaProgram_t *program) {
|
||||
if (!program) return;
|
||||
for (size_t i = 0; i < program->class_count; i++) {
|
||||
RavaClass_t *class = program->classes[i];
|
||||
for (size_t j = 0; j < class->method_count; j++) {
|
||||
RavaMethod_t *method = class->methods[j];
|
||||
if (!method->label_table && method->instructions) {
|
||||
method->label_table = rava_labeltable_create(method->instructions);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static const char* _rava_opcode_name(RavaOpCode_e opcode) {
|
||||
switch (opcode) {
|
||||
case RAVA_OP_NOP: return "NOP";
|
||||
|
||||
Reference in New Issue
Block a user