<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="/rss.xsl.xml"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
<channel>
    <title>Changes in Makefile</title>
    <description></description>
    <language>en</language>
    <copyright>Copyright 2015</copyright>
    <generator>Java</generator><item>
        <title>1dc5bf02 - Makefile changes for newer clang</title>
        <link>http://172.16.0.5:8080/history/wasmtime-44.0.1/crates/wizer/examples/cpp/Makefile#1dc5bf02</link>
        <description>Makefile changes for newer clang

            List of files:
            /wasmtime-44.0.1/crates/wizer/examples/cpp/Makefile</description>
        <pubDate>Thu, 15 Dec 2022 00:21:48 +0000</pubDate>
        <dc:creator>Trevor Elliott &lt;telliott@fastly.com&gt;</dc:creator>
    </item>
<item>
        <title>9ab84eea - Add C++ example using function renaming to handle ctors properly.</title>
        <link>http://172.16.0.5:8080/history/wasmtime-44.0.1/crates/wizer/examples/cpp/Makefile#9ab84eea</link>
        <description>Add C++ example using function renaming to handle ctors properly.Previously, it was difficult to properly use Wizer with C++ programsthat have static constructors. These constructors are normally runbefore `main()` is invoked by some libc/linker plumbing at the usualentry point. This causes a set of undesirable problems:- In the Wizer initialization entry point, our globals&apos; constructors  have not yet run.- If we manually invoke the constructors to resolve the first issue,  then they will be *re*-invoked when the program&apos;s main entry point is  run on the initialized module. This may cause surprising or  inconsistent results.In order to properly handle this, we add a `wizer.h` header with aconvenient macro that allows specifying a user initialization function,and adds an exported top-level Wizer initialization entry point and anexported replacement main entry point.The generated initialization entry point invokes any global constructors(using the function `__wasm_call_ctors()` which is generated by`wasm-ld`) then invokes the user&apos;s initialization function.The generated main entry point is meant to replace `_start` and performsthe same work, *except* that it does not re-invoke constructors.Instead, it immediately invokes `main()` (because everything has alreadybeen initialized) and then calls destructors and exits.Taken together, the two entry points match the code that is present in`_start` in an ordinary Wasm binary compiled by wasi-sdk. This approachshould be relatively stable, as long as the symbols`__wasm_call_ctors()`, `__wasm_call_dtors()`, and `__original_main()`are not renamed in the WASI SDK (this seems unlikely).

            List of files:
            /wasmtime-44.0.1/crates/wizer/examples/cpp/Makefile</description>
        <pubDate>Wed, 10 Feb 2021 06:35:30 +0000</pubDate>
        <dc:creator>Chris Fallin &lt;chris@cfallin.org&gt;</dc:creator>
    </item>
</channel>
</rss>
