chore: refactor out u8

main
Sean McBride 4 years ago
parent 7f9ffe236e
commit 1487614863

@ -22,13 +22,13 @@ get_f64(int32_t offset)
return *(double *)address;
}
INLINE i8
INLINE int8_t
get_i8(int32_t offset)
{
char *mem_as_chars = (char *)local_sandbox_context_cache.linear_memory_start;
void *address = &mem_as_chars[offset];
return *(i8 *)address;
return *(int8_t *)address;
}
INLINE int16_t
@ -96,12 +96,12 @@ set_f64(int32_t offset, double v)
}
INLINE void
set_i8(int32_t offset, i8 v)
set_i8(int32_t offset, int8_t v)
{
char *mem_as_chars = (char *)local_sandbox_context_cache.linear_memory_start;
void *address = &mem_as_chars[offset];
*(i8 *)address = v;
*(int8_t *)address = v;
}
INLINE void

@ -35,9 +35,6 @@
#define round_to_page(x) round_to_pow2(x, PAGE_SIZE)
#define round_up_to_page(x) round_up_to_pow2(x, PAGE_SIZE)
/* Type alias's so I don't have to write uint32_t a million times */
typedef signed char i8;
/* FIXME: per-module configuration? */
#define WASM_PAGE_SIZE (1024 * 64) /* 64KB */
#define WASM_START_PAGES (1 << 8) /* 16MB */

Loading…
Cancel
Save