diff options
author | Derek Schuff <dschuff@chromium.org> | 2017-09-06 14:13:29 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-09-06 14:13:29 -0700 |
commit | d2a401d27ef3592638e0e7689eebed317966334a (patch) | |
tree | 13f627f7cd3aaeb20ac1708ad1bf244bf7ec07c4 /src/wasm.h | |
parent | 192b59a8bc8e5376ca120dc592d5abad7c654230 (diff) | |
download | binaryen-d2a401d27ef3592638e0e7689eebed317966334a.tar.gz binaryen-d2a401d27ef3592638e0e7689eebed317966334a.tar.bz2 binaryen-d2a401d27ef3592638e0e7689eebed317966334a.zip |
Add support for sign-extension operators from threading proposal (#1167)
These are not atomic operations, but are added with the atomic operations to keep from having to define atomic versions of all the sign-extending loads (an atomic zero-extending load + signext operation can be used instead).
Diffstat (limited to 'src/wasm.h')
-rw-r--r-- | src/wasm.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/wasm.h b/src/wasm.h index 0cd5b05e8..d2bea45a1 100644 --- a/src/wasm.h +++ b/src/wasm.h @@ -98,6 +98,10 @@ enum UnaryOp { PromoteFloat32, // f32 to f64 DemoteFloat64, // f64 to f32 ReinterpretInt32, ReinterpretInt64, // reinterpret bits to float + // The following sign-extention operators go along with wasm atomics support. + // Extend signed subword-sized integer. This differs from e.g. ExtendSInt32 + // because the input integer is in an i64 value insetad of an i32 value. + ExtendS8Int32, ExtendS16Int32, ExtendS8Int64, ExtendS16Int64, ExtendS32Int64, }; enum BinaryOp { |