Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Synch from upstream #1

Merged
merged 7 commits into from
Oct 4, 2023
Merged

Synch from upstream #1

merged 7 commits into from
Oct 4, 2023

Conversation

raguilar755
Copy link

synch up upstream code.

eloparco and others added 7 commits September 29, 2023 10:52
Avoid the stack traces getting mixed up together when multi-threading is enabled
by using exception_lock/unlock in dumping the call stacks.

And remove duplicated call stack dump in wasm_application.c.

Also update coding guideline CI to fix the clang-format-12 not found issue.
When destroying wasi-nn context, module instance should be also
removed from hashmap to avoid memory leak.
Fixed a bug in the processing of the br_table_cache opcode that caused out-of-range
references when the label index was greater than the length of the label.
To make it clearer to users when synchronization behaviour is not
supported, return ENOTSUP when O_RSYNC, O_DSYNC or O_SYNC are
respectively not defined. Linux also doesn't support O_RSYNC despite the
O_RSYNC flag being defined.
This PR adds the Cosmopolitan Libc platform enabling compatibility with multiple
x86_64 operating systems with the same binary. The platform is similar to the
Linux platform, but for now only x86_64 with interpreter modes are supported.

The only major change to the core is `posix.c/convert_errno()` was rewritten to use
a switch statement. With Cosmopolitan errno values depend on the currently
running operating system, and so they are non-constant and cannot be used in array
designators. However, the `cosmocc` compiler allows non-constant case labels in
switch statements, enabling the new version.

And updated wamr-test-suites script to add `-j <platform>` option. The spec tests
can be ran via `CC=cosmocc ./test_wamr.sh -j cosmopolitan -t classic-interp`
or `CC=cosmocc ./test_wamr.sh -j cosmopolitan -t fast-interp`.
@raguilar755 raguilar755 merged commit d8ee771 into siemens:main Oct 4, 2023
161 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants