summaryrefslogtreecommitdiffstats
path: root/src/corelib/global/qprocessordetection.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/corelib/global/qprocessordetection.h')
-rw-r--r--src/corelib/global/qprocessordetection.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/corelib/global/qprocessordetection.h b/src/corelib/global/qprocessordetection.h
index 0b260d01e3..aaa27dff4a 100644
--- a/src/corelib/global/qprocessordetection.h
+++ b/src/corelib/global/qprocessordetection.h
@@ -57,7 +57,7 @@
optional and usually dependent on how the compiler was invoked. Variants
that are a superset of another should have a define for the superset.
- In addition to the procesor family, variants, and revisions, we also set
+ In addition to the processor family, variants, and revisions, we also set
Q_BYTE_ORDER appropriately for the target processor. For bi-endian
processors, we try to auto-detect the byte order using the __BIG_ENDIAN__,
__LITTLE_ENDIAN__, or __BYTE_ORDER__ preprocessor macros.
@@ -320,6 +320,12 @@
# endif
# define Q_BYTE_ORDER Q_BIG_ENDIAN
+// -- Web Assembly --
+#elif defined(__EMSCRIPTEN__)
+# define Q_PROCESSOR_WASM
+# define Q_PROCESSOR_X86 6 // enables SIMD support
+# define Q_BYTE_ORDER Q_LITTLE_ENDIAN
+# define Q_PROCESSOR_WORDSIZE 8
#endif
/*