diff --git a/tasks/task_save.c b/tasks/task_save.c index 859f1629c7ff..fd4b19750781 100644 --- a/tasks/task_save.c +++ b/tasks/task_save.c @@ -62,7 +62,11 @@ #include "../cheat_manager.h" #endif -#if defined(HAVE_LIBNX) || defined(_3DS) +#ifdef EMSCRIPTEN +/* Filesystem is in-memory anyway, use huge chunks since each + read/write is a possible suspend to JS code */ +#define SAVE_STATE_CHUNK 4096 * 4096 +#elif defined(HAVE_LIBNX) || defined(_3DS) #define SAVE_STATE_CHUNK 4096 * 10 #else #define SAVE_STATE_CHUNK 4096