<commit_before><h1 id="portability">Portability</h1>

<h2>Platforms and compilers</h2>

<p>The table below summarizes the platforms and compilers which Duktape is known
to work on, with portability notes where appropriate.  This is not an exhaustive
list of supported/unsupported platforms, rather a list of what is known to work
(and not to work).  Platform and compiler specific issues are discussed in more
detail below the table.</p>

<table>
<thead>
<tr>
<th>Operating system</th>
<th>Compiler</th>
<th>Processor</th>
<th>Notes</th>
</tr>
</thead>
<tbody>
<tr>
<td>Linux</td>
<td>GCC</td>
<td>x86, x86-64, ARM, MIPS</td>
<td>No known issues.</td>
</tr>
<tr>
<td>Linux</td>
<td>Clang</td>
<td>x86, x86-64, ARM, MIPS</td>
<td>No known issues.</td>
</tr>
<tr>
<td>Linux</td>
<td>TCC</td>
<td>x86-64</td>
<td>Zero sign issues (see below).</td>
</tr>
<tr>
<td>FreeBSD</td>
<td>Clang</td>
<td>x86-64</td>
<td>Aliasing issues with clang 3.3 on FreeBSD, with <code>-m32</code> and packed <code>duk_tval</code>.</td>
</tr>
<tr>
<td>AmigaOS</td>
<td>VBCC</td>
<td>M68K</td>
<td>Requires some preprocessor defines, datetime resolution limited to full seconds.</td>
</tr>
<tr>
<td>TOS (Atari ST)</td>
<td>VBCC</td>
<td>M68K</td>
<td>Requires some preprocessor defines, datetime resolution limited to full seconds.</td>
</tr>
</tbody>
</table>

<h3>Clang</h3>

<p>Clang 3.3 on FreeBSD has some aliasing issues (at least) when using
<code>-m32</code> and when Duktape ends up using a packed <code>duk_tval</code>
value representation type.  The problem does not appear in all clang versions.
Duktape self tests cover this issue (define <code>DUK_OPT_SELF_TESTS</code>
when compiling).  See internal test file <code>misc/clang_aliasing.c</code>.</p>

<h3>TCC</h3>

<p>TCC has zero sign handling issues; Duktape mostly works but zero sign is<commit_msg>portability notes for msvc and mingw on windows x86<commit_after><h1 id="portability">Portability</h1>

<h2>Platforms and compilers</h2>

<p>The table below summarizes the platforms and compilers which Duktape is known
to work on, with portability notes where appropriate.  This is not an exhaustive
list of supported/unsupported platforms, rather a list of what is known to work
(and not to work).  Platform and compiler specific issues are discussed in more
detail below the table.</p>

<table>
<thead>
<tr>
<th>Operating system</th>
<th>Compiler</th>
<th>Processor</th>
<th>Notes</th>
</tr>
</thead>
<tbody>
<tr>
<td>Linux</td>
<td>GCC</td>
<td>x86, x86-64, ARM, MIPS</td>
<td>No known issues.</td>
</tr>
<tr>
<td>Linux</td>
<td>Clang</td>
<td>x86, x86-64, ARM, MIPS</td>
<td>No known issues.</td>
</tr>
<tr>
<td>Linux</td>
<td>TCC</td>
<td>x86-64</td>
<td>Zero sign issues (see below).</td>
</tr>
<tr>
<td>FreeBSD</td>
<td>Clang</td>
<td>x86-64</td>
<td>Aliasing issues with clang 3.3 on FreeBSD, with <code>-m32</code> and packed <code>duk_tval</code>.</td>
</tr>
<tr>
<td>Windows</td>
<td>MinGW</td>
<td>x86</td>
<td><code>-std=c99</code> recommended, only ISO 8601 date format supported (no platform specific format)</td>
</tr>
<tr>
<td>Windows</td>
<td>MSVC</td>
<td>x86</td>
<td>Tested with Visual Studio Express 2010, only ISO 8601 date format supported (no platform specific format)</td>
</tr>
<tr>
<td>AmigaOS</td>
<td>VBCC</td>
<td>M68K</td>
<td>Requires some preprocessor defines, datetime resolution limited to full seconds.</td>
</tr>
<tr>
<td>TOS (Atari ST)</td>
<td>VBCC</td>
<td>M68K</td>
<td>Requires some preprocessor defines, datetime resolution limited to full seconds.</td>
</tr>
</tbody>
</table>

<h3>Clang</h3>

<p>Clang 3.3 on FreeBSD has some aliasing issues (at least) when using
<code>-m32</code> and when Duktape ends up using a packed <code>duk_tval</code>
value representation type.  The problem does not appear in all clang versions.
Duktape self tests cover this issue (define <code>DUK_OPT_SELF_TESTS</code>
when compiling).  See internal test file <code>misc/clang_aliasing.c</code>.</p>

<h3>TCC</h3>

<p>TCC has zero sign handling issues; Duktape mostly works but zero sign is
{'fraction_non_alphanumeric': 0.165352390340069, 'fraction_numerical': 0.02464268112370626, 'mean_word_length': 5.122171945701357, 'pattern_counts': {'":': 0, '<': 227, '<?xml version=': 0, '>': 227, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7034600', 'n_tokens_mistral': 1636, 'n_tokens_neox': 1562, 'n_words': 481}