vm: quell warnings from vars only used by asserts

db4
Joe Groff 2011-11-22 22:51:54 -08:00
parent 4df56f31f2
commit b6246f2c00
2 changed files with 3 additions and 0 deletions

View File

@ -29,6 +29,7 @@ inline static void check_call_site(cell return_address)
{
unsigned char opcode = call_site_opcode(return_address);
FACTOR_ASSERT(opcode == call_opcode || opcode == jmp_opcode);
(void)opcode; // suppress warning when compiling without assertions
}
inline static void *get_call_target(cell return_address)

View File

@ -23,12 +23,14 @@ jit::jit(code_block_type type_, cell owner_, factor_vm *vm)
{
fixnum old_count = atomic::fetch_add(&parent->current_jit_count, 1);
FACTOR_ASSERT(old_count >= 0);
(void)old_count;
}
jit::~jit()
{
fixnum old_count = atomic::fetch_subtract(&parent->current_jit_count, 1);
FACTOR_ASSERT(old_count >= 1);
(void)old_count;
}
void jit::emit_relocation(cell relocation_template_)