Jump to content

Parallel calculations: Difference between revisions

m
m (syntax highlighting fixup automation)
m (→‎{{header|Wren}}: Minor tidy)
Line 2,698:
 
However, it's possible for a suitable host on a suitable machine to run multiple VMs in parallel as the following example, with a C host, shows when run on a machine with four cores. Four VMs are used each of which runs on its own thread.
<syntaxhighlight lang="ecmascriptwren">/* parallel_calculationsParallel_calculations.wren */
 
import "./math" for Int
Line 2,818:
config.loadModuleFn = &loadModule;
const char* module = "main";
const char* fileName = "parallel_calculationsParallel_calculations.wren";
char *script = readFile(fileName);
 
9,485

edits

Cookies help us deliver our services. By using our services, you agree to our use of cookies.