#include "wcclib.h"

// Wasm loop bounds

__attribute__((import_module("__pragma"), import_name("loopbound"))) extern void
__pragma_loopbound(unsigned int min_bound, unsigned int max_bound);

void *
wcclib_memset(void *s, int c, size_t n) {
    unsigned char *p = s;

    __pragma_loopbound(1, 368);
    while (n--)
        *p++ = (unsigned char) c;
    return (s);
}
