GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — JavaScriptKit/Sources/_CJavaScriptKit/include/WasmGlobalMacros.h at main · t089/JavaScriptKit Expand file tree/ Copy pathWasmGlobalMacros.hMore file actions 45 lines (39 loc) · 1.42 KB / Copy pathWasmGlobalMacros.hFile metadata and controls45 lines (39 loc) · 1.42 KB 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 #ifndef _CJavaScriptKit_WasmGlobalMacros_h #define _CJavaScriptKit_WasmGlobalMacros_h // Define an inline getter for a Wasm global #define WASM_GLOBAL_DEFINE_INLINE_GETTER(name, core_type, c_type) \ static inline c_type name##_get(void) { \ c_type val; \ __asm__( \ ".globaltype " #name ", " #core_type "\n" \ "global.get " #name "\n" \ "local.set %0\n" \ : "=r"(val)); \ return val; \ } // Define an inline setter for a Wasm global #define WASM_GLOBAL_DEFINE_INLINE_SETTER(name, core_type, c_type) \ static inline void name##_set(c_type val) { \ __asm__( \ ".globaltype " #name ", " #core_type "\n" \ "local.get %0\n" \ "global.set " #name "\n" \ : : "r"(val)); \ } // Define an inline getter and setter for a Wasm global #define WASM_GLOBAL_DEFINE_INLINE_ACCESSORS(name, core_type, c_type) \ WASM_GLOBAL_DEFINE_INLINE_GETTER(name, core_type, c_type) \ WASM_GLOBAL_DEFINE_INLINE_SETTER(name, core_type, c_type) // Define a Wasm global storage #define WASM_GLOBAL_DEFINE_STORAGE(name, core_type) \ __asm__( \ ".globaltype " #name ", " #core_type "\n" \ ".global " #name "\n" \ #name ":\n" \ ); // Define an export name for a Wasm value #define WASM_EXPORT_NAME(name, export_name) \ __asm__( \ ".export_name " #name ", " #export_name "\n" \ ); #endif |
| You are visitor 01402520 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |